mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-03-24 07:35:04 +00:00
add a note
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27567 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
8ebd7f937b
commit
a956db2a63
@ -675,6 +675,29 @@ Perhaps use pxor / xorp* to clear a XMM register first?
|
||||
|
||||
//===---------------------------------------------------------------------===//
|
||||
|
||||
Better codegen for:
|
||||
|
||||
void f(float a, float b, vector float * out) { *out = (vector float){ a, 0.0, 0.0, b}; }
|
||||
void f(float a, float b, vector float * out) { *out = (vector float){ a, b, 0.0, 0}; }
|
||||
|
||||
For the later we generate:
|
||||
|
||||
_f:
|
||||
pxor %xmm0, %xmm0
|
||||
movss 8(%esp), %xmm1
|
||||
movaps %xmm0, %xmm2
|
||||
unpcklps %xmm1, %xmm2
|
||||
movss 4(%esp), %xmm1
|
||||
unpcklps %xmm0, %xmm1
|
||||
unpcklps %xmm2, %xmm1
|
||||
movl 12(%esp), %eax
|
||||
movaps %xmm1, (%eax)
|
||||
ret
|
||||
|
||||
This seems like it should use shufps, one for each of a & b.
|
||||
|
||||
//===---------------------------------------------------------------------===//
|
||||
|
||||
Adding to the list of cmp / test poor codegen issues:
|
||||
|
||||
int test(__m128 *A, __m128 *B) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user