[PATCH] D111508: [RISCV] Optimize immediate materialisation with BSETI/BCLRI

Ben Shi via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 12 18:16:49 PDT 2021


benshi001 updated this revision to Diff 379242.
benshi001 added a comment.

Opitimize immediate materialisation in the following way if profitable:

1. Use BCLRI for upper 32-bit if the lower 32-bit is negative int32.
2. Use BSETI for upper 32-bit if the lower 32-bit is positive int32.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D111508/new/

https://reviews.llvm.org/D111508

Files:
  llvm/lib/Target/RISCV/MCTargetDesc/RISCVMatInt.cpp
  llvm/test/CodeGen/RISCV/imm.ll
  llvm/test/MC/RISCV/rv64zbs-aliases-valid.s

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D111508.379242.patch
Type: text/x-patch
Size: 8034 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20211013/e8af0718/attachment.bin>


More information about the llvm-commits mailing list