[PATCH] D89026: [StructurizeCFG][NewPM] Port -structurizecfg to NPM

Arthur Eubanks via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 7 22:10:16 PDT 2020


aeubanks created this revision.
Herald added subscribers: llvm-commits, kerbowa, hiraditya, nhaehnle, jvesely.
Herald added a project: LLVM.
aeubanks requested review of this revision.

This doesn't support -structurizecfg-skip-uniform-regions since that
would require porting LegacyDivergenceAnalysis.

The NPM doesn't support adding a non-analysis pass as a dependency of
another, so I had to add -lowerswitch to some tests or pin them to the
legacy PM.

This is the only RegionPass in tree, so I simply copied the logic for
finding all Regions from the legacy PM's RGManager into
StructurizeCFG::run().


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D89026

Files:
  llvm/include/llvm/InitializePasses.h
  llvm/include/llvm/Transforms/Scalar/StructurizeCFG.h
  llvm/lib/Passes/PassBuilder.cpp
  llvm/lib/Passes/PassRegistry.def
  llvm/lib/Transforms/Scalar/Scalar.cpp
  llvm/lib/Transforms/Scalar/StructurizeCFG.cpp
  llvm/test/Transforms/StructurizeCFG/AMDGPU/uniform-regions.ll
  llvm/test/Transforms/StructurizeCFG/interleaved-loop-order.ll
  llvm/test/Transforms/StructurizeCFG/nested-loop-order.ll
  llvm/test/Transforms/StructurizeCFG/switch.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D89026.296864.patch
Type: text/x-patch
Size: 14331 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20201008/8b486380/attachment.bin>


More information about the llvm-commits mailing list