[FastISel][AArch64] Fold 'AND' instruction during the address computation.
authorJuergen Ributzka <juergen@apple.com>
Thu, 18 Sep 2014 05:40:41 +0000 (05:40 +0000)
committerJuergen Ributzka <juergen@apple.com>
Thu, 18 Sep 2014 05:40:41 +0000 (05:40 +0000)
commitffbd4879ebb8c0075500be281937586206a727dc
treeecb3b8f8cb8cfc91855b4821ede934bba1145504
parent49ab1a424d1a0e41b61de752283538a61112eca4
[FastISel][AArch64] Fold 'AND' instruction during the address computation.

The 'AND' instruction could be used to mask out the lower 32 bits of a register.
If this is done inside an address computation we might be able to fold the
instruction into the memory instruction itself.

and  x1, x1, #0xffffffff   ---> ldrb x0, [x0, w1, uxtw]
ldrb x0, [x0, x1]

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@218030 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/AArch64/AArch64FastISel.cpp
test/CodeGen/AArch64/fast-isel-addressing-modes.ll