diff options
author | Dale Johannesen <dalej@apple.com> | 2008-05-14 20:12:51 +0000 |
---|---|---|
committer | Dale Johannesen <dalej@apple.com> | 2008-05-14 20:12:51 +0000 |
commit | aafce77b17d340aace52bcd49d1944109d82f14a (patch) | |
tree | e7d1caf5f9d6c359802174c4a01644b9aa326202 /lib/Bitcode | |
parent | 50871247216dfef8386a112766e972a1792b0b56 (diff) |
Add CommonLinkage; currently tentative definitions
are represented as "weak", but there are subtle differences
in some cases on Darwin, so we need both. The intent
is that "common" will behave identically to "weak" unless
somebody changes their target to do something else.
No functional change as yet.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51118 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Bitcode')
-rw-r--r-- | lib/Bitcode/Reader/BitcodeReader.cpp | 1 | ||||
-rw-r--r-- | lib/Bitcode/Writer/BitcodeWriter.cpp | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/lib/Bitcode/Reader/BitcodeReader.cpp b/lib/Bitcode/Reader/BitcodeReader.cpp index 40982666f0..2d421b4b9e 100644 --- a/lib/Bitcode/Reader/BitcodeReader.cpp +++ b/lib/Bitcode/Reader/BitcodeReader.cpp @@ -66,6 +66,7 @@ static GlobalValue::LinkageTypes GetDecodedLinkage(unsigned Val) { case 5: return GlobalValue::DLLImportLinkage; case 6: return GlobalValue::DLLExportLinkage; case 7: return GlobalValue::ExternalWeakLinkage; + case 8: return GlobalValue::CommonLinkage; } } diff --git a/lib/Bitcode/Writer/BitcodeWriter.cpp b/lib/Bitcode/Writer/BitcodeWriter.cpp index 40e70115d9..8e9a395ab6 100644 --- a/lib/Bitcode/Writer/BitcodeWriter.cpp +++ b/lib/Bitcode/Writer/BitcodeWriter.cpp @@ -270,6 +270,7 @@ static unsigned getEncodedLinkage(const GlobalValue *GV) { case GlobalValue::DLLImportLinkage: return 5; case GlobalValue::DLLExportLinkage: return 6; case GlobalValue::ExternalWeakLinkage: return 7; + case GlobalValue::CommonLinkage: return 8; } } |