Open ShihengCao opened 5 months ago
The error may by revelant to the NVCC and CUDA version. My machine is an A100 GPU with CUDA Driver version 545.23.08 and CUDA version 12.3. I encounted the same problem when building the tool with NVCC 12.1.1 and 11.8. However, when I changed to NVCC 11.4.0, this error just vanished and the tool worked well.
LD_PRELOAD=../../tools/instr_count_bb/instr_count_bb.so ./vectoradd
------------- NVBit (NVidia Binary Instrumentation Tool v1.5.5) Loaded --------------
NVBit core environment variables (mostly for nvbit-devs):
NVDISASM = nvdisasm - override default nvdisasm found in PATH
NOBANNER = 0 - if set, does not print this banner
---------------------------------------------------------------------------------
START_GRID_NUM = 0 - Beginning of the kernel gird launch interval where to apply instrumentation
END_GRID_NUM = 4294967295 - End of the kernel grid launch interval where to apply instrumentation
COUNT_WARP_LEVEL = 1 - Count warp level or thread level instructions
EXCLUDE_PRED_OFF = 0 - Exclude predicated off instruction from count
ACTIVE_FROM_START = 1 - Start instruction counting from start or wait for cuProfilerStart and cuProfilerStop
MANGLED_NAMES = 1 - Print kernel names mangled or not
TOOL_VERBOSE = 0 - Enable verbosity inside the tool
----------------------------------------------------------------------------------------------------
kernel 0 - _Z6vecAddPdS_S_i - #thread-blocks 98, kernel instructions 50066, total instructions 50066
Final sum = 100000.000000; sum/n = 1.000000 (should be ~1)
Total app instructions: 50066
I got it to work on CUDA 11.7 with NVIDIA driver 545.23.08.
Thanks for reply, I made it work with CUDA 10.2
I run the instr_count in test-apps and get this
when i run make, there are some warnings. i am not sure is it relevant with the problem.
my env:
there are some tests i did, i compiled and ran the example in another machine and success, but when i copy the so file and the exexcute file to WSL, it faces the same problem ,which is instrumentation function count_instrs not found in binary.