Add "hasSection" flag in the Summary

Reviewers: tejohnson

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D19405

From: Mehdi Amini <mehdi.amini@apple.com>

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@267329 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Mehdi Amini
2016-04-24 05:31:43 +00:00
parent 3f71db1efb
commit 822155bcb5
4 changed files with 32 additions and 5 deletions

View File

@@ -745,7 +745,9 @@ static GlobalValueSummary::GVFlags getDecodedGVSummaryFlags(uint64_t RawFlags,
// like getDecodedLinkage() above. Any future change to the linkage enum and
// to getDecodedLinkage() will need to be taken into account here as above.
auto Linkage = GlobalValue::LinkageTypes(RawFlags & 0xF); // 4 bits
return GlobalValueSummary::GVFlags(Linkage);
RawFlags = RawFlags >> 4;
auto HasSection = RawFlags & 0x1; // bool
return GlobalValueSummary::GVFlags(Linkage, HasSection);
}
static GlobalValue::VisibilityTypes getDecodedVisibility(unsigned Val) {