[PATCH] D105417: [RISCV] Teach RISCVMatInt about cases where it can use LUI+SLLI to replace LUI+ADDI+SLLI for large constants.

Luís Marques via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 20 01:54:10 PDT 2021


luismarques accepted this revision.
luismarques added a comment.

You added RVC RUN lines to a test because you spotted an issue there *before* the changes were gated by `HasRVC`. The next time around, how will we detect such changes, without adding RVC RUN lines to more test files? Doesn't that mean that we should add RVC RUN lines in other potentially problematic test files (e.g. `rv64zb*.ll`)? Or are we confident that more targeted tests will always detect all such issues...?

Other than that, LGTM. Thanks.



================
Comment at: llvm/test/CodeGen/RISCV/add-before-shl.ll:6-9
 ; RUN: llc -mtriple=riscv32 -mattr=+c -verify-machineinstrs --riscv-no-aliases< %s \
 ; RUN:   | FileCheck -check-prefixes=RV32C %s
 ; RUN: llc -mtriple=riscv64 -mattr=+c -verify-machineinstrs --riscv-no-aliases < %s \
 ; RUN:   | FileCheck -check-prefixes=RV64C %s
----------------
craig.topper wrote:
> I added new RVC RUN lines so we can see that the code with compression enabled isn't affected.
Nit: wrap before column 80.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D105417



More information about the llvm-commits mailing list