diff options
| author | bors <bors@rust-lang.org> | 2018-11-26 12:14:13 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2018-11-26 12:14:13 +0000 |
| commit | 6bfb46e4ac9a2704f06de1a2ff7a4612cd70c8cb (patch) | |
| tree | b41fb59406c53b5d9a249b41541946285a3f7ef1 | |
| parent | b51632e3f0856ea444f5e59819538e85947673fc (diff) | |
| parent | 7215963e56321c5e92b9c2f7c4ad788362451b37 (diff) | |
| download | rust-6bfb46e4ac9a2704f06de1a2ff7a4612cd70c8cb.tar.gz rust-6bfb46e4ac9a2704f06de1a2ff7a4612cd70c8cb.zip | |
Auto merge of #55835 - alexcrichton:llvm-upgrade, r=nikomatsakis
Upgrade LLVM to trunk, still version 8 This commit upgrades the LLVM/LLD/compiler-rt submodules used to the current trunk versions in upstream. Some activity has happened on the wasm SIMD side of things as well as LLD which we'd like to pick up!
| -rw-r--r-- | .travis.yml | 6 | ||||
| m--------- | src/libcompiler_builtins | 0 | ||||
| -rw-r--r-- | src/librustc_codegen_ssa/back/linker.rs | 11 | ||||
| m--------- | src/llvm | 0 | ||||
| -rw-r--r-- | src/rustllvm/PassWrapper.cpp | 8 | ||||
| -rw-r--r-- | src/rustllvm/RustWrapper.cpp | 6 | ||||
| m--------- | src/tools/lld | 0 |
7 files changed, 27 insertions, 4 deletions
diff --git a/.travis.yml b/.travis.yml index 14fb17aeedd..fa66220f442 100644 --- a/.travis.yml +++ b/.travis.yml @@ -30,7 +30,7 @@ matrix: - env: > RUST_CHECK_TARGET=dist - RUST_CONFIGURE_ARGS="--enable-extended --enable-profiler --enable-lldb --set rust.jemalloc" + RUST_CONFIGURE_ARGS="--enable-extended --enable-profiler --set rust.jemalloc" SRC=. DEPLOY_ALT=1 RUSTC_RETRY_LINKER_ON_SEGFAULT=1 @@ -87,7 +87,7 @@ matrix: # OSX 10.7 and `xcode7` is the latest Xcode able to compile LLVM for 10.7. - env: > RUST_CHECK_TARGET=dist - RUST_CONFIGURE_ARGS="--build=i686-apple-darwin --enable-full-tools --enable-profiler --enable-lldb --set rust.jemalloc" + RUST_CONFIGURE_ARGS="--build=i686-apple-darwin --enable-full-tools --enable-profiler --set rust.jemalloc" SRC=. DEPLOY=1 RUSTC_RETRY_LINKER_ON_SEGFAULT=1 @@ -102,7 +102,7 @@ matrix: - env: > RUST_CHECK_TARGET=dist - RUST_CONFIGURE_ARGS="--target=aarch64-apple-ios,armv7-apple-ios,armv7s-apple-ios,i386-apple-ios,x86_64-apple-ios --enable-full-tools --enable-sanitizers --enable-profiler --enable-lldb --set rust.jemalloc" + RUST_CONFIGURE_ARGS="--target=aarch64-apple-ios,armv7-apple-ios,armv7s-apple-ios,i386-apple-ios,x86_64-apple-ios --enable-full-tools --enable-sanitizers --enable-profiler --set rust.jemalloc" SRC=. DEPLOY=1 RUSTC_RETRY_LINKER_ON_SEGFAULT=1 diff --git a/src/libcompiler_builtins b/src/libcompiler_builtins -Subproject 939cbca6e9d829265d6cf006d3532142a4061cd +Subproject fe74674f6e4be76d47b66f67d529ebf4186f4eb diff --git a/src/librustc_codegen_ssa/back/linker.rs b/src/librustc_codegen_ssa/back/linker.rs index ec5ca580104..f3cc344254f 100644 --- a/src/librustc_codegen_ssa/back/linker.rs +++ b/src/librustc_codegen_ssa/back/linker.rs @@ -1037,6 +1037,17 @@ impl<'a> Linker for WasmLd<'a> { // indicative of bugs, let's prevent them. self.cmd.arg("--fatal-warnings"); + // The symbol visibility story is a bit in flux right now with LLD. + // It's... not entirely clear to me what's going on, but this looks to + // make everything work when `export_symbols` isn't otherwise called for + // things like executables. + self.cmd.arg("--export-dynamic"); + + // LLD only implements C++-like demangling, which doesn't match our own + // mangling scheme. Tell LLD to not demangle anything and leave it up to + // us to demangle these symbols later. + self.cmd.arg("--no-demangle"); + ::std::mem::replace(&mut self.cmd, Command::new("")) } diff --git a/src/llvm b/src/llvm -Subproject 7051ead40a5f825878b59bf08d4e768be9e99a4 +Subproject 21a0c9ebc285d794a298e97717abad8d6135fa8 diff --git a/src/rustllvm/PassWrapper.cpp b/src/rustllvm/PassWrapper.cpp index 3b0046222a9..06de0d6509b 100644 --- a/src/rustllvm/PassWrapper.cpp +++ b/src/rustllvm/PassWrapper.cpp @@ -922,7 +922,11 @@ LLVMRustCreateThinLTOData(LLVMRustThinLTOModule *modules, GlobalValue::LinkageTypes NewLinkage) { ResolvedODR[ModuleIdentifier][GUID] = NewLinkage; }; +#if LLVM_VERSION_GE(8, 0) + thinLTOResolvePrevailingInIndex(Ret->Index, isPrevailing, recordNewLinkage); +#else thinLTOResolveWeakForLinkerInIndex(Ret->Index, isPrevailing, recordNewLinkage); +#endif // Here we calculate an `ExportedGUIDs` set for use in the `isExported` // callback below. This callback below will dictate the linkage for all @@ -977,7 +981,11 @@ extern "C" bool LLVMRustPrepareThinLTOResolveWeak(const LLVMRustThinLTOData *Data, LLVMModuleRef M) { Module &Mod = *unwrap(M); const auto &DefinedGlobals = Data->ModuleToDefinedGVSummaries.lookup(Mod.getModuleIdentifier()); +#if LLVM_VERSION_GE(8, 0) + thinLTOResolvePrevailingInModule(Mod, DefinedGlobals); +#else thinLTOResolveWeakForLinkerModule(Mod, DefinedGlobals); +#endif return true; } diff --git a/src/rustllvm/RustWrapper.cpp b/src/rustllvm/RustWrapper.cpp index f423503e19f..b6e07942f86 100644 --- a/src/rustllvm/RustWrapper.cpp +++ b/src/rustllvm/RustWrapper.cpp @@ -708,7 +708,11 @@ extern "C" LLVMMetadataRef LLVMRustDIBuilderCreateStaticVariable( llvm::DIGlobalVariableExpression *VarExpr = Builder->createGlobalVariableExpression( unwrapDI<DIDescriptor>(Context), Name, LinkageName, unwrapDI<DIFile>(File), LineNo, unwrapDI<DIType>(Ty), IsLocalToUnit, - InitExpr, unwrapDIPtr<MDNode>(Decl), AlignInBits); + InitExpr, unwrapDIPtr<MDNode>(Decl), +#if LLVM_VERSION_GE(8, 0) + /* templateParams */ nullptr, +#endif + AlignInBits); InitVal->setMetadata("dbg", VarExpr); diff --git a/src/tools/lld b/src/tools/lld -Subproject 2a9b88b8b419d094fb2185c0ca31c28d31bdca0 +Subproject 1928c5eeb613a4c6d232fc47ae91914bbfd92a7 |
