NVIDIA-Genomics-Research / GenomeWorks

SDK for GPU accelerated genome assembly and analysis
https://clara-parabricks.github.io/GenomeWorks/
Apache License 2.0
278 stars 76 forks source link

How to fix cudaErrorInvalidDeviceFunction exception for cudamapper #655

Closed wzboy1984 closed 3 years ago

wzboy1984 commented 3 years ago

Hi,

When I ran "cudamapper 1.fasta 2.fasta", I met with an error "cudaErrorInvalidDeviceFunction". The screen shows below:

Initialized GenomeWorks logger with log level ERROR -C / --target-indices-in-host-memory not set, using -Q / --query-indices-in-host-memory value: 10 -c / --target-indices-in-device-memory not set, using -q / --query-indices-in-device-memory value: 5 Query file: 1.fasta, number of reads: 1 Target file: 2.fasta, number of reads: 1 Programmatically looking for max cached memory Using device memory cache of 12493416039 bytes Device 0 took batch 1 out of 1 batches in total terminate called after throwing an instance of 'thrust::system::system_error' what(): scan failed on 2nd step: cudaErrorInvalidDeviceFunction: invalid device function Aborted (core dumped)

Also, I tried to run the test cases for cudamapper, 19 tests failed with the below exception:

... [----------] 5 tests from TestCudamapperIndexCaching [ RUN ] TestCudamapperIndexCaching.test_index_cache_same_query_and_target unknown file: Failure C++ exception with description "scan failed on 2nd step: cudaErrorInvalidDeviceFunction: invalid device function" thrown in the test body. [ FAILED ] TestCudamapperIndexCaching.test_index_cache_same_query_and_target (20 ms) ...

My linux system is Ubuntu 21.04. My GenomeWorks program is the lastest dev version (9fd8232). My cuda version is 11.3.
My GPU is GTX 1080ti and arch flag for compilation is 6.1. What should I do to fix the problem described above?

wzboy1984 commented 3 years ago

I fixed the problem by changing cuda 11.3 to cuda 10.2.