diff options
| author | Tor Aamodt <[email protected]> | 2010-07-19 09:30:26 -0800 |
|---|---|---|
| committer | Tor Aamodt <[email protected]> | 2010-07-19 09:30:26 -0800 |
| commit | 7f931254bd1468c2db4fc7a954550e89c3d742f4 (patch) | |
| tree | 0a38a6646ad660e15e374cdccb2cd97ba6809ba2 /libopencl/opencl_runtime_api.cc | |
| parent | 4a23383d1266b7bce38d1f1f1c782c11643c364e (diff) | |
updating opencl wrapper support
[git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 6892]
Diffstat (limited to 'libopencl/opencl_runtime_api.cc')
| -rw-r--r-- | libopencl/opencl_runtime_api.cc | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/libopencl/opencl_runtime_api.cc b/libopencl/opencl_runtime_api.cc index 22119c9..d49cc6e 100644 --- a/libopencl/opencl_runtime_api.cc +++ b/libopencl/opencl_runtime_api.cc @@ -515,6 +515,8 @@ void _cl_program::Build(const char *options) if( result != 0 ) { printf("GPGPU-Sim OpenCL API: ERROR ** while calling NVIDIA driver to convert OpenCL to PTX (%u)\n", result ); + printf("GPGPU-Sim OpenCL API: LD_LIBRARY_PATH was \'%s\'\n", nvopencl_libdir); + printf("GPGPU-Sim OpenCL API: command line was \'%s\'\n", commandline); exit(1); } // clean up files... @@ -662,6 +664,25 @@ clCreateContextFromType(cl_context_properties * properties, return ctx; } +extern CL_API_ENTRY cl_context CL_API_CALL +clCreateContext( const cl_context_properties * properties, + cl_uint num_devices, + const cl_device_id *devices, + void (*pfn_notify)(const char *, const void *, size_t, void *), + void * user_data, + cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_0 +{ + GPGPUSIM_INIT + if( properties != NULL ) { + printf("GPGPU-Sim OpenCL API: do not know how to use properties in %s\n", __my_func__ ); + exit(1); + } + if( errcode_ret ) + *errcode_ret = CL_SUCCESS; + cl_context ctx = new _cl_context; + return ctx; +} + extern CL_API_ENTRY cl_int CL_API_CALL clGetContextInfo(cl_context context, cl_context_info param_name, |
