[llvm-commits] [patch] Invalid alignments for NEON loads

Tim Northover t.p.northover at gmail.com
Wed Aug 8 04:30:46 PDT 2012


Hi,

I've been looking at http://llvm.org/bugs/show_bug.cgi?id=13275. The
issue is that LLVM is printing the following instruction to assembly:

    vld1.32 {d15[0]}, [r0, :16]

This is attempting to put an alignment-specifier of 16 bits onto a
32-bit operation, which is invalid (if present, the specifier must be
the data width). The addrmode6oneL32 Operand instance already handles
this case for object code emission by treating the alignment
instruction operand (put in by SelectAddrMode6) as a hint and only
writing valid instructions. The attached patch extends this by adding
a parallel PrintMethod for when assembly is being written.

I'm not convinced the approach is the best long-term implementation of
these addressing-modes, but I assume there's a good reason it was
chosen and I've just about convinced myself there are no more hidden
codegen issues because of it.

Ok to commit?

Tim.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: vld1-align.diff
Type: application/octet-stream
Size: 2429 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20120808/4401fa2a/attachment.obj>


More information about the llvm-commits mailing list