[PATCH] D46396: Optionally simplify basic blocks introduced by AtomicExpandPass

Krzysztof Parzyszek via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 3 10:27:58 PDT 2018


kparzysz created this revision.
kparzysz added reviewers: jyknight, ab.

The atomic expansion pass typically runs late, after most IR optimizations have already run. The test-and-branch code it generates can often be simplified, but no such simplification normally occurred. This patch adds an optional parameter to createAtomicExpandPass with CFG simplification options. The presence of this parameter will trigger running simplifyCFG
on basic blocks created in expandPartwordCmpXchg, insertRMWLLSCLoop, and expandAtomicCmpXchg.


Repository:
  rL LLVM

https://reviews.llvm.org/D46396

Files:
  include/llvm/CodeGen/Passes.h
  lib/CodeGen/AtomicExpandPass.cpp
  lib/Target/Hexagon/HexagonTargetMachine.cpp
  test/CodeGen/Hexagon/intrinsics/atomicrmw_addsub_native.ll
  test/CodeGen/Hexagon/intrinsics/atomicrmw_bitwise_native.ll
  test/CodeGen/Hexagon/intrinsics/atomicrmw_nand.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D46396.145045.patch
Type: text/x-patch
Size: 8121 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180503/92b78de9/attachment.bin>


More information about the llvm-commits mailing list