diff options
| author | Andrew M. B. Boktor <[email protected]> | 2012-08-17 15:39:05 -0800 |
|---|---|---|
| committer | Andrew Boktor <[email protected]> | 2014-08-14 13:48:54 -0700 |
| commit | bc96229ad220fbb0bda1354a699efc41783f4f27 (patch) | |
| tree | 205bd40ec5e143533649ddb5dc40c5d8be1778d8 /libcuda/cuda_runtime_api.cc | |
| parent | 88fcb4e649cf4de32be8f9d15cb2b9e593d4b993 (diff) | |
Fixing the case where cuobjdump is not used for on demand loading of binaries
[git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 13795]
Diffstat (limited to 'libcuda/cuda_runtime_api.cc')
| -rw-r--r-- | libcuda/cuda_runtime_api.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/libcuda/cuda_runtime_api.cc b/libcuda/cuda_runtime_api.cc index 9eee56a..011fef3 100644 --- a/libcuda/cuda_runtime_api.cc +++ b/libcuda/cuda_runtime_api.cc @@ -1638,7 +1638,8 @@ void CUDARTAPI __cudaRegisterFunction( unsigned fat_cubin_handle = (unsigned)(unsigned long long)fatCubinHandle; printf("GPGPU-Sim PTX: __cudaRegisterFunction %s : hostFun 0x%p, fat_cubin_handle = %u\n", deviceFun, hostFun, fat_cubin_handle); - cuobjdumpParseBinary(fat_cubin_handle); + if(context->get_device()->get_gpgpu()->get_config().use_cuobjdump()) + cuobjdumpParseBinary(fat_cubin_handle); context->register_function( fat_cubin_handle, hostFun, deviceFun ); } @@ -1654,7 +1655,8 @@ extern void __cudaRegisterVar( { printf("GPGPU-Sim PTX: __cudaRegisterVar: hostVar = %p; deviceAddress = %s; deviceName = %s\n", hostVar, deviceAddress, deviceName); printf("GPGPU-Sim PTX: __cudaRegisterVar: Registering const memory space of %d bytes\n", size); - cuobjdumpParseBinary((unsigned)(unsigned long long)fatCubinHandle); + if(GPGPUSim_Context()->get_device()->get_gpgpu()->get_config().use_cuobjdump()) + cuobjdumpParseBinary((unsigned)(unsigned long long)fatCubinHandle); fflush(stdout); if ( constant && !global && !ext ) { gpgpu_ptx_sim_register_const_variable(hostVar,deviceName,size); |
