]> granicus.if.org Git - llvm/commit
[WebAssembly] Add atomic.fence instruction
authorHeejin Ahn <aheejin@gmail.com>
Wed, 28 Aug 2019 23:13:43 +0000 (23:13 +0000)
committerHeejin Ahn <aheejin@gmail.com>
Wed, 28 Aug 2019 23:13:43 +0000 (23:13 +0000)
commit7d610ade1d38fd0d8e5513446c26d4bc2838ca8f
tree92d1953cddea1919ed608e5c01389d5e8037a0b0
parentdb58724403592f5ea30958407d85d7607e1f117c
[WebAssembly] Add atomic.fence instruction

Summary:
This adds `atomic.fence` instruction:
https://github.com/WebAssembly/threads/blob/master/proposals/threads/Overview.md#fence-operator

And we now emit the new `atomic.fence` instruction for multithread
fences, rather than the prevous `atomic.rmw` hack.

Reviewers: dschuff

Subscribers: sbc100, jgravelle-google, hiraditya, sunfish, jfb, tlively, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D66794

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@370272 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/WebAssembly/WebAssemblyISelDAGToDAG.cpp
lib/Target/WebAssembly/WebAssemblyInstrAtomics.td
test/CodeGen/WebAssembly/atomic-fence.ll
test/CodeGen/WebAssembly/atomic-fence.mir [new file with mode: 0644]
test/MC/WebAssembly/atomics-encodings.s