[FastISel][AArch64] Add support for more addressing modes.
authorJuergen Ributzka <juergen@apple.com>
Wed, 13 Aug 2014 22:53:29 +0000 (22:53 +0000)
committerJuergen Ributzka <juergen@apple.com>
Wed, 13 Aug 2014 22:53:29 +0000 (22:53 +0000)
commit8c9a0319bb537da2774c59d698085e08ac32c63f
tree0cd968176de65825043a41861caba3fa57a96828
parentb677a877c8ae9a52b834e75def8086ea0f54a0a5
[FastISel][AArch64] Add support for more addressing modes.

FastISel didn't take much advantage of the different addressing modes available
to it on AArch64. This commit allows the ComputeAddress method to recognize more
addressing modes that allows shifts and sign-/zero-extensions to be folded into
the memory operation itself.

For Example:
  lsl x1, x1, #3     --> ldr x0, [x0, x1, lsl #3]
  ldr x0, [x0, x1]

  sxtw x1, w1
  lsl x1, x1, #3     --> ldr x0, [x0, x1, sxtw #3]
  ldr x0, [x0, x1]

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@215597 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/AArch64/AArch64FastISel.cpp
test/CodeGen/AArch64/fast-isel-addressing-modes.ll [new file with mode: 0644]