[llvm-commits] [PATCH, PR-13709]: Remove unnecessary SRL instruction to access high sub-reg of a register pair.

Pranav Bhandarkar pranavb at codeaurora.org
Mon Aug 27 11:20:04 PDT 2012


Hi,

This is a fix for PR13709.

We peephole optimize by forwarding the high-subreg of a register pair, Rp0
into the copy of the lower subregister of Rp1 in 

""
Rp1 = SRL Rp0, 32
Rx = Rp1: subreg_loreg
""

So, we transform the above into.
"""
Rp1 = SRL Rp0, 32   // dead if there are no other uses of Rp1.
Rx = Rp0:subreg_hireg
"""

Built and Installed fine. No regressions on make check.

Pranav
Qualcomm Innovation Center (QuIC) is a member of the Code Aurora Forum.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-LLVM-Bug-Fix-13709-Remove-needless-lsr-Rp-32-instruc.patch
Type: application/octet-stream
Size: 8178 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20120827/6c134d30/attachment.obj>


More information about the llvm-commits mailing list