aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/CodeGen.cpp
diff options
context:
space:
mode:
authorSanjay Patel <spatel@rotateright.com>2022-04-11 07:09:47 -0400
committerSanjay Patel <spatel@rotateright.com>2022-04-11 07:44:58 -0400
commit2ed15984b49a1af87be37ec8bd6ee3ab7f724767 (patch)
treed308fa7929c340deaaee8637100719b72f931400 /llvm/lib/CodeGen/CodeGen.cpp
parentd6cf181a8df6a7925660b2332e3ab7dbcfd08145 (diff)
downloadllvm-2ed15984b49a1af87be37ec8bd6ee3ab7f724767.zip
llvm-2ed15984b49a1af87be37ec8bd6ee3ab7f724767.tar.gz
llvm-2ed15984b49a1af87be37ec8bd6ee3ab7f724767.tar.bz2
[SDAG] try to reduce compare of funnel shift equal 0
fshl (or X, Y), X, C ==/!= 0 --> or (shl Y, C), X ==/!= 0 fshl X, (or X, Y), C ==/!= 0 --> or (srl Y, BW-C), X ==/!= 0 This is similar to an existing setcc-of-rotate fold, but the matching requires more checks for the more general funnel op: https://alive2.llvm.org/ce/z/Ab2jDd We are effectively decomposing the funnel shift into logical shifts, reassociating, and removing a shift. This should get us the final improvements for x86-64 that were originally shown in D111530 ( https://github.com/llvm/llvm-project/issues/49541 ); x86-32 still shows some SHLD/SHRD, so the pattern is not matching there yet. Differential Revision: https://reviews.llvm.org/D122919
Diffstat (limited to 'llvm/lib/CodeGen/CodeGen.cpp')
0 files changed, 0 insertions, 0 deletions