diff options
| author | Roman Lebedev <lebedev.ri@gmail.com> | 2020-01-03 16:50:37 +0300 |
|---|---|---|
| committer | Roman Lebedev <lebedev.ri@gmail.com> | 2020-01-03 17:55:46 +0300 |
| commit | d09ac032ee0012d11ae9f9d717eaa6a10cc22a75 (patch) | |
| tree | d182d23284c7a386d62e09e92f39a7e1b2baeed2 /clang/test/Preprocessor/overflow.c | |
| parent | 3d492d7503d197246115eb38e7b1b61143d0c99f (diff) | |
| download | bcm5719-llvm-d09ac032ee0012d11ae9f9d717eaa6a10cc22a75.tar.gz bcm5719-llvm-d09ac032ee0012d11ae9f9d717eaa6a10cc22a75.zip | |
[NFC][DAGCombine][X86] '~(X - 1)' pattern tests
The fold 'A - (A & (B - 1))' -> 'A & (0 - B)'
added in 8dab0a4a7d691f2704f1079538e0ef29548db159
is too specific. It should just be 'A - (A & B)' -> 'A & (~B)',
but we currently fail to sink that '~' into `(B - 1)`.
Name: ~(X - 1) -> (0 - X)
%o = add i32 %X, -1
%r = xor i32 %o, -1
=>
%r = sub i32 0, %X
https://rise4fun.com/Alive/rjU
Diffstat (limited to 'clang/test/Preprocessor/overflow.c')
0 files changed, 0 insertions, 0 deletions

