diff options
author | Chris Lattner <sabre@nondot.org> | 2005-09-18 03:42:07 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2005-09-18 03:42:07 +0000 |
commit | e9bed7d10759e86634793d6589f894d1e44f43e8 (patch) | |
tree | ac7bce9fb8289eeaae35ed991d17d26898a7b9f5 /lib/CodeGen/MachineFunction.cpp | |
parent | 1e122d1dc297f9386c11916df86fa0245b61041f (diff) |
Implement or.ll:test21. This teaches instcombine to be able to turn this:
struct {
unsigned int bit0:1;
unsigned int ubyte:31;
} sdata;
void foo() {
sdata.ubyte++;
}
into this:
foo:
add DWORD PTR [sdata], 2
ret
instead of this:
foo:
mov %EAX, DWORD PTR [sdata]
mov %ECX, %EAX
add %ECX, 2
and %ECX, -2
and %EAX, 1
or %EAX, %ECX
mov DWORD PTR [sdata], %EAX
ret
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@23376 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/MachineFunction.cpp')
0 files changed, 0 insertions, 0 deletions