[PATCH] D87681: [ARM] Improve VPT predicate tracking

Sam Parker via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 15 03:42:03 PDT 2020


samparker created this revision.
samparker added reviewers: SjoerdMeijer, samtebbs, dmgreen, NickGuy.
Herald added subscribers: danielkiss, hiraditya, kristof.beyls.
Herald added a project: LLVM.
samparker requested review of this revision.

The VPTBlock has been modified to track the 'global' state of the VPR, as well as the state for each block. Each object now just holds a list of instructions that makeup the block, while static structures hold the predicate information. This enables global access for querying how both a VPT block and individual instructions are predicated. These changes now allow us, again, to handle more complicated cases where multiple instructions build a predicate and/or where the same predicate in used in multiple blocks.
It doesn't, however, get us back to before the tracking was 'fixed' as some extra logic will be required to properly handle VPT instructions. Currently a VPT could be effectively predicated because of it's inputs, but the existing logic will not detect that and so will refuse to perform the transformation. This can be seen in remat-vctp.ll test where we still don't perform the transform.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D87681

Files:
  llvm/lib/Target/ARM/ARMLowOverheadLoops.cpp
  llvm/test/CodeGen/Thumb2/LowOverheadLoops/cond-vector-reduce-mve-codegen.ll
  llvm/test/CodeGen/Thumb2/LowOverheadLoops/tp-multiple-vpst.ll
  llvm/test/CodeGen/Thumb2/LowOverheadLoops/vctp-in-vpt-2.mir
  llvm/test/CodeGen/Thumb2/LowOverheadLoops/vpt-blocks.mir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D87681.291859.patch
Type: text/x-patch
Size: 28081 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200915/b0fb7191/attachment.bin>


More information about the llvm-commits mailing list