[PATCH] D63433: [RISCV] Add RISCV-specific TargetTransformInfo

Sam Elliott via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 17 08:29:18 PDT 2019


lenary created this revision.
lenary added reviewers: asb, luismarques.
lenary added a project: LLVM.

LLVM Allows Targets to provide information that guides optimisations
made to LLVM IR. This is done with callbacks on a TargetTransformInfo object.

This patch adds a TargetTransformInfo class for RISC-V. This will allow us to
implement RISC-V specific callbacks as they become necessary.

This commit also adds the getIntImmCost callbacks, and tests them with a simple
constant hoisting test.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D63433

Files:
  llvm/lib/Target/RISCV/CMakeLists.txt
  llvm/lib/Target/RISCV/LLVMBuild.txt
  llvm/lib/Target/RISCV/RISCVTargetMachine.cpp
  llvm/lib/Target/RISCV/RISCVTargetMachine.h
  llvm/lib/Target/RISCV/RISCVTargetTransformInfo.cpp
  llvm/lib/Target/RISCV/RISCVTargetTransformInfo.h
  llvm/test/Transforms/ConstantHoisting/RISCV/immediates.ll
  llvm/test/Transforms/ConstantHoisting/RISCV/lit.local.cfg

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D63433.205084.patch
Type: text/x-patch
Size: 7479 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190617/b365f373/attachment.bin>


More information about the llvm-commits mailing list