summaryrefslogtreecommitdiff
path: root/lib/Bitcode/Reader
diff options
context:
space:
mode:
authorMichael Gottesman <mgottesman@apple.com>2013-02-05 05:57:38 +0000
committerMichael Gottesman <mgottesman@apple.com>2013-02-05 05:57:38 +0000
commita2de37c897556fbd1f94a3ed84ad27accd8f8deb (patch)
treeaf34d39baab0faa1b905d84b643c765f734e9aed /lib/Bitcode/Reader
parent91b978e15774039f991cf91048dc4cc74726744b (diff)
downloadllvm-a2de37c897556fbd1f94a3ed84ad27accd8f8deb.tar.gz
llvm-a2de37c897556fbd1f94a3ed84ad27accd8f8deb.tar.bz2
llvm-a2de37c897556fbd1f94a3ed84ad27accd8f8deb.tar.xz
Added LLVM Asm/Bitcode Reader/Writer support for new IR keyword externally_initialized.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174340 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Bitcode/Reader')
-rw-r--r--lib/Bitcode/Reader/BitcodeReader.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/Bitcode/Reader/BitcodeReader.cpp b/lib/Bitcode/Reader/BitcodeReader.cpp
index 6ab7011187..e10e6d6476 100644
--- a/lib/Bitcode/Reader/BitcodeReader.cpp
+++ b/lib/Bitcode/Reader/BitcodeReader.cpp
@@ -1596,9 +1596,13 @@ bool BitcodeReader::ParseModule(bool Resume) {
if (Record.size() > 8)
UnnamedAddr = Record[8];
+ bool ExternallyInitialized = false;
+ if (Record.size() > 9)
+ ExternallyInitialized = Record[9];
+
GlobalVariable *NewGV =
new GlobalVariable(*TheModule, Ty, isConstant, Linkage, 0, "", 0,
- TLM, AddressSpace);
+ TLM, AddressSpace, ExternallyInitialized);
NewGV->setAlignment(Alignment);
if (!Section.empty())
NewGV->setSection(Section);