1 ; RUN: opt < %s -basicaa -gvn -instcombine -S | FileCheck %s
3 @flag0 = internal global i32 zeroinitializer
4 @turn = internal global i32 zeroinitializer
9 %a = load i32, i32* @flag0
10 %b = atomicrmw xchg i32* @turn, i32 1 monotonic
11 %c = load i32, i32* @flag0