<div dir="ltr">CMake compiler check fails:<div><br></div><div><div>Determining if files mach-o/dyld.h exist failed with the following output:</div><div>Change Dir: /gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/CMakeFiles/CMakeTmp</div><div><br></div><div>Run Build Command:"/usr/bin/gmake" "cmTC_1486a/fast"</div><div>/usr/bin/gmake -f CMakeFiles/cmTC_1486a.dir/build.make CMakeFiles/cmTC_1486a.dir/build</div><div>gmake[1]: Entering directory `/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/CMakeFiles/CMak</div><div>eTmp'</div><div>Building C object CMakeFiles/cmTC_1486a.dir/CheckIncludeFiles.c.o</div><div>/gpfs/work/pcp0/pcp0151/opt/llvm+clang-upstream/bin/clang        -o CMakeFiles/cmTC_1486a.dir/C</div><div>heckIncludeFiles.c.o -c /gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/CMakeFiles/CMakeTmp/C</div><div>heckIncludeFiles.c</div><div>/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/CMakeFiles/CMakeTmp/CheckIncludeFiles.c:2:10:</div><div> fatal error: 'mach-o/dyld.h' file not found</div><div>#include <mach-o/dyld.h></div><div>         ^~~~~~~~~~~~~~~</div><div>1 error generated.</div><div>gmake[1]: *** [CMakeFiles/cmTC_1486a.dir/CheckIncludeFiles.c.o] Error 1</div><div>gmake[1]: Leaving directory `/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/CMakeFiles/CMake</div><div>Tmp'</div><div>gmake: *** [cmTC_1486a/fast] Error 2</div><div><br></div><div>Source:</div><div>/* */</div><div>#include <mach-o/dyld.h></div><div><br></div><div><br></div><div>int main(void){return 0;}</div><div><br></div><div>Determining if files mach/mach.h exist failed with the following output:</div><div>Change Dir: /gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/CMakeFiles/CMakeTmp</div><div><br></div><div>Run Build Command:"/usr/bin/gmake" "cmTC_a088b/fast"</div><div>/usr/bin/gmake -f CMakeFiles/cmTC_a088b.dir/build.make CMakeFiles/cmTC_a088b.dir/build</div><div>gmake[1]: Entering directory `/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/CMakeFiles/CMak</div><div>eTmp'</div><div>Building C object CMakeFiles/cmTC_a088b.dir/CheckIncludeFiles.c.o</div><div>/gpfs/work/pcp0/pcp0151/opt/llvm+clang-upstream/bin/clang        -o CMakeFiles/cmTC_a088b.dir/C</div><div>heckIncludeFiles.c.o -c /gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/CMakeFiles/CMakeTmp/C</div><div>heckIncludeFiles.c</div><div>/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/CMakeFiles/CMakeTmp/CheckIncludeFiles.c:2:10:</div><div> fatal error: 'mach/mach.h' file not found</div><div>#include <mach/mach.h></div><div>         ^~~~~~~~~~~~~</div><div>1 error generated.</div><div>gmake[1]: *** [CMakeFiles/cmTC_a088b.dir/CheckIncludeFiles.c.o] Error 1</div><div>gmake[1]: Leaving directory `/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/CMakeFiles/CMakeTmp'</div><div><br></div><div class="gmail_quote"><div dir="ltr">On Wed, Sep 5, 2018 at 7:01 PM Jonas Hahnfeld <<a href="mailto:hahnjo@hahnjo.de">hahnjo@hahnjo.de</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I can't reproduce the problem on x86, at least on this file on branch <br>
master and for-upstream. Maybe it's specific to Power?<br>
<br>
Can you have a look where this function is called? Extending the compile <br>
command for that specific file by "-S -emit-llvm" and posting the result <br>
would be helpful.<br>
<br>
Jonas<br>
<br>
On 2018-09-05 11:20, Itaru Kitayama wrote:<br>
> Jonas,<br>
> No problem. It is at:<br>
> <br>
> <a href="https://github.com/ikitayama/nest-simulator" rel="noreferrer" target="_blank">https://github.com/ikitayama/nest-simulator</a><br>
> <br>
> ... and especially this file<br>
> <br>
> <a href="https://github.com/ikitayama/nest-simulator/blob/master/sli/arraydatum.cc" rel="noreferrer" target="_blank">https://github.com/ikitayama/nest-simulator/blob/master/sli/arraydatum.cc</a><br>
> <br>
> is the first one on which llvm/clang-8.0.0 stops in a build process.<br>
> <br>
> On Wed, Sep 5, 2018 at 3:56 PM Jonas Hahnfeld <<a href="mailto:hahnjo@hahnjo.de" target="_blank">hahnjo@hahnjo.de</a>><br>
> wrote:<br>
> <br>
>> Mabye you are using some thread-local storage? Can you share the<br>
>> code,<br>
>> everything else will be guesses at best...<br>
>> <br>
>> Jonas<br>
>> <br>
>> On 2018-09-05 06:15, Itaru Kitayama via Openmp-dev wrote:<br>
>>> Hi Alexey,<br>
>>> If the function is not explicitly used in the code-base in<br>
>> question,<br>
>>> how do I<br>
>>> find which function/module requires it?<br>
>>> <br>
>>> On Tue, Sep 4, 2018 at 11:15 PM Alexey Bataev<br>
>> <<a href="mailto:a.bataev@outlook.com" target="_blank">a.bataev@outlook.com</a>><br>
>>> wrote:<br>
>>> <br>
>>>> It means that this function is used somewhere in the code that is<br>
>>>> offloaded to the GPU. I don't think this is correct, this<br>
>> function<br>
>>>> is pthreads-specific and I don't think that NVidia GPUs support<br>
>>>> pthreads.<br>
>>>> <br>
>>>> -------------<br>
>>>> Best regards,<br>
>>>> Alexey Bataev<br>
>>>> <br>
>>>> 02.09.2018 3:51, Itaru Kitayama via Openmp-dev пишет:<br>
>>>> <br>
>>>>> <br>
>>>> <br>
>>>>> Hi,<br>
>>>>> I am trying to build an application that can do OpenMP<br>
>> offloading<br>
>>>>> on a POWER8 + P100 system using the latest LLVM/Clang toolchain<br>
>>>>> (openmp<br>
>>>>> is too the latest).<br>
>>>>> <br>
>>>>> The build error is:<br>
>>>>> <br>
>>>>> [  3%] Building CXX object<br>
>>>>> sli/CMakeFiles/sli_lib.dir/arraydatum.cc.o<br>
>>>>> cd /gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/sli &&<br>
>>>>> /gpfs/work/pcp0/pcp0151/opt/llvm+clang-upstream/bin/clang++<br>
>>>>> -Dsli_lib_EXPORTS -I/bgsys/drivers/ppcfloor/comm/gcc/include<br>
>>>>> -I/gpfs/software/opt/gsl/2.4/include<br>
>>>>> -I/gpfs/homeb/pcp0/pcp0151/projects/nest-simulator/libnestutil<br>
>>>>> -I/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream/libnestutil<br>
>>>>> -std=c++11 -O2 -Wall -fopenmp<br>
>> -fopenmp-targets=nvptx64-nvidia-cuda<br>
>>>>> --cuda-path=/gpfs/software/opt/cuda/9.2.88  -fPIC   -o<br>
>>>>> CMakeFiles/sli_lib.dir/arraydatum.cc.o -c<br>
>>>>> <br>
>> /gpfs/homeb/pcp0/pcp0151/projects/nest-simulator/sli/arraydatum.cc<br>
>>>>> <br>
>>>>> ptxas fatal   : Cannot take address of function<br>
>>>>> '__pthread_key_create'<br>
>>>>> clang-8: error: ptxas command failed with exit code 255 (use -v<br>
>> to<br>
>>>>> see invocation)<br>
>>>>> make[2]: *** [sli/CMakeFiles/sli_lib.dir/arraydatum.cc.o] Error<br>
>>>>> 255<br>
>>>>> make[2]: Leaving directory<br>
>>>>> `/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream'<br>
>>>>> make[1]: *** [sli/CMakeFiles/sli_lib.dir/all] Error 2<br>
>>>>> make[1]: Leaving directory<br>
>>>>> `/gpfs/work/pcp0/pcp0151/build/nest-clang-upstream'<br>
>>>>> make: *** [all] Error 2<br>
>>>>> <br>
>>>>> The CUDA toolkit is 9.2.88, is it possible the error is fixed in<br>
>>>>> the<br>
>>>>> latest toolkit?<br>
>>>>> <br>
>>>>> Thanks,<br>
>>>>> Itaru.<br>
>>>> <br>
>>>>> _______________________________________________<br>
>>>>> Openmp-dev mailing list<br>
>>>>> <a href="mailto:Openmp-dev@lists.llvm.org" target="_blank">Openmp-dev@lists.llvm.org</a><br>
>>>>> <a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/openmp-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/openmp-dev</a><br>
>>> _______________________________________________<br>
>>> Openmp-dev mailing list<br>
>>> <a href="mailto:Openmp-dev@lists.llvm.org" target="_blank">Openmp-dev@lists.llvm.org</a><br>
>>> <a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/openmp-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/openmp-dev</a><br>
</blockquote></div></div></div>