Fix a typo in the bitcode reader in the handling of atomic stores. Reported by David Meyer on llvmdev.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@140040 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Eli Friedman 2011-09-19 19:41:28 +00:00
parent fb12f35545
commit c3d3598425
2 changed files with 2 additions and 2 deletions

View File

@ -2653,7 +2653,7 @@ bool BitcodeReader::ParseFunctionBody(Function *F) {
return Error("Invalid STOREATOMIC record"); return Error("Invalid STOREATOMIC record");
AtomicOrdering Ordering = GetDecodedOrdering(Record[OpNum+2]); AtomicOrdering Ordering = GetDecodedOrdering(Record[OpNum+2]);
if (Ordering == NotAtomic || Ordering == Release || if (Ordering == NotAtomic || Ordering == Acquire ||
Ordering == AcquireRelease) Ordering == AcquireRelease)
return Error("Invalid STOREATOMIC record"); return Error("Invalid STOREATOMIC record");
SynchronizationScope SynchScope = GetDecodedSynchScope(Record[OpNum+3]); SynchronizationScope SynchScope = GetDecodedSynchScope(Record[OpNum+3]);

View File

@ -1,4 +1,4 @@
; RUN: opt -S < %s | FileCheck %s ; RUN: opt < %s | opt -S | FileCheck %s
; Basic smoke test for atomic operations. ; Basic smoke test for atomic operations.
define void @f(i32* %x) { define void @f(i32* %x) {