aboutsummaryrefslogtreecommitdiff
path: root/lib/Bytecode
diff options
context:
space:
mode:
authorMisha Brukman <brukman+llvm@gmail.com>2004-11-14 21:02:55 +0000
committerMisha Brukman <brukman+llvm@gmail.com>2004-11-14 21:02:55 +0000
commita3e6ad62f372afcc47075d407c81e694d56e8918 (patch)
treeb6d9c58d99c1a92cb598c55f2716b591fbe280a4 /lib/Bytecode
parentf2cdf5e934dcedfdfb3c595b01761471a0ca883c (diff)
Mark an unmaterialized function as having GhostLinkage
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17748 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Bytecode')
-rw-r--r--lib/Bytecode/Reader/Reader.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Bytecode/Reader/Reader.cpp b/lib/Bytecode/Reader/Reader.cpp
index 18399c1db3..0984e8e073 100644
--- a/lib/Bytecode/Reader/Reader.cpp
+++ b/lib/Bytecode/Reader/Reader.cpp
@@ -1735,6 +1735,10 @@ void BytecodeReader::ParseFunctionLazily() {
// Save the information for future reading of the function
LazyFunctionLoadMap[Func] = LazyFunctionInfo(BlockStart, BlockEnd);
+ // This function has a body but it's not loaded so it appears `External'.
+ // Mark it as a `Ghost' instead to notify the users that it has a body.
+ Func->setLinkage(GlobalValue::GhostLinkage);
+
// Pretend we've `parsed' this function
At = BlockEnd;
}