aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Support/Host.cpp
diff options
context:
space:
mode:
authorAlexey Bataev <a.bataev@hotmail.com>2015-03-30 05:20:59 +0000
committerAlexey Bataev <a.bataev@hotmail.com>2015-03-30 05:20:59 +0000
commitb4505a722927a16fbb5dcbec5e3b90ab1d7942dd (patch)
tree9b097b538bf215a369011a8a901cc88a454de33a /llvm/lib/Support/Host.cpp
parent36df1ca5f1ab42bc92bffc25068edbb924b44a40 (diff)
downloadllvm-b4505a722927a16fbb5dcbec5e3b90ab1d7942dd.zip
llvm-b4505a722927a16fbb5dcbec5e3b90ab1d7942dd.tar.gz
llvm-b4505a722927a16fbb5dcbec5e3b90ab1d7942dd.tar.bz2
[OPENMP] Codegen for 'atomic update' construct.
Adds atomic update codegen for the following forms of expressions: x binop= expr; x++; ++x; x--; --x; x = x binop expr; x = expr binop x; 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: bb: ... atomic load <x> cont: <expected> = phi [ <x>, label %bb ], [ <new_failed>, %cont ] <desired> = <expected> binop <expr> <res> = cmpxchg atomic &<x>, desired, expected <new_failed> = <res>.field1; br <res>field2, label %exit, label %cont exit: ... Differential Revision: http://reviews.llvm.org/D8536 llvm-svn: 233513
Diffstat (limited to 'llvm/lib/Support/Host.cpp')
0 files changed, 0 insertions, 0 deletions