diff options
| author | Evan Cheng <evan.cheng@apple.com> | 2011-07-13 00:42:17 +0000 |
|---|---|---|
| committer | Evan Cheng <evan.cheng@apple.com> | 2011-07-13 00:42:17 +0000 |
| commit | f863e3fb73f03b6aa0b4f9932a98b94258dc2957 (patch) | |
| tree | 6a9f39826df01e829d7371f7207ae76ab2fa367a /llvm/lib/Bitcode/Reader/BitReader.cpp | |
| parent | 0d0dff43983bc9be0ccdeb1eedaa4e63eafa4c30 (diff) | |
| download | llvm-f863e3fb73f03b6aa0b4f9932a98b94258dc2957.zip llvm-f863e3fb73f03b6aa0b4f9932a98b94258dc2957.tar.gz llvm-f863e3fb73f03b6aa0b4f9932a98b94258dc2957.tar.bz2 | |
Improve codegen for select's:
if (x != 0) x = 1
if (x == 1) x = 1
Previous codegen looks like this:
mov r1, r0
cmp r1, #1
mov r0, #0
moveq r0, #1
The naive lowering select between two different values. It should recognize the
test is equality test so it's more a conditional move rather than a select:
cmp r0, #1
movne r0, #0
rdar://9758317
llvm-svn: 135017
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitReader.cpp')
0 files changed, 0 insertions, 0 deletions
