diff options
| author | Benjamin Kramer <benny.kra@googlemail.com> | 2014-04-24 08:15:31 +0000 |
|---|---|---|
| committer | Benjamin Kramer <benny.kra@googlemail.com> | 2014-04-24 08:15:31 +0000 |
| commit | f43438b6c3e8cb979658c87baf681f2e24aff9df (patch) | |
| tree | 45ad341f6c867addfca486b0202b4ebaee4f2ffb /lib/Bitcode | |
| parent | 63ed439ab5ac43a4b36e347df35db84707fc6894 (diff) | |
| download | llvm-f43438b6c3e8cb979658c87baf681f2e24aff9df.tar.gz llvm-f43438b6c3e8cb979658c87baf681f2e24aff9df.tar.bz2 llvm-f43438b6c3e8cb979658c87baf681f2e24aff9df.tar.xz | |
X86: Emit test instead of constant shift + compare if the shift result is unused.
This allows us to compile
return (mask & 0x8 ? a : b);
into
testb $8, %dil
cmovnel %edx, %esi
instead of
andl $8, %edi
shrl $3, %edi
cmovnel %edx, %esi
which we formed previously because dag combiner canonicalizes setcc of and into shift.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207088 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Bitcode')
0 files changed, 0 insertions, 0 deletions
