PATCH] ARM NEON Lowering: Merge extractelt, bitcast, sitofp sequence

Jakob Stoklund Olesen jolesen at apple.com
Fri Feb 15 09:41:12 PST 2013


On Feb 15, 2013, at 5:06 AM, Arnold <aschwaighofer at apple.com> wrote:

> No, those are not generic copies ie COPY, INSERT_SUBREG, etc (but opaque machineinstrs by the time they get to coalescing/ allocation) that is why the coalescer/allocator can not reason about them.
> 
> What I am doing in this patch is to use instructions that the coalescer/allocator can understand.

Right, the coalescer only understands the generic copies.

EXTRACT_SUBREG, INSERT_SUBREG, COPY_TO_REGCLASS, and REG_SEQUENCE are all converted into COPY instructions before they reach the coalescer which can handle SUBREG_TO_REG and COPY instructions.

In most cases, COPY_TO_REGCLASS shouldn't be required any longer. InstrEmitter knows how to restrict to a subclass that supports ssub0 sub-registers, for example.

Did you try matching just the (f32 (bitconvert (extractelt ...))) sub-pattern? That could catch other cases where isel wants to copy i32s to the integer registers.

/jakob




More information about the llvm-commits mailing list