aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorSam Elliott <selliott@lowrisc.org>2021-01-15 11:20:28 +0000
committerSam Elliott <selliott@lowrisc.org>2021-01-15 11:28:19 +0000
commit141e45b99ca09235b985504e8108dbb3cf210fbd (patch)
tree67e620162b160ca174f7f3e491a9ce2acb4de9aa /clang/lib/Frontend/CompilerInvocation.cpp
parentb9993fcbf53aa28ca2e7696a1855affeb558b51c (diff)
downloadllvm-141e45b99ca09235b985504e8108dbb3cf210fbd.zip
llvm-141e45b99ca09235b985504e8108dbb3cf210fbd.tar.gz
llvm-141e45b99ca09235b985504e8108dbb3cf210fbd.tar.bz2
[RISCV] Optimize Branch Comparisons
I noticed in D94450 that there were quite a few places where we generate the sequence: ``` xN <- comparison ... xN <- xor xN, 1 bnez xN, symbol ``` Given we know the XOR will be used by BRCOND, which only looks at the lowest bit, I think we can remove the XOR and just invert the branch condition in these cases? The case mostly seems to come up in floating point tests, where there is often more logic to combine the results of multiple SETCCs, rather than a single (BRCOND (SETCC ...) ...). Reviewed By: craig.topper Differential Revision: https://reviews.llvm.org/D94535
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions