about summary refs log tree commit diff
path: root/src/libstd/sys/unix/stack_overflow.rs
diff options
context:
space:
mode:
authorMazdak Farrokhzad <twingoow@gmail.com>2019-04-14 00:39:44 +0200
committerGitHub <noreply@github.com>2019-04-14 00:39:44 +0200
commit7ff376b3b27d2e5c5c01b336924bcc3e507e5c4d (patch)
tree78ad46500c21bb3cad0f686c2ae348b115f39b93 /src/libstd/sys/unix/stack_overflow.rs
parentc4a3332d38c6c92394b5f7818f0a963fbcf86052 (diff)
parent724ca0584e2be0714edf2f30b86230666d7a9d19 (diff)
downloadrust-7ff376b3b27d2e5c5c01b336924bcc3e507e5c4d.tar.gz
rust-7ff376b3b27d2e5c5c01b336924bcc3e507e5c4d.zip
Rollup merge of #59812 - michaelwoerister:profile-gen-msvc-imp, r=alexcrichton
Exclude profiler-generated symbols from MSVC __imp_-symbol workaround.

LLVM's profiling instrumentation adds a few symbols that are used by the profiler runtime. Since these show up as globals in the LLVM IR, the compiler generates `dllimport`-related `__imp_` stubs for them. This can lead to linker errors because the instrumentation symbols have weak linkage or are in a comdat section, but the `__imp_` stubs aren't.

Instead of trying to replicate the linkage/comdat setup for the stubs, this PR just excludes the profiler-related symbols from stub-generation since they aren't supposed to be referenced via `__declspec(dllimport)` anywhere anyway.

r? @alexcrichton

EDIT: I considered making this more general, i.e. inferring from the symbol name if it is a Rust symbol or not. But then I figured out that that would yield false negatives for `#[no_mangle]` et al, so I went with a blacklist approach.
Diffstat (limited to 'src/libstd/sys/unix/stack_overflow.rs')
0 files changed, 0 insertions, 0 deletions