Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"carlsim/kernel/inc/snn.h:1128:2: error: ‘StopWatchInterface’ does not name a type;" build error #18

Open
Runkli opened this issue Feb 26, 2022 · 2 comments

Comments

@Runkli
Copy link

Runkli commented Feb 26, 2022

When doing make after cloning the repo, I get the following error:

In file included from carlsim/kernel/src/snn_cpu_module.cpp:50:
carlsim/kernel/inc/snn.h:1128:2: error: ‘StopWatchInterface’ does not name a type; did you mean ‘UpdateInterval’?
StopWatchInterface* timer;

@rsdmse
Copy link

rsdmse commented Apr 6, 2022

I got the same error. I resolved it by making the following edits:

  • carlsim/configure.mk line 95: use the actual directory of cuda samples common
  • carlsim/kernel/inc/snn.h line 94: add #include <helper_timer.h>
  • carlsim/kernel/src/snn_manager.cpp line 65: add #include <cuda_version_control.h>
#9 26.81 /usr/local/cuda/bin/nvcc -ccbin g++  -c -I/usr/local/cuda/samples/common -Icarlsim/interface/inc -Icarlsim/kernel/inc -Icarlsim/monitor -Itools/simple_weight_tuner -Itools/spike_generators -Itools/stopwatch -Itools/visual_stimulus -Itools/pti -m64 -D__CUDA10__ -gencode arch=compute_35,code=sm_35 -gencode arch=compute_60,code=sm_60 -gencode arch=compute_70,code=sm_70 -Wno-deprecated-gpu-targets -gencode arch=compute_60,code=sm_60 -gencode arch=compute_61,code=sm_61 -gencode arch=compute_70,code=sm_70 --compiler-options "-O3 -ffast-math" carlsim/kernel/src/gpu_module/snn_gpu_module.cu -o carlsim/kernel/src/gpu_module/snn_gpu_module-cu.o
#9 34.28 ar rcs libcarlsim.a.5.0.0   carlsim/kernel/src/snn_cpu_module-cpp.o  carlsim/kernel/src/snn_manager-cpp.o  carlsim/kernel/src/spike_buffer-cpp.o  carlsim/kernel/src/print_snn_info-cpp.o  carlsim/interface/src/callback_core-cpp.o  carlsim/interface/src/linear_algebra-cpp.o  carlsim/interface/src/user_errors-cpp.o  carlsim/interface/src/carlsim-cpp.o  carlsim/interface/src/poisson_rate-cpp.o  carlsim/monitor/group_monitor-cpp.o  carlsim/monitor/group_monitor_core-cpp.o  carlsim/monitor/spike_monitor-cpp.o  carlsim/monitor/spike_monitor_core-cpp.o  carlsim/monitor/neuron_monitor-cpp.o  carlsim/monitor/neuron_monitor_core-cpp.o  carlsim/monitor/connection_monitor-cpp.o  carlsim/monitor/connection_monitor_core-cpp.o   tools/simple_weight_tuner/simple_weight_tuner.o  tools/spike_generators/spikegen_from_file.o  tools/spike_generators/interactive_spikegen.o  tools/spike_generators/pre_post_group_spikegen.o  tools/spike_generators/spikegen_from_vector.o  tools/spike_generators/periodic_spikegen.o  tools/stopwatch/stopwatch.o  tools/visual_stimulus/visual_stimulus.o  tools/pti/ParameterInstances.o  tools/pti/PTI.o  tools/pti/Logger.o  tools/pti/Util.o   carlsim/kernel/src/gpu_module/snn_gpu_module-cu.o   
#9 34.31 CARLsim5 library path: /usr/local/lib
#9 34.31 CARLsim5 include path: /usr/local/include
#9 34.34 CARLsim 5.0.0 successfully installed.

@lwy-599
Copy link

lwy-599 commented Aug 9, 2022

Followding the above steps,make again yields the following error:
/usr/local/cuda-11.4/bin/nvcc -ccbin g++ -c -Iusr/local/cuda-11.4/samples/common/inc -Icarlsim/interface/inc -Icarlsim/kernel/inc -Icarlsim/monitor -Itools/simple_weight_tuner -Itools/spike_generators -Itools/stopwatch -Itools/visual_stimulus -Itools/pti -m64 -D__CUDA11__ -gencode arch=compute_35,code=sm_35 -gencode arch=compute_50,code=sm_50 -gencode arch=compute_52,code=sm_52 -Wno-deprecated-gpu-targets -gencode arch=compute_60,code=sm_60 -gencode arch=compute_61,code=sm_61 -gencode arch=compute_70,code=sm_70 --compiler-options "-O3 -ffast-math" carlsim/kernel/src/gpu_module/snn_gpu_module.cu -o carlsim/kernel/src/gpu_module/snn_gpu_module-cu.o
/usr/include/stdio.h(189): error: attribute "malloc" does not take arguments

/usr/include/stdio.h(201): error: attribute "malloc" does not take arguments

/usr/include/stdio.h(223): error: attribute "malloc" does not take arguments

/usr/include/stdio.h(260): error: attribute "malloc" does not take arguments

/usr/include/stdio.h(285): error: attribute "malloc" does not take arguments

/usr/include/stdio.h(294): error: attribute "malloc" does not take arguments

/usr/include/stdio.h(303): error: attribute "malloc" does not take arguments

/usr/include/stdio.h(309): error: attribute "malloc" does not take arguments

/usr/include/stdio.h(315): error: attribute "malloc" does not take arguments

/usr/include/stdio.h(830): error: attribute "malloc" does not take arguments

/usr/include/stdlib.h(566): error: attribute "malloc" does not take arguments

/usr/include/stdlib.h(570): error: attribute "malloc" does not take arguments

/usr/include/stdlib.h(799): error: attribute "malloc" does not take arguments

/usr/include/wchar.h(155): error: attribute "malloc" does not take arguments

/usr/include/wchar.h(582): error: attribute "malloc" does not take arguments

carlsim/kernel/src/gpu_module/snn_gpu_module.cu(1583): warning: function "tex1Dfetch(texture<T, 1, cudaReadModeElementType>, int) [with T=int]"
/usr/local/cuda-11.4/bin/../targets/x86_64-linux/include/texture_fetch_functions.h(132): here was declared deprecated

carlsim/kernel/src/gpu_module/snn_gpu_module.cu(1586): warning: function "tex1Dfetch(texture<T, 1, cudaReadModeElementType>, int) [with T=int]"
/usr/local/cuda-11.4/bin/../targets/x86_64-linux/include/texture_fetch_functions.h(132): here was declared deprecated

carlsim/kernel/src/gpu_module/snn_gpu_module.cu(1606): warning: function "tex1Dfetch(texture<T, 1, cudaReadModeElementType>, int) [with T=int]"
/usr/local/cuda-11.4/bin/../targets/x86_64-linux/include/texture_fetch_functions.h(132): here was declared deprecated

carlsim/kernel/src/gpu_module/snn_gpu_module.cu(1607): warning: function "tex1Dfetch(texture<T, 1, cudaReadModeElementType>, int) [with T=int]"
/usr/local/cuda-11.4/bin/../targets/x86_64-linux/include/texture_fetch_functions.h(132): here was declared deprecated

15 errors detected in the compilation of "carlsim/kernel/src/gpu_module/snn_gpu_module.cu".
make: *** [carlsim/carlsim.mk:187:carlsim/kernel/src/gpu_module/snn_gpu_module-cu.o] 错误 1
I can't install successfully.could you tell me how to solve this problem?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants