[PATCH] D141891: [VP][DAGCombiner] Introduce gneralized pattern match for vp sdnodes.

Yeting Kuo via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 16 21:56:18 PST 2023


fakepaper56 created this revision.
fakepaper56 added reviewers: simoll, craig.topper, frasercrmck, RKSimon, spatel, rogfer01.
Herald added subscribers: luke, StephenFan, ecnelises, luismarques, apazos, sameer.abuasal, steven.zhang, s.egerton, Jim, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, edward-jones, zzheng, jrtc27, niosHD, sabuasal, simoncook, johnrusso, rbar, asb, hiraditya.
Herald added a project: All.
fakepaper56 requested review of this revision.
Herald added subscribers: llvm-commits, pcwang-thead, MaskRay.
Herald added a project: LLVM.

The patch tries to solve duplicated combine work for vp sdnodes. The idea is to
introduce MatchConext that verifies specific patterns and generate specific node
infromation. There is two MatchConext in DAGCombiner. EmptyMatcher is for
normal nodes and VPMatcher is for vp nodes.

The idea of this patch is come form Simon Moll's proposal [0]. I only fixed some
minor issues and added few new features in this patch.

[0]: https://github.com/sx-aurora-dev/llvm-project/commit/c38a14484aa2945f3b05369560b65916dd832f76


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D141891

Files:
  llvm/include/llvm/CodeGen/ISDOpcodes.h
  llvm/include/llvm/IR/VPIntrinsics.def
  llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
  llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
  llvm/test/CodeGen/RISCV/rvv/fold-vp-fadd-and-vp-fmul.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D141891.489697.patch
Type: text/x-patch
Size: 23090 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230117/000135b9/attachment.bin>


More information about the llvm-commits mailing list