[PATCH] D61185: [RISCV] Add CostModel tests

Luís Marques via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Apr 26 05:44:15 PDT 2019


luismarques created this revision.
luismarques added a reviewer: asb.
Herald added subscribers: llvm-commits, benna, psnobl, jocewei, PkmX, rkruppe, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, shiva0217, kito-cheng, niosHD, sabuasal, apazos, simoncook, johnrusso, rbar.
Herald added a project: LLVM.

These tests revolve around checking that the implied offsets fit the simm12 immediates. When they do, the offsets can be folded into the loads/stores, and therefore they should have zero cost.
The patch adds vector tests, despite the RISC-V backend currently not targetting any vector units. That was a borderline decision. Since we can compile IR vector instructions to scalar native ones, I felt including the vector tests made sense. This way we also have the infrastructure already in place for when we decide to add support for vector extensions.


Repository:
  rL LLVM

https://reviews.llvm.org/D61185

Files:
  test/Analysis/CostModel/RISCV/gep.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D61185.196836.patch
Type: text/x-patch
Size: 23480 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190426/cac8ada0/attachment.bin>


More information about the llvm-commits mailing list