[Openmp-dev] ptxas fatal : Cannot take address of function '__pthread_key_create'

Jonas Hahnfeld via Openmp-dev openmp-dev at lists.llvm.org
Tue Sep 4 23:56:26 PDT 2018


Mabye you are using some thread-local storage? Can you share the code, 
everything else will be guesses at best...

Jonas

On 2018-09-05 06:15, Itaru Kitayama via Openmp-dev wrote:
> Hi Alexey,
> If the function is not explicitly used in the code-base in question,
> how do I
> find which function/module requires it?
> 
> On Tue, Sep 4, 2018 at 11:15 PM Alexey Bataev <a.bataev at outlook.com>
> wrote:
> 
>> It means that this function is used somewhere in the code that is
>> offloaded to the GPU. I don't think this is correct, this function
>> is pthreads-specific and I don't think that NVidia GPUs support
>> pthreads.
>> 
>> -------------
>> Best regards,
>> Alexey Bataev
>> 
>> 02.09.2018 3:51, Itaru Kitayama via Openmp-dev пишет:
>> 
>>> 
>> 
>>> Hi,
>>> I am trying to build an application that can do OpenMP offloading
>>> on a POWER8 + P100 system using the latest LLVM/Clang toolchain
>>> (openmp
>>> is too the latest).
>>> 
>>> The build error is:
>>> 
>>> [  3%] Building CXX object
>>> sli/CMakeFiles/sli_lib.dir/arraydatum.cc.o
>>> cd /gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/sli &&
>>> /gpfs/work/pcp0/pcp0151/opt/llvm+clang-upstream/bin/clang++
>>> -Dsli_lib_EXPORTS -I/bgsys/drivers/ppcfloor/comm/gcc/include
>>> -I/gpfs/software/opt/gsl/2.4/include
>>> -I/gpfs/homeb/pcp0/pcp0151/projects/nest-simulator/libnestutil
>>> -I/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/libnestutil
>>> -std=c++11 -O2 -Wall -fopenmp -fopenmp-targets=nvptx64-nvidia-cuda
>>> --cuda-path=/gpfs/software/opt/cuda/9.2.88  -fPIC   -o
>>> CMakeFiles/sli_lib.dir/arraydatum.cc.o -c
>>> /gpfs/homeb/pcp0/pcp0151/projects/nest-simulator/sli/arraydatum.cc
>>> 
>>> ptxas fatal   : Cannot take address of function
>>> '__pthread_key_create'
>>> clang-8: error: ptxas command failed with exit code 255 (use -v to
>>> see invocation)
>>> make[2]: *** [sli/CMakeFiles/sli_lib.dir/arraydatum.cc.o] Error
>>> 255
>>> make[2]: Leaving directory
>>> `/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream'
>>> make[1]: *** [sli/CMakeFiles/sli_lib.dir/all] Error 2
>>> make[1]: Leaving directory
>>> `/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream'
>>> make: *** [all] Error 2
>>> 
>>> The CUDA toolkit is 9.2.88, is it possible the error is fixed in
>>> the
>>> latest toolkit?
>>> 
>>> Thanks,
>>> Itaru.
>> 
>>> _______________________________________________
>>> Openmp-dev mailing list
>>> Openmp-dev at lists.llvm.org
>>> http://lists.llvm.org/cgi-bin/mailman/listinfo/openmp-dev
> _______________________________________________
> Openmp-dev mailing list
> Openmp-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/openmp-dev


More information about the Openmp-dev mailing list