From 3f5f7fdac100acda6570dc1eb33e28e82f4eca25 Mon Sep 17 00:00:00 2001 From: "Andrew M. B. Boktor" Date: Wed, 9 Nov 2011 12:33:16 -0800 Subject: The simulator stops and outputs a message if it cannot find a cubin file while trying to convert to ptxplus [git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 10869] --- libcuda/cuda_runtime_api.cc | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'libcuda/cuda_runtime_api.cc') diff --git a/libcuda/cuda_runtime_api.cc b/libcuda/cuda_runtime_api.cc index 8bb0e01..7a651bb 100644 --- a/libcuda/cuda_runtime_api.cc +++ b/libcuda/cuda_runtime_api.cc @@ -1143,6 +1143,10 @@ void** CUDARTAPI __cudaRegisterFatBinary( void *fatCubin ) symbol_table *symtab; const char *ptx = info->ptx[selected_capability].ptx; if(context->get_device()->get_gpgpu()->get_config().convert_to_ptxplus() ) { + if (info->cubin[selected_capability].cubin ==NULL) { + printf("GPGPU-Sim PTX: Cannot convert to ptxplus no cubin found, probably because it was compiled using newer version of cuda (>=3.0)\nGPGPU-Sim PTX: Exiting ...\n"); + exit(1); + } char *ptxplus_str = gpgpu_ptx_sim_convert_ptx_to_ptxplus(ptx, info->cubin[selected_capability].cubin, source_num++, context->get_device()->get_gpgpu()->get_config().saved_converted_ptxplus()); symtab=gpgpu_ptx_sim_load_ptx_from_string(ptxplus_str,source_num); -- cgit v1.3