DebugInfo: change alignment type from uint64_t to uint32_t to save space.

In futher patches we shall have alignment field added to DIVariable family
and switching from uint64_t to uint32_t will save 4 bytes per variable.

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



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284482 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Victor Leschuk
2016-10-18 14:31:22 +00:00
parent 05fe9f3914
commit 58be60c483
13 changed files with 120 additions and 116 deletions

View File

@@ -2497,7 +2497,9 @@ std::error_code BitcodeReader::parseMetadata(bool ModuleLevel) {
Metadata *Scope = getDITypeRefOrNull(Record[5]);
Metadata *BaseType = getDITypeRefOrNull(Record[6]);
uint64_t SizeInBits = Record[7];
uint64_t AlignInBits = Record[8];
if (Record[8] > (uint64_t)std::numeric_limits<uint32_t>::max())
return error("Alignment value is too large");
uint32_t AlignInBits = Record[8];
uint64_t OffsetInBits = Record[9];
DINode::DIFlags Flags = static_cast<DINode::DIFlags>(Record[10]);
Metadata *Elements = getMDOrNull(Record[11]);