[PATCH] D27002: [AArch64] Handle more zero reg cases in foldMemoryOperandImpl

Geoff Berry via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 22 14:27:13 PST 2016


gberry created this revision.
gberry added reviewers: qcolombet, MatzeB.
gberry added subscribers: t.p.northover, mcrosier, llvm-commits.
Herald added subscribers: rengolin, aemerson.

Extend AArch64 foldMemoryOperandImpl() to handle folding spills of COPYs like:

  %vreg0:sub_32<def,read-undef> = COPY %WZR; GPR64common:%vreg0

by generating:

  STRXui %XZR <fi#0>

These cases show up mostly due to zero extended values that get
coalesced and subsequently spilled.


https://reviews.llvm.org/D27002

Files:
  lib/Target/AArch64/AArch64InstrInfo.cpp
  lib/Target/AArch64/AArch64InstrInfo.h
  test/CodeGen/MIR/AArch64/spill-fold-zr.mir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D27002.78950.patch
Type: text/x-patch
Size: 5712 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161122/9b484f24/attachment.bin>


More information about the llvm-commits mailing list