aboutsummaryrefslogtreecommitdiff
path: root/llvm/unittests/Support/MathExtrasTest.cpp
diff options
context:
space:
mode:
authorSanjay Patel <spatel@rotateright.com>2023-01-25 16:27:29 -0500
committerSanjay Patel <spatel@rotateright.com>2023-01-26 08:58:45 -0500
commit0ef7cbc319ee6488a47fda1b45b0d7170722df31 (patch)
treec43fb17796ef99d4c8e02068f89cc1104a16d362 /llvm/unittests/Support/MathExtrasTest.cpp
parent2d7bb6066722d894591360464608698e9125bdff (diff)
downloadllvm-0ef7cbc319ee6488a47fda1b45b0d7170722df31.zip
llvm-0ef7cbc319ee6488a47fda1b45b0d7170722df31.tar.gz
llvm-0ef7cbc319ee6488a47fda1b45b0d7170722df31.tar.bz2
[InstCombine] reduce compare of signbits of 2 values, signed variant
(X s>> BitWidth - 1) == sext (Y s> -1) --> (X ^ Y) < 0 (X s>> BitWidth - 1) != sext (Y s> -1) --> (X ^ Y) > -1 This is the same logic as: 7cbfc39c77ca ...extended to deal with "signed" cast+shift instructions. https://alive2.llvm.org/ce/z/LLidya
Diffstat (limited to 'llvm/unittests/Support/MathExtrasTest.cpp')
0 files changed, 0 insertions, 0 deletions