summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
diff options
context:
space:
mode:
authorTimur Iskhodzhanov <timurrrr@google.com>2015-01-16 08:38:45 +0000
committerTimur Iskhodzhanov <timurrrr@google.com>2015-01-16 08:38:45 +0000
commit60b721363c86ef4712aa26652ed6cbcd9768c3f9 (patch)
treecae8ca8d3c34df2ca31636f7d60f6609e9fc5f44 /llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
parent24b04aa393d683404aec0e77a5d3915ed8f65eb0 (diff)
downloadbcm5719-llvm-60b721363c86ef4712aa26652ed6cbcd9768c3f9.tar.gz
bcm5719-llvm-60b721363c86ef4712aa26652ed6cbcd9768c3f9.zip
Revert r226242 - Revert Revert Don't create new comdats in CodeGen
This breaks AddressSanitizer (ninja check-asan) on Windows llvm-svn: 226251
Diffstat (limited to 'llvm/lib/Bitcode/Writer/BitcodeWriter.cpp')
-rw-r--r--llvm/lib/Bitcode/Writer/BitcodeWriter.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp b/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
index 960a7922cd8..5e8c64ee9cd 100644
--- a/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
+++ b/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
@@ -480,13 +480,13 @@ static unsigned getEncodedLinkage(const GlobalValue &GV) {
case GlobalValue::ExternalLinkage:
return 0;
case GlobalValue::WeakAnyLinkage:
- return 16;
+ return 1;
case GlobalValue::AppendingLinkage:
return 2;
case GlobalValue::InternalLinkage:
return 3;
case GlobalValue::LinkOnceAnyLinkage:
- return 18;
+ return 4;
case GlobalValue::ExternalWeakLinkage:
return 7;
case GlobalValue::CommonLinkage:
@@ -494,9 +494,9 @@ static unsigned getEncodedLinkage(const GlobalValue &GV) {
case GlobalValue::PrivateLinkage:
return 9;
case GlobalValue::WeakODRLinkage:
- return 17;
+ return 10;
case GlobalValue::LinkOnceODRLinkage:
- return 19;
+ return 11;
case GlobalValue::AvailableExternallyLinkage:
return 12;
}
@@ -629,7 +629,7 @@ static void WriteModuleInfo(const Module *M, const ValueEnumerator &VE,
Log2_32_Ceil(MaxGlobalType+1)));
Abbv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 1)); // Constant.
Abbv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::VBR, 6)); // Initializer.
- Abbv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 5)); // Linkage.
+ Abbv->Add(BitCodeAbbrevOp(BitCodeAbbrevOp::Fixed, 4)); // Linkage.
if (MaxAlignment == 0) // Alignment.
Abbv->Add(BitCodeAbbrevOp(0));
else {
OpenPOWER on IntegriCloud