[compiler-rt] r240586 - One more change required to build the sanitizers for iOS.

Alexey Samsonov vonosmas at gmail.com
Fri Jun 26 11:22:05 PDT 2015


Hi Kuba,

Right, I think you need to #ifdef out calls to slow unwinder if
SANITIZER_CAN_SLOW_UNWIND is 0.

On Fri, Jun 26, 2015 at 1:10 AM, Kuba Brecka <kuba.brecka at gmail.com> wrote:

> Hi Chris,
> this seems to break my OS X build of compiler-rt:
>
> $ ninja
> [16/57] Linking CXX shared library
> lib/clang/3.7.0/lib/darwin/libclang_rt.ubsan_osx_dynamic.dylib
> FAILED: : && /usr/bin/c++  -fPIC ... -o
> lib/clang/3.7.0/lib/darwin/libclang_rt.ubsan_osx_dynamic.dylib ...
> Undefined symbols for architecture x86_64:
>   "__sanitizer::BufferedStackTrace::SlowUnwindStack(unsigned long,
> unsigned int)", referenced from:
>       __sanitizer::BufferedStackTrace::Unwind(unsigned int, unsigned long,
> unsigned long, void*, unsigned long, unsigned long, bool) in
> sanitizer_stacktrace_libcdep.cc.o
>   "__sanitizer::BufferedStackTrace::SlowUnwindStackWithContext(unsigned
> long, void*, unsigned int)", referenced from:
>       __sanitizer::BufferedStackTrace::Unwind(unsigned int, unsigned long,
> unsigned long, void*, unsigned long, unsigned long, bool) in
> sanitizer_stacktrace_libcdep.cc.o
> ld: symbol(s) not found for architecture x86_64
> clang: error: linker command failed with exit code 1 (use -v to see
> invocation)
>
> Note that my CMake configuration is `-DCMAKE_BUILD_TYPE=Debug
> -DCOMPILER_RT_DEBUG=On`, which looks like is the reason why the buildbots
> build fine.  They build the release version, and here call to
> `SlowUnwindStack` is optimized out.
>
> Kuba
>
> Author: cbieneman
> Date: Wed Jun 24 15:13:44 2015
> New Revision: 240586
>
> URL: http://llvm.org/viewvc/llvm-project?rev=240586&view=rev <https://urldefense.proofpoint.com/v2/url?u=http-3A__llvm.org_viewvc_llvm-2Dproject-3Frev-3D240586-26view-3Drev&d=AwMFAg&c=8hUWFZcy2Z-Za5rBPlktOQ&r=mQ4LZ2PUj9hpadE3cDHZnIdEwhEBrbAstXeMaFoB9tg&m=6KJ7cDTjsYPUJQVgmelmOXAbPH4HH2QA55wrK90Y86A&s=CYFzT-bjdm2O1oJDi6WcL-RRDoh6gOpa4SVC6tAxKq4&e=>
> Log:
> One more change required to build the sanitizers for iOS.
>
> Summary: _Unwind_Backtrace is not available on iOS, so we should ifdef out the posix implementations of BufferedStackTrace::SlowUnwindStack and BufferedStackTrace::SlowUnwindStackWithContext on iOS.
>
> Reviewers: samsonov
>
> Reviewed By: samsonov
>
> Subscribers: llvm-commits
>
> Differential Revision: http://reviews.llvm.org/D10696 <https://urldefense.proofpoint.com/v2/url?u=http-3A__reviews.llvm.org_D10696&d=AwMFAg&c=8hUWFZcy2Z-Za5rBPlktOQ&r=mQ4LZ2PUj9hpadE3cDHZnIdEwhEBrbAstXeMaFoB9tg&m=6KJ7cDTjsYPUJQVgmelmOXAbPH4HH2QA55wrK90Y86A&s=Spp0vkTnrAn8MapkKglYt7RTCGmkSeSfbf7kbVnF1Ig&e=>
>
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
>


-- 
Alexey Samsonov
vonosmas at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150626/6f5d45e0/attachment.html>


More information about the llvm-commits mailing list