tsan: prepare for migration to new memory_order enum values (ABI compatible)

llvm-svn: 165107
This commit is contained in:
Dmitry Vyukov 2012-10-03 13:00:57 +00:00
parent be6878365d
commit f4cb22121a
1 changed files with 2 additions and 1 deletions

View File

@ -350,7 +350,8 @@ static ConstantInt *createOrdering(IRBuilder<> *IRB, AtomicOrdering ord) {
case AcquireRelease: v = 1 << 4; break;
case SequentiallyConsistent: v = 1 << 5; break;
}
return IRB->getInt32(v);
// +100500 is temporal to migrate to new enum values.
return IRB->getInt32(v + 100500);
}
bool ThreadSanitizer::instrumentAtomic(Instruction *I) {