Author: dim Date: Sun Dec 8 13:56:26 2013 New Revision: 259100 URL: http://svnweb.freebsd.org/changeset/base/259100
Log: Pull in r196658 from upstream clang trunk: CodeGen: Don't emit linkage on thunks that aren't emitted because they're vararg. This can happen when we're trying to emit a thunk with available_externally linkage with optimization enabled but bail because it doesn't make sense for vararg functions. [LLVM] PR18098. This should fix clang "Broken module found, compilation aborted" errors when building the qt4-based dvbcut port. Reported by: se MFC after: 3 days Modified: head/contrib/llvm/tools/clang/lib/CodeGen/CGVTables.cpp Modified: head/contrib/llvm/tools/clang/lib/CodeGen/CGVTables.cpp ============================================================================== --- head/contrib/llvm/tools/clang/lib/CodeGen/CGVTables.cpp Sun Dec 8 13:46:27 2013 (r259099) +++ head/contrib/llvm/tools/clang/lib/CodeGen/CGVTables.cpp Sun Dec 8 13:56:26 2013 (r259100) @@ -454,10 +454,9 @@ void CodeGenVTables::EmitThunk(GlobalDec } else { // Normal thunk body generation. CodeGenFunction(CGM).GenerateThunk(ThunkFn, FnInfo, GD, Thunk); + if (UseAvailableExternallyLinkage) + ThunkFn->setLinkage(llvm::GlobalValue::AvailableExternallyLinkage); } - - if (UseAvailableExternallyLinkage) - ThunkFn->setLinkage(llvm::GlobalValue::AvailableExternallyLinkage); } void CodeGenVTables::MaybeEmitThunkAvailableExternally(GlobalDecl GD, _______________________________________________ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"