Have the bitcode writer and reader handle the new attribute references.

The bitcode writer emits a reference to the attribute group that the object at
the given index refers to. The bitcode reader is modified to read this in and
map it back to the attribute group.

llvm-svn: 174952
This commit is contained in:
Bill Wendling committed 2013-02-12 08:13:50 +00:00
1 parent a096b14d1d
commit 0dc08915d2
2 files changed
+11 -33

No files matched your search

@@ -494,6 +494,14 @@ bool BitcodeReader::ParseAttributeBlock() {
Attrs.clear();
break;
}
case bitc::PARAMATTR_CODE_ENTRY: { // ENTRY: [attrgrp0, attrgrp1, ...]
for (unsigned i = 0, e = Record.size(); i != e; ++i)
Attrs.push_back(MAttributeGroups[Record[i]]);
MAttributes.push_back(AttributeSet::get(Context, Attrs));
Attrs.clear();
break;
}
}
}
}