[PATCH] D95447: [RISCV] Add support for RVV int<->fp & fp<->fp conversions

Fraser Cormack via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 26 07:51:17 PST 2021


frasercrmck created this revision.
frasercrmck added reviewers: craig.topper, evandro, rogfer01, HsiangKai.
Herald added subscribers: NickHung, luismarques, apazos, sameer.abuasal, pzheng, s.egerton, Jim, benna, psnobl, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, edward-jones, zzheng, jrtc27, shiva0217, kito-cheng, niosHD, sabuasal, simoncook, johnrusso, rbar, asb, hiraditya.
frasercrmck requested review of this revision.
Herald added subscribers: llvm-commits, MaskRay.
Herald added a project: LLVM.

This patch adds support for the full range of vector int-to-float,
float-to-int, and float-to-float conversions on legal types.

Many conversions are supported natively in RVV so are lowered with
patterns. These include conversions between (element) types of the same
size, and those that are half/double the size of the input. When
conversions take place between types that are less than half or more
than double the size we must lower them using sequences of instructions
which go via intermediate types.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D95447

Files:
  llvm/lib/Target/RISCV/RISCVISelLowering.cpp
  llvm/lib/Target/RISCV/RISCVISelLowering.h
  llvm/lib/Target/RISCV/RISCVInstrInfoVSDPatterns.td
  llvm/test/CodeGen/RISCV/rvv/vfpext-sdnode-rv32.ll
  llvm/test/CodeGen/RISCV/rvv/vfpext-sdnode-rv64.ll
  llvm/test/CodeGen/RISCV/rvv/vfptoi-sdnode-rv32.ll
  llvm/test/CodeGen/RISCV/rvv/vfptoi-sdnode-rv64.ll
  llvm/test/CodeGen/RISCV/rvv/vfptrunc-sdnode-rv32.ll
  llvm/test/CodeGen/RISCV/rvv/vfptrunc-sdnode-rv64.ll
  llvm/test/CodeGen/RISCV/rvv/vitofp-sdnode-rv32.ll
  llvm/test/CodeGen/RISCV/rvv/vitofp-sdnode-rv64.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D95447.319296.patch
Type: text/x-patch
Size: 216704 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210126/82014fa8/attachment-0001.bin>


More information about the llvm-commits mailing list