[PATCH] D67348: [RISCV] Add codegen pattern matching for bit manipulation assembly instructions.

Paolo Savini via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 3 04:04:41 PST 2019


PaoloS updated this revision to Diff 231857.
PaoloS edited the summary of this revision.
PaoloS added a comment.

Update codegen pattern matching to RISCV BitManip v0.92:

Add pattern matching for packu, packh, sext.b, sext.h.
Add correspondent tests.
Remove pattern matching for bfp. It is very unlikely to find an exact user implementation of such operation in the source code that can be matched automatically. And it is fragile to maintain.
Revert the lowering of select CC instructions into cmov. cmov would be used for any select CC instruction regardless the condition code and such condition wouldn't be computed.
Changed the tests in a way that they check just whether the bitmanip instruction is generated or not. There's no need for this patch to check the correctness of the selection without the B extension.


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

https://reviews.llvm.org/D67348

Files:
  llvm/lib/Target/RISCV/RISCVISelLowering.cpp
  llvm/lib/Target/RISCV/RISCVInstrInfoB.td
  llvm/test/CodeGen/RISCV/rv32Zbb.ll
  llvm/test/CodeGen/RISCV/rv32Zbbp.ll
  llvm/test/CodeGen/RISCV/rv32Zbp.ll
  llvm/test/CodeGen/RISCV/rv32Zbs.ll
  llvm/test/CodeGen/RISCV/rv32Zbt.ll
  llvm/test/CodeGen/RISCV/rv64Zbb.ll
  llvm/test/CodeGen/RISCV/rv64Zbbp.ll
  llvm/test/CodeGen/RISCV/rv64Zbp.ll
  llvm/test/CodeGen/RISCV/rv64Zbs.ll
  llvm/test/CodeGen/RISCV/rv64Zbt.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D67348.231857.patch
Type: text/x-patch
Size: 50986 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20191203/1d409b23/attachment-0001.bin>


More information about the llvm-commits mailing list