[Patch] [AArch64] Implement allowsUnalignedMemoryAccesses()
Jiangning Liu
liujiangning1 at gmail.com
Wed Apr 9 13:47:56 PDT 2014
Hi zhaoshi,
> I believe "ld1/st1 + rev" or "ldr" on big-endian should be controlled by
pattern matching and addressed by a separate patch... Can you point me to
the review thread you mentioned?
http://permalink.gmane.org/gmane.comp.compilers.llvm.cvs/180464
> I looked into ARM64 backend. All vector types are promoted to v2i64/v2i32
and the pattern matcher emits ldr/str instructions.
Yes, and this is probably the way we should follow for non-strict alignment
mode, i.e. generate ldr/str. So it may affect your performance finally due
to instrction change for little endian. For strict mode, we should have to
use ld1+rev for big endian to gurantee the same semantic.
> My assumption is Linux by default is configured to support unaligned
accesses. Do you mean I should add -aarch64-no-strict-align to the command
line in my test?
Yes, I think you should add more RUNs in your test to cover all opts you
are going to add.
> Can you elaborate a little bit about "the ld1/st1 CHECK should be
guaranteed for both little-endian and big-endian"?
Since that big-endian patch has not been upstreamed yet, at present you can
only use ld1/st1 to make correct test case for both little endian and big
endian. I expect your test case should be updated to use ldr/str by the big
endian patch, if your patch will be upstreamed first.
Thanks,
-Jiangning
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140410/f67d3afc/attachment.html>
More information about the llvm-commits
mailing list