1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 03:53:04 +02:00

[PGO] Fix build errors in x86_64-darwin

Fix buildbot failure for x86_64-darwin due to r254021

llvm-svn: 254028
This commit is contained in:
Rong Xu 2015-11-24 21:55:50 +00:00
parent 4168a65f41
commit f74fb8bb95
2 changed files with 3 additions and 3 deletions

View File

@ -97,7 +97,7 @@ public:
uint64_t BBWeight = BFI->getBlockFreq(&*BB).getFrequency();
uint64_t Weight;
if (int successors = TI->getNumSuccessors()) {
for (uint32_t i = 0; i != successors; ++i) {
for (int i = 0; i != successors; ++i) {
BasicBlock *TargetBB = TI->getSuccessor(i);
bool Critical = isCriticalEdge(TI, i);
uint64_t scaleFactor = BBWeight;

View File

@ -264,8 +264,8 @@ void FuncPGOInstrumentation<Edge, BBInfo>::computeCFGHash() {
for (unsigned s = 0, e = TI->getNumSuccessors(); s != e; ++s) {
BasicBlock *Succ = TI->getSuccessor(s);
uint32_t Index = getBBInfo(Succ).Index;
for (int i = 0; i < sizeof(uint32_t) / sizeof(char); i++)
Indexes.push_back((char)(Index >> (i * sizeof(char))));
for (int i = 0; i < 4; i++)
Indexes.push_back((char)(Index >> i));
}
}
JC.update(Indexes);