diff options
author | Sanjay Patel <spatel@rotateright.com> | 2017-08-24 22:54:01 +0000 |
---|---|---|
committer | Sanjay Patel <spatel@rotateright.com> | 2017-08-24 22:54:01 +0000 |
commit | bb789381fc11ccef82ab21ea9b3f5c347fb4b495 (patch) | |
tree | ce0051139e62296d8b5e6c3444f1ac0ee5cbfcfe /llvm/unittests/Support/ErrorTest.cpp | |
parent | 01cbd18ee91415a2caaeaf613f7d623bba7da49d (diff) | |
download | llvm-bb789381fc11ccef82ab21ea9b3f5c347fb4b495.zip llvm-bb789381fc11ccef82ab21ea9b3f5c347fb4b495.tar.gz llvm-bb789381fc11ccef82ab21ea9b3f5c347fb4b495.tar.bz2 |
[InstCombine] fix and enhance udiv/urem narrowing
There are 3 small independent changes here:
1. Account for multiple uses in the pattern matching: avoid the transform if it increases the instruction count.
2. Add a missing fold for the case where the numerator is the constant: http://rise4fun.com/Alive/E2p
3. Enable all folds for vector types.
There's still one more potential change - use "shouldChangeType()" to keep from transforming to an illegal integer type.
Differential Revision: https://reviews.llvm.org/D36988
llvm-svn: 311726
Diffstat (limited to 'llvm/unittests/Support/ErrorTest.cpp')
0 files changed, 0 insertions, 0 deletions