IR: Represent -ggnu-pubnames with a flag on the DICompileUnit.

This allows the flag to be persisted through to LTO.

Differential Revision: https://reviews.llvm.org/D37655

llvm-svn: 313078
This commit is contained in:
Peter Collingbourne
2017-09-12 21:50:41 +00:00
parent 3ffe632777
commit 88b490f5b6
20 changed files with 186 additions and 174 deletions
+3 -2
View File
@@ -1355,7 +1355,7 @@ Error MetadataLoader::MetadataLoaderImpl::parseOneMetadata(
break;
}
case bitc::METADATA_COMPILE_UNIT: {
if (Record.size() < 14 || Record.size() > 18)
if (Record.size() < 14 || Record.size() > 19)
return error("Invalid record");
// Ignore Record[0], which indicates whether this compile unit is
@@ -1369,7 +1369,8 @@ Error MetadataLoader::MetadataLoaderImpl::parseOneMetadata(
Record.size() <= 15 ? nullptr : getMDOrNull(Record[15]),
Record.size() <= 14 ? 0 : Record[14],
Record.size() <= 16 ? true : Record[16],
Record.size() <= 17 ? false : Record[17]);
Record.size() <= 17 ? false : Record[17],
Record.size() <= 18 ? false : Record[18]);
MetadataList.assignValue(CU, NextMetadataNo);
NextMetadataNo++;