[PATCH] D119657: [OpenMP][mlir] Lowering for omp.atomic.update

Shraiysh via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Feb 12 23:33:38 PST 2022


shraiysh created this revision.
Herald added subscribers: awarzynski, sdasgup3, wenzhicui, wrengr, Chia-hungDuan, dcaballe, cota, teijeong, rdzhabarov, tatianashp, msifontes, jurahul, Kayjukh, grosul1, Joonsoo, liufengdb, aartbik, mgester, arpith-jacob, antiagainst, shauheen, rriddle, mehdi_amini, guansong, hiraditya, yaxunl.
Herald added a reviewer: ftynse.
shraiysh requested review of this revision.
Herald added a reviewer: jdoerfert.
Herald added subscribers: llvm-commits, sstefan1, stephenneuendorffer, nicolasvasilache.
Herald added projects: MLIR, LLVM.

This patch adds lowering from omp.atomic.update to LLVM IR. Whenever a
special LLVM IR instruction is available for the operation, `atomicrmw`
instruction is emitted, otherwise a compare-exchange loop based update
is emitted.

Depends on D119522 <https://reviews.llvm.org/D119522>


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D119657

Files:
  llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp
  mlir/lib/Target/LLVMIR/Dialect/OpenMP/OpenMPToLLVMIRTranslation.cpp
  mlir/test/Target/LLVMIR/openmp-llvm.mlir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D119657.408239.patch
Type: text/x-patch
Size: 9279 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220213/e0308829/attachment.bin>


More information about the llvm-commits mailing list