[PATCH] D97859: [LegalizeDAG] Implement promotion rules for SELECT_CC

LemonBoy via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 3 07:25:29 PST 2021


LemonBoy created this revision.
LemonBoy added reviewers: fhahn, david-arm.
Herald added subscribers: hiraditya, kristof.beyls.
LemonBoy requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

Implement the promotion rule for SELECT_CC nodes by upcasting all the parameters and downcasting the result.
The AArch64 target makes use of this rule and, since it was not implemented, in some cases the instruction selector would hit an assertion upon encountering the illegal node.

This patch requires D97840 <https://reviews.llvm.org/D97840>, the included test cases hit both problems.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D97859

Files:
  llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
  llvm/test/CodeGen/AArch64/vecreduce-fmax-legalization.ll
  llvm/test/CodeGen/AArch64/vecreduce-fmin-legalization.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D97859.327788.patch
Type: text/x-patch
Size: 19391 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210303/af89206f/attachment.bin>


More information about the llvm-commits mailing list