[PATCH] D108095: [profile] Don't use pragma comment linker on mingw

Nikita Popov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 16 00:18:48 PDT 2021


nikic added a comment.

In D108095#2945822 <https://reviews.llvm.org/D108095#2945822>, @mstorsjo wrote:

> Btw, to understand your setup - you're building compiler-rt/profile as part of building clang, via e.g. `LLVM_ENABLE_PROJECTS` (so it ends up being built with the existing host compiler, GCC) but then compile code using the clang and using the newly built compiler-rt/profile library with the newly built clang?

We're compiling the profile runtime for use with rustc. The runtime gets compiled using the host compiler and then linked with programs built by rustc with the newly built LLVM. Clang is never built.

In D108095#2945825 <https://reviews.llvm.org/D108095#2945825>, @mstorsjo wrote:

> Sorry, I’m a bit slow today: I presume the situation is that this setup used to work fine, when doing profiled builds with clang, when linking with ld.bfd - but now it no longer does. But sanitizers have always required that they (the compiler-rt code) are built with clang (e.g. with LLVM_ENABLE_RUNTIMES, or entirely manually/separately) and linked with lld.

Is that a mingw-specific requirement? I don't think sanitizers for other platforms need to be be built with clang or linked with lld. We don't support sanitizers on mingw right now, so we may not have run into that issue.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D108095/new/

https://reviews.llvm.org/D108095



More information about the llvm-commits mailing list