From 5e018f9e29a2b7e67e82dfa17f32662f18a9bdf7 Mon Sep 17 00:00:00 2001 From: Alexey Bataev Date: Thu, 23 Apr 2015 06:35:10 +0000 Subject: [OPENMP] Codegen for 'atomic capture'. Adds codegen for 'atomic capture' constructs with the following forms of expressions/statements: v = x binop= expr; v = x++; v = ++x; v = x--; v = --x; v = x = x binop expr; v = x = expr binop x; {v = x; x = binop= expr;} {v = x; x++;} {v = x; ++x;} {v = x; x--;} {v = x; --x;} {x = x binop expr; v = x;} {x binop= expr; v = x;} {x++; v = x;} {++x; v = x;} {x--; v = x;} {--x; v = x;} {x = x binop expr; v = x;} {x = expr binop x; v = x;} {v = x; x = expr;} If x and expr are integer and binop is associative or x is a LHS in a RHS of the assignment expression, and atomics are allowed for type of x on the target platform atomicrmw instruction is emitted. Otherwise compare-and-swap sequence is emitted. Update of 'v' is not required to be be atomic with respect to the read or write of the 'x'. bb: ... atomic load cont: = phi [ , label %bb ], [ , %cont ] = binop = cmpxchg atomic &, desired, expected = .field1; br field2, label %exit, label %cont exit: atomic store , ... Differential Revision: http://reviews.llvm.org/D9049 llvm-svn: 235573 --- clang/test/OpenMP/atomic_messages.cpp | 1 - 1 file changed, 1 deletion(-) (limited to 'clang/test/OpenMP/atomic_messages.cpp') diff --git a/clang/test/OpenMP/atomic_messages.cpp b/clang/test/OpenMP/atomic_messages.cpp index 7466509b275..73068141633 100644 --- a/clang/test/OpenMP/atomic_messages.cpp +++ b/clang/test/OpenMP/atomic_messages.cpp @@ -672,7 +672,6 @@ int capture() { #pragma omp atomic capture capture b = a /= b; - // expected-note@+1 {{in instantiation of function template specialization 'capture' requested here}} return capture(); } -- cgit v1.2.3