Open SomePersonSomeWhereInTheWorld opened 1 year ago
It seems like the setup_environment
script does't find the correct vesion of gcc. Because the output has no version info in touch /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11080/release/cuda-sim/Makefile.makedepend
.
And you can check the command in setup_environment
script:
CC_VERSION=`gcc --version | head -1 | awk '{for(i=1;i<=NF;i++){ if(match($i,/^[0-9]\.[0-9]\.[0-9]$/)) {print $i; exit 0}}}'`
and, add a setence echo $CC_VERSION
after this line to see if there is valid CC_VERSION
for output.
Another possible reason is that you don't correctly use the script, cause the path /path/to/me/gpgpu-sim_distribution/
is not right.
It seems like the
setup_environment
script does't find the correct vesion of gcc. Because the output has no version info intouch /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11080/release/cuda-sim/Makefile.makedepend
.And you can check the command in
setup_environment
script:CC_VERSION=`gcc --version | head -1 | awk '{for(i=1;i<=NF;i++){ if(match($i,/^[0-9]\.[0-9]\.[0-9]$/)) {print $i; exit 0}}}'`
and, add a setence
echo $CC_VERSION
after this line to see if there is validCC_VERSION
for output.
It returns nothing, if I just used:
gcc --version | head -1
gcc (GCC) 11.2.1 20220127 (Red Hat 11.2.1-9)
Another possible reason is that you don't correctly use the script, cause the path
/path/to/me/gpgpu-sim_distribution/
is not right.
Just obfuscation on my part of the path.
match($i,/^[0-9]\.[0-9]\.[0-9]$/)
can only check gcc whose version is less than 9.9.9, so the version that you use is 11.2.1. I recommend that you can use gcc-7.5.0 or gcc-5.3.0, which is very stable.
You can also edit match($i,/^[0-9]\.[0-9]\.[0-9]$/)
to match($i,/^1[0-9]|0?[1-9]\.[0-9]\.[0-9]$/)
for the use of your gcc version, but it may occur compilation problem. So to be on the safe side, you can lower your gcc version to gcc-5.3.0 or gcc-7.5.0.
You can also edit
match($i,/^[0-9]\.[0-9]\.[0-9]$/)
tomatch($i,/^[0-11]\.[0-9]\.[0-9]$/)
for the use of your gcc version, but it may occur compilation problem.
Just tried this and I get:
~/gpgpu-sim_distribution$ make
Building GPGPU-Sim version 4.0.0 (build gpgpu-sim_git-commit-90ec3399763d7c8512cfe7dc193473086c38ca38_modified_1.0) with CUDA version 11.7
if [ ! -d lib/gcc-/cuda-11070/release ]; then mkdir -p lib/gcc-/cuda-11070/release; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libcuda ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libcuda; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/decuda_pred_table ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/decuda_pred_table; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpgpu-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpgpu-sim; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl/bin ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl/bin; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/intersim2 ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/intersim2; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch/cacti ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch/cacti; fi;
make -C ./src/cuda-sim/ depend
make[1]: Entering directory '/path/to/me/gpgpu-sim_distribution/src/cuda-sim'
touch /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend
makedepend -f/path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend -p/path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/ cuda_device_printf.cc cuda_device_runtime.cc cuda-sim.cc instructions.cc memory.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc ptx-stats.cc 2> /dev/null
Sorry, there is some mistake, the code should be match($i,/^1[0-9]|0?[1-9]\.[0-9]\.[0-9]$/)
or just match($i,/^1[0-9]\.[0-9]\.[0-9]$/)
.
Even if your env can check the right gcc version during this stage, it will occur compilation errors. So to be on the safe side, you can lower the gcc version to gcc-5.3.0 or gcc-7.5.0.
I tried both:
gpgpu-sim_distribution$ make
Building GPGPU-Sim version 4.0.0 (build gpgpu-sim_git-commit-90ec3399763d7c8512cfe7dc193473086c38ca38_modified_1.0) with CUDA version 11.7
if [ ! -d lib/gcc-/cuda-11070/release ]; then mkdir -p lib/gcc-/cuda-11070/release; fi;
if [ ! -d path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/libcuda ]; then mkdir -p path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/libcuda; fi;
if [ ! -d path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim ]; then mkdir -p path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim; fi;
if [ ! -d path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/decuda_pred_table ]; then mkdir -p path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/decuda_pred_table; fi;
if [ ! -d path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpgpu-sim ]; then mkdir -p path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpgpu-sim; fi;
if [ ! -d path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl ]; then mkdir -p path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl; fi;
if [ ! -d path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl/bin ]; then mkdir -p path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl/bin; fi;
if [ ! -d path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/intersim2 ]; then mkdir -p path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/intersim2; fi;
if [ ! -d path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus ]; then mkdir -p path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus; fi;
if [ ! -d path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch ]; then mkdir -p path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch; fi;
if [ ! -d path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch/cacti ]; then mkdir -p path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch/cacti; fi;
make -C ./src/cuda-sim/ depend
make[1]: Entering directory 'path/to/megpgpu-sim_distribution/src/cuda-sim'
make[1]: Warning: File 'path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend' has modification time 77 s in the future
touch path/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend
makedepend -fpath/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend -ppath/to/megpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/ cuda_device_printf.cc cuda_device_runtime.cc cuda-sim.cc instructions.cc memory.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc ptx-stats.cc 2> /dev/null
make[1]: *** [Makefile:76: depend] Error 127
make[1]: Leaving directory 'path/to/megpgpu-sim_distribution/src/cuda-sim'
make: *** [Makefile:207: cuda-sim] Error 2
It's best to give me an account to connect to your machine remotely, and I'll locate the error. If your machine can connect remotely, you can send the account number to my email masa-lab@outlook.com
The gcc version detection code in version_detection.mk
should also be updated.
The gcc version detection code in
version_detection.mk
should also be updated.
Well it's now finding the version:
make
make: Warning: File 'version_detection.mk' has modification time 176 s in the future
Building GPGPU-Sim version 4.0.0 (build gpgpu-sim_git-commit-90ec3399763d7c8512cfe7dc193473086c38ca38_modified_2.0) with CUDA version 11.7
if [ ! -d lib/gcc-11.2.1/cuda-11070/release ]; then mkdir -p lib/gcc-11.2.1/cuda-11070/release; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libcuda ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libcuda; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/decuda_pred_table ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/decuda_pred_table; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpgpu-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpgpu-sim; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl/bin ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl/bin; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/intersim2 ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/intersim2; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuobjdump_to_ptxplus ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuobjdump_to_ptxplus; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch/cacti ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch/cacti; fi;
make -C ./src/cuda-sim/ depend
make[1]: Entering directory '/path/to/me/gpgpu-sim_distribution/src/cuda-sim'
make[1]: Warning: File '/path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend' has modification time 178 s in the future
touch /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend
makedepend -f/path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend -p/path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/ cuda_device_printf.cc cuda_device_runtime.cc cuda-sim.cc instructions.cc memory.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc ptx-stats.cc 2> /dev/null
make[1]: *** [Makefile:76: depend] Error 127
make[1]: Leaving directory '/path/to/me/gpgpu-sim_distribution/src/cuda-sim'
make: *** [Makefile:207: cuda-sim] Error 2
I rebuild the errors using gcc-11.3.1, and i have the same error:
[xxx@lab gpgpu-sim_distribution]$ make
Building GPGPU-Sim version 4.0.0 (build gpgpu-sim_git-commit-90ec3399763d7c8512cfe7dc193473086c38ca38_modified_2.0) with CUDA version 11.7
if [ ! -d lib/gcc-11.3.1/cuda-11070/release ]; then mkdir -p lib/gcc-11.3.1/cuda-11070/release; fi;
if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libcuda ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libcuda; fi;
if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim; fi;
if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/decuda_pred_table ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/decuda_pred_table; fi;
if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpgpu-sim ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpgpu-sim; fi;
if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libopencl ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libopencl; fi;
if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libopencl/bin ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libopencl/bin; fi;
if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/intersim2 ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/intersim2; fi;
if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuobjdump_to_ptxplus ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuobjdump_to_ptxplus; fi;
if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpuwattch ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpuwattch; fi;
if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpuwattch/cacti ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpuwattch/cacti; fi;
make -C ./src/cuda-sim/ depend
make[1]: Entering directory '/home/xxx/gpgpu-sim_distribution/src/cuda-sim'
touch /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/Makefile.makedepend
makedepend -f/home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/Makefile.makedepend -p/home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/ cuda-sim.cc cuda_device_printf.cc cuda_device_runtime.cc instructions.cc memory.cc ptx-stats.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc 2> /dev/null
make[1]: *** [Makefile:76: depend] Error 127
make[1]: Leaving directory '/home/xxx/gpgpu-sim_distribution/src/cuda-sim'
make: *** [Makefile:207: cuda-sim] Error 2
This error occurs in the https://github.com/gpgpu-sim/gpgpu-sim_distribution/blob/90ec3399763d7c8512cfe7dc193473086c38ca38/src/cuda-sim/Makefile#L76C1-L76C1 :
depend:
touch $(OUTPUT_DIR)/Makefile.makedepend
makedepend -f$(OUTPUT_DIR)/Makefile.makedepend -p$(OUTPUT_DIR)/ $(SRCS) 2> /dev/null
Makedepend just build dependencies on some cpp files under cuda-sim. After I comment out this line, the errors have been skipped but new errors occured:
gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/ptx_parser_decode.def:2:11: error: unable to find string literal operator ‘operator""end’ with ‘const char [30]’, ‘long unsigned int’ arguments
2 | DEF(YYEOF,"YYEOF /* "end of file" */")
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The reason is that the version of gcc-11.3.1 is too high to compile the code. So lower your gcc version.
I rebuild the errors using gcc-11.3.1, and i have the same error:
[xxx@lab gpgpu-sim_distribution]$ make Building GPGPU-Sim version 4.0.0 (build gpgpu-sim_git-commit-90ec3399763d7c8512cfe7dc193473086c38ca38_modified_2.0) with CUDA version 11.7 if [ ! -d lib/gcc-11.3.1/cuda-11070/release ]; then mkdir -p lib/gcc-11.3.1/cuda-11070/release; fi; if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libcuda ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libcuda; fi; if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim; fi; if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/decuda_pred_table ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/decuda_pred_table; fi; if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpgpu-sim ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpgpu-sim; fi; if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libopencl ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libopencl; fi; if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libopencl/bin ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/libopencl/bin; fi; if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/intersim2 ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/intersim2; fi; if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuobjdump_to_ptxplus ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuobjdump_to_ptxplus; fi; if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpuwattch ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpuwattch; fi; if [ ! -d /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpuwattch/cacti ]; then mkdir -p /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/gpuwattch/cacti; fi; make -C ./src/cuda-sim/ depend make[1]: Entering directory '/home/xxx/gpgpu-sim_distribution/src/cuda-sim' touch /home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/Makefile.makedepend makedepend -f/home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/Makefile.makedepend -p/home/xxx/gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/ cuda-sim.cc cuda_device_printf.cc cuda_device_runtime.cc instructions.cc memory.cc ptx-stats.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc 2> /dev/null make[1]: *** [Makefile:76: depend] Error 127 make[1]: Leaving directory '/home/xxx/gpgpu-sim_distribution/src/cuda-sim' make: *** [Makefile:207: cuda-sim] Error 2
This error occurs in the https://github.com/gpgpu-sim/gpgpu-sim_distribution/blob/90ec3399763d7c8512cfe7dc193473086c38ca38/src/cuda-sim/Makefile#L76C1-L76C1 :
depend: touch $(OUTPUT_DIR)/Makefile.makedepend makedepend -f$(OUTPUT_DIR)/Makefile.makedepend -p$(OUTPUT_DIR)/ $(SRCS) 2> /dev/null
Makedepend just build dependencies on some cpp files under cuda-sim. After I comment out this line, the errors have been skipped but new errors occured:
gpgpu-sim_distribution/build/gcc-11.3.1/cuda-11070/release/cuda-sim/ptx_parser_decode.def:2:11: error: unable to find string literal operator ‘operator""end’ with ‘const char [30]’, ‘long unsigned int’ arguments 2 | DEF(YYEOF,"YYEOF /* "end of file" */") | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The reason is that the version of gcc-11.3.1 is too high to compile the code. So lower your gcc version.
It is not the gcc version issue. The solution is patching the make file.
Replace gpgpu-sim/src/cuda-sim/Makefile: L131-135
with
ifeq ($(shell uname),Linux)
cat $(OUTPUT_DIR)/ptx.tab.h | grep "=" | sed 's/^[ ]\+//' | sed 's/[=,]//g' | sed 's/\([_A-Z1-9]\+\)[ ]\+\([0-9]\+\)/\1 \1/' | sed 's/"/\\"/g' | sed 's/^/DEF(/' | sed 's/ /,"/' | sed 's/$$/")/' > $(OUTPUT_DIR)/ptx_parser_decode.def
else
cat $(OUTPUT_DIR)/ptx.tab.h | grep "=" | sed -E 's/^ +//' | sed 's/[=,]//g' | sed -E 's/([_A-Z1-9]+).*/\1 \1/' | sed 's/"/\\"/g' |sed 's/^/DEF(/' | sed 's/ /,"/' | sed 's/$$/")/' > $(OUTPUT_DIR)/ptx_parser_decode.def
endif
This change simply added the escape to the quote symbol.
It is not the gcc version issue. The solution is patching the make file.
Replace gpgpu-sim/src/cuda-sim/Makefile: L131-135
with
ifeq ($(shell uname),Linux) cat $(OUTPUT_DIR)/ptx.tab.h | grep "=" | sed 's/^[ ]\+//' | sed 's/[=,]//g' | sed 's/\([_A-Z1-9]\+\)[ ]\+\([0-9]\+\)/\1 \1/' | sed 's/"/\\"/g' | sed 's/^/DEF(/' | sed 's/ /,"/' | sed 's/$$/")/' > $(OUTPUT_DIR)/ptx_parser_decode.def else cat $(OUTPUT_DIR)/ptx.tab.h | grep "=" | sed -E 's/^ +//' | sed 's/[=,]//g' | sed -E 's/([_A-Z1-9]+).*/\1 \1/' | sed 's/"/\\"/g' |sed 's/^/DEF(/' | sed 's/ /,"/' | sed 's/$$/")/' > $(OUTPUT_DIR)/ptx_parser_decode.def endif
This change simply added the escape to the quote symbol.
No luck after making the change, GCC version still not being detected correctly, still showing as gcc-/cuda
:
make
Building GPGPU-Sim version 4.0.0 (build gpgpu-sim_git-commit-90ec3399763d7c8512cfe7dc193473086c38ca38_modified_1.0) with CUDA version 11.7
if [ ! -d lib/gcc-/cuda-11070/release ]; then mkdir -p lib/gcc-/cuda-11070/release; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libcuda ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libcuda; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/decuda_pred_table ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/decuda_pred_table; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpgpu-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpgpu-sim; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl/bin ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl/bin; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/intersim2 ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/intersim2; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch/cacti ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch/cacti; fi;
make -C ./src/cuda-sim/ depend
make[1]: Entering directory '/path/to/me/gpgpu-sim_distribution/src/cuda-sim'
make[1]: Warning: File 'Makefile' has modification time 28 s in the future
touch /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend
makedepend -f/path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend -p/path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/ cuda_device_printf.cc cuda_device_runtime.cc cuda-sim.cc instructions.cc memory.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc ptx-stats.cc 2> /dev/null
Makefile:150: /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend: No such file or directory
make[1]: *** [Makefile:76: depend] Error 127
make[1]: Leaving directory '/path/to/me/gpgpu-sim_distribution/src/cuda-sim'
make: *** [Makefile:207: cuda-sim] Error 2
I tried to hard code 11.2.1 in the Makefile
:
[Building GPGPU-Sim version 4.0.0 (build gpgpu-sim_git-commit-90ec3399763d7c8512cfe7dc193473086c38ca38_modified_2.0) with CUDA version 11.7
if [ ! -d lib/gcc-11.2.1/cuda-11070/release ]; then mkdir -p lib/gcc-11.2.1/cuda-11070/release; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libcuda ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libcuda; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/decuda_pred_table ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/decuda_pred_table; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpgpu-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpgpu-sim; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl/bin ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl/bin; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/intersim2 ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/intersim2; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuobjdump_to_ptxplus ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuobjdump_to_ptxplus; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch; fi;
if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch/cacti ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch/cacti; fi;
make -C ./src/cuda-sim/ depend
make[1]: Entering directory '/path/to/me/gpgpu-sim_distribution/src/cuda-sim'
touch /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend
makedepend -f/path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend -p/path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/ cuda_device_printf.cc cuda_device_runtime.cc cuda-sim.cc instructions.cc memory.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc ptx-stats.cc 2> /dev/null
Makefile:150: /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend: No such file or directory
make[1]: *** [Makefile:76: depend] Error 127
make[1]: Leaving directory '/path/to/me/gpgpu-sim_distribution/src/cuda-sim'
make: *** [Makefile:207: cuda-sim] Error 2](url)
Then a subsequent make has this:
make -C ./src/cuda-sim/ depend
make[1]: Entering directory '/manitou-home/home/rk3199/gpgpu-sim_distribution/src/cuda-sim'
touch /manitou-home/home/rk3199/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend
makedepend -f/manitou-home/home/rk3199/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend -p/manitou-home/home/rk3199/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/ cuda_device_printf.cc cuda_device_runtime.cc cuda-sim.cc instructions.cc memory.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc ptx-stats.cc 2> /dev/null
make[1]: *** [Makefile:76: depend] Error 127
make[1]: Leaving directory '/manitou-home/home/rk3199/gpgpu-sim_distribution/src/cuda-sim'
make: *** [Makefile:207: cuda-sim] Error 2
these exist:
ls -l build/gcc-11.2.1/cuda-11070/release/
total 32
drwxr-xr-x 3 me user 4096 Dec 1 13:37 cuda-sim
drwxr-xr-x 2 me user 4096 Dec 1 13:37 cuobjdump_to_ptxplus
-rw-r--r-- 1 me user 114 Dec 1 2023 detailed_version
drwxr-xr-x 2 me user 4096 Dec 1 13:37 gpgpu-sim
drwxr-xr-x 3 me user 4096 Dec 1 13:37 gpuwattch
drwxr-xr-x 2 me user 4096 Dec 1 13:37 intersim2
drwxr-xr-x 2 me user 4096 Dec 1 13:37 libcuda
drwxr-xr-x 3 me user 4096 Dec 1 13:37 libopencl
It is not the gcc version issue. The solution is patching the make file. Replace gpgpu-sim/src/cuda-sim/Makefile: L131-135 with
ifeq ($(shell uname),Linux) cat $(OUTPUT_DIR)/ptx.tab.h | grep "=" | sed 's/^[ ]\+//' | sed 's/[=,]//g' | sed 's/\([_A-Z1-9]\+\)[ ]\+\([0-9]\+\)/\1 \1/' | sed 's/"/\\"/g' | sed 's/^/DEF(/' | sed 's/ /,"/' | sed 's/$$/")/' > $(OUTPUT_DIR)/ptx_parser_decode.def else cat $(OUTPUT_DIR)/ptx.tab.h | grep "=" | sed -E 's/^ +//' | sed 's/[=,]//g' | sed -E 's/([_A-Z1-9]+).*/\1 \1/' | sed 's/"/\\"/g' |sed 's/^/DEF(/' | sed 's/ /,"/' | sed 's/$$/")/' > $(OUTPUT_DIR)/ptx_parser_decode.def endif
This change simply added the escape to the quote symbol.
No luck after making the change, GCC version still not being detected correctly, still showing as
gcc-/cuda
:make Building GPGPU-Sim version 4.0.0 (build gpgpu-sim_git-commit-90ec3399763d7c8512cfe7dc193473086c38ca38_modified_1.0) with CUDA version 11.7 if [ ! -d lib/gcc-/cuda-11070/release ]; then mkdir -p lib/gcc-/cuda-11070/release; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libcuda ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libcuda; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/decuda_pred_table ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/decuda_pred_table; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpgpu-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpgpu-sim; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl/bin ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/libopencl/bin; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/intersim2 ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/intersim2; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch/cacti ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/gpuwattch/cacti; fi; make -C ./src/cuda-sim/ depend make[1]: Entering directory '/path/to/me/gpgpu-sim_distribution/src/cuda-sim' make[1]: Warning: File 'Makefile' has modification time 28 s in the future touch /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend makedepend -f/path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend -p/path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/ cuda_device_printf.cc cuda_device_runtime.cc cuda-sim.cc instructions.cc memory.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc ptx-stats.cc 2> /dev/null Makefile:150: /path/to/me/gpgpu-sim_distribution/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend: No such file or directory make[1]: *** [Makefile:76: depend] Error 127 make[1]: Leaving directory '/path/to/me/gpgpu-sim_distribution/src/cuda-sim' make: *** [Makefile:207: cuda-sim] Error 2
I tried to hard code 11.2.1 in the
Makefile
:[Building GPGPU-Sim version 4.0.0 (build gpgpu-sim_git-commit-90ec3399763d7c8512cfe7dc193473086c38ca38_modified_2.0) with CUDA version 11.7 if [ ! -d lib/gcc-11.2.1/cuda-11070/release ]; then mkdir -p lib/gcc-11.2.1/cuda-11070/release; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libcuda ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libcuda; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/decuda_pred_table ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/decuda_pred_table; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpgpu-sim ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpgpu-sim; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl/bin ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/libopencl/bin; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/intersim2 ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/intersim2; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuobjdump_to_ptxplus ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuobjdump_to_ptxplus; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch; fi; if [ ! -d /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch/cacti ]; then mkdir -p /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/gpuwattch/cacti; fi; make -C ./src/cuda-sim/ depend make[1]: Entering directory '/path/to/me/gpgpu-sim_distribution/src/cuda-sim' touch /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend makedepend -f/path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend -p/path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/ cuda_device_printf.cc cuda_device_runtime.cc cuda-sim.cc instructions.cc memory.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc ptx-stats.cc 2> /dev/null Makefile:150: /path/to/me/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend: No such file or directory make[1]: *** [Makefile:76: depend] Error 127 make[1]: Leaving directory '/path/to/me/gpgpu-sim_distribution/src/cuda-sim' make: *** [Makefile:207: cuda-sim] Error 2](url)
Then a subsequent make has this:
make -C ./src/cuda-sim/ depend make[1]: Entering directory '/manitou-home/home/rk3199/gpgpu-sim_distribution/src/cuda-sim' touch /manitou-home/home/rk3199/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend makedepend -f/manitou-home/home/rk3199/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/Makefile.makedepend -p/manitou-home/home/rk3199/gpgpu-sim_distribution/build/gcc-11.2.1/cuda-11070/release/cuda-sim/ cuda_device_printf.cc cuda_device_runtime.cc cuda-sim.cc instructions.cc memory.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc ptx-stats.cc 2> /dev/null make[1]: *** [Makefile:76: depend] Error 127 make[1]: Leaving directory '/manitou-home/home/rk3199/gpgpu-sim_distribution/src/cuda-sim' make: *** [Makefile:207: cuda-sim] Error 2
these exist:
ls -l build/gcc-11.2.1/cuda-11070/release/ total 32 drwxr-xr-x 3 me user 4096 Dec 1 13:37 cuda-sim drwxr-xr-x 2 me user 4096 Dec 1 13:37 cuobjdump_to_ptxplus -rw-r--r-- 1 me user 114 Dec 1 2023 detailed_version drwxr-xr-x 2 me user 4096 Dec 1 13:37 gpgpu-sim drwxr-xr-x 3 me user 4096 Dec 1 13:37 gpuwattch drwxr-xr-x 2 me user 4096 Dec 1 13:37 intersim2 drwxr-xr-x 2 me user 4096 Dec 1 13:37 libcuda drwxr-xr-x 3 me user 4096 Dec 1 13:37 libopencl
https://github.com/wuye9036/gpgpu-sim/tree/wuye/mask_out_warnings
You can try my branch. Smoked benchmark from accel-sim on GCC-11.4 & CUDA 11.8.
I think that might be caused by missing xutils-dev
package. Try to reinstall it by your package manager.
@SomePersonSomeWhereInTheWorld Please remember to call source setup_environment
before invoking make all
I installed xorg-x11-utils (Centos/RHEL equivalent to xutils-dev), same error and I used your branch. Still not parsing the version of GCC, notice the build/gcc-/cuda-11070
:
Building GPGPU-Sim version 4.2.0 (build gpgpu-sim_git-commit-857fc8_modified_0.0) with CUDA version 11.7
if [ ! -d lib/gcc-/cuda-11070/release ]; then mkdir -p lib/gcc-/cuda-11070/release; fi;
if [ ! -d /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/libcuda ]; then mkdir -p /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/libcuda; fi;
if [ ! -d /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuda-sim ]; then mkdir -p /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuda-sim; fi;
if [ ! -d /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuda-sim/decuda_pred_table ]; then mkdir -p /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuda-sim/decuda_pred_table; fi;
if [ ! -d /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/gpgpu-sim ]; then mkdir -p /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/gpgpu-sim; fi;
if [ ! -d /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/libopencl ]; then mkdir -p /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/libopencl; fi;
if [ ! -d /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/libopencl/bin ]; then mkdir -p /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/libopencl/bin; fi;
if [ ! -d /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/intersim2 ]; then mkdir -p /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/intersim2; fi;
if [ ! -d /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus ]; then mkdir -p /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus; fi;
if [ ! -d /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/accelwattch ]; then mkdir -p /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/accelwattch; fi;
if [ ! -d /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/accelwattch/cacti ]; then mkdir -p /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/accelwattch/cacti; fi;
make -C ./src/cuda-sim/ depend
make[1]: Entering directory '/path/to/me/gpgpu-sim/src/cuda-sim'
make[1]: Warning: File '/path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend' has modification time 85 s in the future
touch /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend
makedepend -f/path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuda-sim/Makefile.makedepend -p/path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuda-sim/ cuda_device_printf.cc cuda_device_runtime.cc cuda-sim.cc instructions.cc memory.cc ptx_ir.cc ptx_loader.cc ptx_parser.cc ptx_sim.cc ptx-stats.cc 2> /dev/null
make[1]: *** [Makefile:79: depend] Error 127
make[1]: Leaving directory '/path/to/me/gpgpu-sim/src/cuda-sim'
make: *** [Makefile:207: cuda-sim] Error 2
Hmmm you may forget the code that you have cloned and try this fork:
git@github.com:accel-sim/gpgpu-sim_distribution.git
Then change the branch to dev and build it. This fork contains lots of fixes and forks.
Hmmm you may forget the code that you have cloned and try this fork:
git@github.com:accel-sim/gpgpu-sim_distribution.git
Then change the branch to dev and build it. This fork contains lots of fixes and forks.
I'm not following. Can you provide the commands to do this?
Hmmm you may forget the code that you have cloned and try this fork: git@github.com:accel-sim/gpgpu-sim_distribution.git Then change the branch to dev and build it. This fork contains lots of fixes and forks.
I'm not following. Can you provide the commands to do this
Please ensure that makedepend
is installed correctly on your system.
Use the command yum search makedepend
to determine which package includes makedepend
.
After identifying the package, install it, and then use the command which makedepend
to confirm that makedepend
has been installed correctly.
Once this is done, try building it again.
Please ensure that
makedepend
is installed correctly on your system. Use the commandyum search makedepend
to determine which package includesmakedepend
. After identifying the package, install it, and then use the commandwhich makedepend
to confirm thatmakedepend
has been installed correctly.Once this is done, try building it again.
Indeed, no makedepend, which is a part of imake in RHEL/CentOS, now at least make completes:
make[1]: warning: Clock skew detected. Your build may be incomplete.
make[1]: Leaving directory '/path/to/me/gpgpu-sim/cuobjdump_to_ptxplus'
Still doesn't put the path with the correct GCC version:
/path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus/elf_lexer.o /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus/elf_parser.o
Please ensure that
makedepend
is installed correctly on your system. Use the commandyum search makedepend
to determine which package includesmakedepend
. After identifying the package, install it, and then use the commandwhich makedepend
to confirm thatmakedepend
has been installed correctly. Once this is done, try building it again.Indeed, no makedepend, which is a part of imake in RHEL/CentOS, now at least make completes: make[1]: warning: Clock skew detected. Your build may be incomplete. make[1]: Leaving directory '/path/to/me/gpgpu-sim/cuobjdump_to_ptxplus'
Still doesn't put the path with the correct GCC version:
/path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus/elf_lexer.o /path/to/me/gpgpu-sim/build/gcc-/cuda-11070/release/cuobjdump_to_ptxplus/elf_parser.o
it doesn't affect the use of gpgpu-sim. If you wanna to fix it, you can modify the gpgpu-sim/setup_environment:L47 from
CC_VERSION=`gcc --version | head -1 | awk '{for(i=1;i<=NF;i++){ if(match($i,/^[0-9]\.[0-9]\.[0-9]$/)) {print $i; exit 0}}}'`
to
CC_VERSION=`gcc --version | head -1 | awk '{for(i=1;i<=NF;i++){ if(match($i,/^[0-9]+\.[0-9]\.[0-9]$/)) {print $i; exit 0}}}'`
And apply this changes into version_detection.mk
.
Perhaps, learning a bit shell
and makefile
could help you address any compilation issues you might encounter in the future.
I thought I had all of the dependencies but perhaps not. Pardon the path obfuscation. From what I found
xorg-x11-utils
is the RHEL/CentOS equivalent forxutils
.RHEL 9, cuda11.8/toolkit/11.8.0 in a Bright HPC cluster.