aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@sifive.com>2022-05-11 12:16:37 -0700
committerCraig Topper <craig.topper@sifive.com>2022-05-11 12:47:13 -0700
commit5c7ec998a916baf8b35d571d0cc11753d464792d (patch)
tree40c236fc6aac6cd38b2c24162a40c30bc04058ad /clang/lib/Frontend/CompilerInvocation.cpp
parent411b9b8153ee95a51a2b7b3ebdb6fec9a7229f5a (diff)
downloadllvm-5c7ec998a916baf8b35d571d0cc11753d464792d.zip
llvm-5c7ec998a916baf8b35d571d0cc11753d464792d.tar.gz
llvm-5c7ec998a916baf8b35d571d0cc11753d464792d.tar.bz2
[RISCV] Fold addiw from (add X, (addiw (lui C1, C2))) into load/store address
This is a followup to D124231. We can fold the ADDIW in this pattern if we can prove that LUI+ADDI would have produced the same result as LUI+ADDIW. This pattern occurs because constant materialization prefers LUI+ADDIW for all simm32 immediates. Only immediates in the range 0x7ffff800-0x7fffffff require an ADDIW. Other simm32 immediates work with LUI+ADDI. Reviewed By: asb Differential Revision: https://reviews.llvm.org/D124693
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions