[PATCH] D53067: [AArch64] Swap comparison operands if that enables some folding.

Arnaud A. de Grandmaison via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 10 02:41:26 PDT 2018


aadg created this revision.
aadg added reviewers: efriedma, t.p.northover.
Herald added subscribers: kristof.beyls, mcrosier.
Herald added a reviewer: javed.absar.

AArch64 can fold some shift+extend operations on the RHS operand of
comparisons, so swap the operands if that makes sense.

This provides a fix for https://bugs.llvm.org/show_bug.cgi?id=38751


Repository:
  rL LLVM

https://reviews.llvm.org/D53067

Files:
  lib/Target/AArch64/AArch64ISelLowering.cpp
  test/CodeGen/AArch64/and-mask-removal.ll
  test/CodeGen/AArch64/lack-of-signed-truncation-check.ll
  test/CodeGen/AArch64/sat-add.ll
  test/CodeGen/AArch64/signed-truncation-check.ll
  test/CodeGen/AArch64/swap-compare-operands.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D53067.168962.patch
Type: text/x-patch
Size: 26559 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181010/b1b8b1c9/attachment.bin>


More information about the llvm-commits mailing list