Mitch Phillips via llvm-dev
2021-May-17 17:34 UTC
[llvm-dev] Linking error with Dataflow sanitizer
Removing the dfs$ prefix from the mangled name, the symbol that's missing is std::exception::what(), which normally comes from libc++abi. Are you sure that libc++abi.so contains the dfsan-prefixed symbol and your link line order is correct? On my machine: $ ninja cxx cxxabi && nm lib/libc++abi.so.1.0 | grep exception | grep what 000000000011cd60 T dfs$_ZNKSt13bad_exception4whatEv 000000000011cc90 T dfs$_ZNKSt9exception4whatEv On Mon, May 17, 2021 at 9:02 AM floris westermann via llvm-dev < llvm-dev at lists.llvm.org> wrote:> Hi everyone, > > I am currently trying to compile a project with the Dataflow sanitizer. > I have recompiled the libcxx and other dependencies using the sanitizer > and the libc++abi. > > The libraries are linked dynamically but when I try to execute the binary > I get the following error: > ```symbol lookup error: ./Variane_testharness: undefined symbol: > dfs$_ZNKSt9exception4whatEv``` > > The project is a verilog project that is translated to CPP with verilator. > > Does anyone know how I can resolve this? > > Cheers, > Floris > _______________________________________________ > LLVM Developers mailing list > llvm-dev at lists.llvm.org > https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20210517/0952aa17/attachment.html>
floris westermann via llvm-dev
2021-May-18 10:42 UTC
[llvm-dev] Linking error with Dataflow sanitizer
Hi Mitch, I checked the lib and the symbols seem to be present: $ nm /usr/local/lib/libc++.so.1.0 | grep exception | grep what 0000000000236554 T dfs$_ZNKSt13bad_exception4whatEv 0000000000236538 T dfs$_ZNKSt9exception4whatEv What should be the link order? On Mon, 17 May 2021 at 19:34, Mitch Phillips <mitchp at google.com> wrote:> Removing the dfs$ prefix from the mangled name, the symbol that's missing > is std::exception::what(), which normally comes from libc++abi. Are you > sure that libc++abi.so contains the dfsan-prefixed symbol and your link > line order is correct? > > On my machine: > > $ ninja cxx cxxabi && nm lib/libc++abi.so.1.0 | grep exception | grep what > 000000000011cd60 T dfs$_ZNKSt13bad_exception4whatEv > 000000000011cc90 T dfs$_ZNKSt9exception4whatEv > > On Mon, May 17, 2021 at 9:02 AM floris westermann via llvm-dev < > llvm-dev at lists.llvm.org> wrote: > >> Hi everyone, >> >> I am currently trying to compile a project with the Dataflow sanitizer. >> I have recompiled the libcxx and other dependencies using the sanitizer >> and the libc++abi. >> >> The libraries are linked dynamically but when I try to execute the binary >> I get the following error: >> ```symbol lookup error: ./Variane_testharness: undefined symbol: >> dfs$_ZNKSt9exception4whatEv``` >> >> The project is a verilog project that is translated to CPP with verilator. >> >> Does anyone know how I can resolve this? >> >> Cheers, >> Floris >> _______________________________________________ >> LLVM Developers mailing list >> llvm-dev at lists.llvm.org >> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev >> >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20210518/8282c691/attachment.html>