diff options
author | John McCall <rjmccall@apple.com> | 2011-06-17 07:33:57 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2011-06-17 07:33:57 +0000 |
commit | 0502a224984a26087ea4d64e8e5d2dd4dca432f6 (patch) | |
tree | 99b9f567851006efd02865f6ec262661b9a4fa67 /test/CodeGenCXX/static-init.cpp | |
parent | 71c482c76c67ad4240757c4e319ffdb72272b8ee (diff) |
Perform an acquire memory barrier on the fast path of a thread-safe
static initializer check, as required by the Itanium ABI.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133250 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGenCXX/static-init.cpp')
-rw-r--r-- | test/CodeGenCXX/static-init.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/test/CodeGenCXX/static-init.cpp b/test/CodeGenCXX/static-init.cpp index 78749a7a2f..d488e63669 100644 --- a/test/CodeGenCXX/static-init.cpp +++ b/test/CodeGenCXX/static-init.cpp @@ -16,6 +16,9 @@ void f() { // CHECK: call void @_ZN1AC1Ev // CHECK: call i32 @__cxa_atexit(void (i8*)* bitcast (void (%struct.A*)* @_ZN1AD1Ev to void (i8*)*), i8* getelementptr inbounds (%struct.A* @_ZZ1fvE1a, i32 0, i32 0), i8* bitcast (i8** @__dso_handle to i8*)) // CHECK: call void @__cxa_guard_release + + // rdar://problem/9496726 + // CHECK: call void @llvm.memory.barrier(i1 true, i1 true, i1 false, i1 false, i1 false) static A a; } |