[llvm-commits] [PATCH] Remove redundant register copies when inserting to Q registers on ARM

James Molloy James.Molloy at arm.com
Mon Sep 3 01:19:32 PDT 2012


Hi Jakob,

Sure. Please find attached a patch which does just this.

OK to commit?

Cheers,

James

On Fri, 2012-08-31 at 17:41 +0100, Jakob Stoklund Olesen wrote:
> On Aug 31, 2012, at 8:26 AM, James Molloy <James.Molloy at arm.com> wrote:
>
> > Hi Jakob,
> >
> > That would be neat, and indeed makes sense and works for i32 set-lanes:
> >
> > def : Pat<(insertelt (v4i32 QPR:$src1), GPR:$src2, imm:$lane),
> >          (v4i32 (INSERT_SUBREG QPR:$src1,
> >                  GPR:$src2,
> >                  (SSubReg_f32_reg imm:$lane)))>;
> >
> > But this doesn't work for i16 or i8; lane widths that are smaller than
> > the smallest subregister (ssubx).
>
> Ah, I see.
>
> Could you use the pattern above for 32-bit lanes, and the pseudos for smaller lanes?
>
> BTW, I am planning on fixing the coalescer so it can handle stuff like this. It's not yet clear when that will happen, though.
>
> Thanks,
>
> /jakob
>
>
>


-- IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium.  Thank you.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: integer_insertelement.diff
Type: text/x-patch
Size: 5859 bytes
Desc: integer_insertelement.diff
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20120903/fff5cd2d/attachment.bin>


More information about the llvm-commits mailing list