[ThinLTO] Revert r325320: Import global variables
authorChandler Carruth <chandlerc@gmail.com>
Fri, 2 Mar 2018 23:40:08 +0000 (23:40 +0000)
committerChandler Carruth <chandlerc@gmail.com>
Fri, 2 Mar 2018 23:40:08 +0000 (23:40 +0000)
commita4619d9944c7e54c421582c7dc592ae051d8bf51
tree972ffb5b5cb34231ee60cf68d4acc028eee71bcb
parentdbf75c9c79910f8b99b2a273d886d8db3ff9b93e
[ThinLTO] Revert r325320: Import global variables

This caused some links to fail with ThinLTO due to missing symbols as
well as causing some binaries to have failures at runtime. We're working
with the author to get a test case, but want to get the tree green
again.

Further, it appears to introduce a data race. While the test usage of
threads was disabled in r325361 & r325362, that isn't an acceptable fix.
I've reverted both of these as well. This code needs to be thread safe.
Test cases for this are already on the original commit thread.

llvm-svn: 326638
llvm/lib/Linker/IRMover.cpp
llvm/lib/Transforms/IPO/FunctionImport.cpp
llvm/test/ThinLTO/X86/Inputs/globals-import-cf-baz.ll [deleted file]
llvm/test/ThinLTO/X86/globals-import-const-fold.ll [deleted file]
llvm/test/Transforms/FunctionImport/funcimport.ll
llvm/test/Transforms/PGOProfile/thinlto_samplepgo_icp3.ll