|
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160 |
- /*********************************************************************/
- /* Copyright 2009, 2010 The University of Texas at Austin. */
- /* All rights reserved. */
- /* */
- /* Redistribution and use in source and binary forms, with or */
- /* without modification, are permitted provided that the following */
- /* conditions are met: */
- /* */
- /* 1. Redistributions of source code must retain the above */
- /* copyright notice, this list of conditions and the following */
- /* disclaimer. */
- /* */
- /* 2. Redistributions in binary form must reproduce the above */
- /* copyright notice, this list of conditions and the following */
- /* disclaimer in the documentation and/or other materials */
- /* provided with the distribution. */
- /* */
- /* THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY OF TEXAS AT */
- /* AUSTIN ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, */
- /* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF */
- /* MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE */
- /* DISCLAIMED. IN NO EVENT SHALL THE UNIVERSITY OF TEXAS AT */
- /* AUSTIN OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, */
- /* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES */
- /* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE */
- /* GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR */
- /* BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF */
- /* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT */
- /* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT */
- /* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE */
- /* POSSIBILITY OF SUCH DAMAGE. */
- /* */
- /* The views and conclusions contained in the software and */
- /* documentation are those of the authors and should not be */
- /* interpreted as representing official policies, either expressed */
- /* or implied, of The University of Texas at Austin. */
- /*********************************************************************/
-
- #define ASSEMBLER
- #include "common.h"
-
- #ifndef WINDOWS_ABI
- #define M ARG1
- #define X ARG4
- #define INCX ARG5
- #define Y ARG6
- #define INCY ARG2
- #else
- #define M ARG1
- #define X ARG2
- #define INCX ARG3
- #define Y ARG4
- #define INCY %rbx
- #endif
-
- #include "l1param.h"
-
- PROLOGUE
- PROFCODE
-
- #ifndef WINDOWS_ABI
- movq 8(%rsp), INCY
- #else
- pushq %rbx
-
- movq 48(%rsp), X
- movq 56(%rsp), INCX
- movq 64(%rsp), Y
- movq 72(%rsp), INCY
- #endif
-
- SAVEREGISTERS
-
- leaq (, INCX, SIZE), INCX
- leaq (, INCY, SIZE), INCY
-
- cmpq $SIZE, INCX
- jne .L50
- cmpq $SIZE, INCY
- jne .L50
-
- subq $-32 * SIZE, X
- subq $-32 * SIZE, Y
-
- cmpq $3, M
- jle .L16
-
- testq $SIZE, Y
- je .L05
-
- movss -32 * SIZE(X), %xmm0
- movss -32 * SIZE(Y), %xmm1
-
- movss %xmm1, -32 * SIZE(X)
- movss %xmm0, -32 * SIZE(Y)
-
- addq $1 * SIZE, X
- addq $1 * SIZE, Y
- decq M
- ALIGN_3
-
- .L05:
- testq $2 * SIZE, Y
- je .L10
-
- movsd -32 * SIZE(X), %xmm0
- movsd -32 * SIZE(Y), %xmm1
-
- movlps %xmm1, -32 * SIZE(X)
- movlps %xmm0, -32 * SIZE(Y)
-
- addq $2 * SIZE, X
- addq $2 * SIZE, Y
- subq $2, M
- jle .L19
- ALIGN_3
-
- .L10:
- cmpq $3, M
- jle .L16
-
- testq $2 * SIZE, X
- jne .L30
-
- testq $1 * SIZE, X
- jne .L20
-
- movq M, %rax
- sarq $5, %rax
- jle .L13
- ALIGN_3
-
- .L11:
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 0) - PREOFFSET(X)
- #endif
-
- movaps -32 * SIZE(X), %xmm0
- movaps -32 * SIZE(Y), %xmm1
-
- movaps %xmm0, -32 * SIZE(Y)
- movaps %xmm1, -32 * SIZE(X)
-
- movaps -28 * SIZE(X), %xmm0
- movaps -28 * SIZE(Y), %xmm1
-
- movaps %xmm0, -28 * SIZE(Y)
- movaps %xmm1, -28 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 0) - PREOFFSET(Y)
- #endif
-
- movaps -24 * SIZE(X), %xmm0
- movaps -24 * SIZE(Y), %xmm1
-
- movaps %xmm0, -24 * SIZE(Y)
- movaps %xmm1, -24 * SIZE(X)
-
- movaps -20 * SIZE(X), %xmm0
- movaps -20 * SIZE(Y), %xmm1
-
- movaps %xmm0, -20 * SIZE(Y)
- movaps %xmm1, -20 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 64) - PREOFFSET(X)
- #endif
-
- movaps -16 * SIZE(X), %xmm0
- movaps -16 * SIZE(Y), %xmm1
-
- movaps %xmm0, -16 * SIZE(Y)
- movaps %xmm1, -16 * SIZE(X)
-
- movaps -12 * SIZE(X), %xmm0
- movaps -12 * SIZE(Y), %xmm1
-
- movaps %xmm0, -12 * SIZE(Y)
- movaps %xmm1, -12 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 64) - PREOFFSET(Y)
- #endif
-
- movaps -8 * SIZE(X), %xmm0
- movaps -8 * SIZE(Y), %xmm1
-
- movaps %xmm0, -8 * SIZE(Y)
- movaps %xmm1, -8 * SIZE(X)
-
- movaps -4 * SIZE(X), %xmm0
- movaps -4 * SIZE(Y), %xmm1
-
- movaps %xmm0, -4 * SIZE(Y)
- movaps %xmm1, -4 * SIZE(X)
-
- subq $-32 * SIZE, Y
- subq $-32 * SIZE, X
-
- decq %rax
- jg .L11
- ALIGN_3
-
- .L13:
- testq $16, M
- jle .L14
-
- movaps -32 * SIZE(X), %xmm0
- movaps -32 * SIZE(Y), %xmm1
-
- movaps %xmm0, -32 * SIZE(Y)
- movaps %xmm1, -32 * SIZE(X)
-
- movaps -28 * SIZE(X), %xmm0
- movaps -28 * SIZE(Y), %xmm1
-
- movaps %xmm0, -28 * SIZE(Y)
- movaps %xmm1, -28 * SIZE(X)
-
- movaps -24 * SIZE(X), %xmm0
- movaps -24 * SIZE(Y), %xmm1
-
- movaps %xmm0, -24 * SIZE(Y)
- movaps %xmm1, -24 * SIZE(X)
-
- movaps -20 * SIZE(X), %xmm0
- movaps -20 * SIZE(Y), %xmm1
-
- movaps %xmm0, -20 * SIZE(Y)
- movaps %xmm1, -20 * SIZE(X)
-
- addq $16 * SIZE, X
- addq $16 * SIZE, Y
- ALIGN_3
-
- .L14:
- testq $8, M
- jle .L15
-
- movaps -32 * SIZE(X), %xmm0
- movaps -32 * SIZE(Y), %xmm1
-
- movaps %xmm0, -32 * SIZE(Y)
- movaps %xmm1, -32 * SIZE(X)
-
- movaps -28 * SIZE(X), %xmm0
- movaps -28 * SIZE(Y), %xmm1
-
- movaps %xmm0, -28 * SIZE(Y)
- movaps %xmm1, -28 * SIZE(X)
-
- addq $8 * SIZE, X
- addq $8 * SIZE, Y
- ALIGN_3
-
- .L15:
- testq $4, M
- jle .L16
-
- movaps -32 * SIZE(X), %xmm0
- movaps -32 * SIZE(Y), %xmm1
-
- movaps %xmm0, -32 * SIZE(Y)
- movaps %xmm1, -32 * SIZE(X)
-
- addq $4 * SIZE, X
- addq $4 * SIZE, Y
- ALIGN_3
-
- .L16:
- testq $2, M
- jle .L17
-
- movsd -32 * SIZE(X), %xmm0
- movsd -32 * SIZE(Y), %xmm1
-
- movlps %xmm1, -32 * SIZE(X)
- addq $2 * SIZE, X
- movlps %xmm0, -32 * SIZE(Y)
- addq $2 * SIZE, Y
- ALIGN_3
-
- .L17:
- testq $1, M
- jle .L19
-
- movss -32 * SIZE(X), %xmm0
- movss -32 * SIZE(Y), %xmm1
-
- movss %xmm1, -32 * SIZE(X)
- movss %xmm0, -32 * SIZE(Y)
- ALIGN_3
-
- .L19:
- xorq %rax,%rax
-
- RESTOREREGISTERS
-
- #ifdef WINDOWS_ABI
- popq %rbx
- #endif
-
- ret
- ALIGN_3
-
- .L20:
- movaps -33 * SIZE(X), %xmm0
- movaps -32 * SIZE(Y), %xmm1
-
- movss %xmm1, -32 * SIZE(X)
- pshufd $0x39, %xmm1, %xmm3
- movlps %xmm3, -31 * SIZE(X)
-
- subq $3, M
-
- movq M, %rax
- sarq $5, %rax
- jle .L23
- ALIGN_4
-
- .L21:
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 0) - PREOFFSET(X)
- #endif
-
- movaps -29 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x39, %xmm0, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x93, %xmm3, %xmm1
- movaps %xmm1, -29 * SIZE(X)
-
- movaps -25 * SIZE(X), %xmm0
- movaps -24 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x39, %xmm2, %xmm2
- movaps %xmm2, -28 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x93, %xmm1, %xmm3
- movaps %xmm3, -25 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 0) - PREOFFSET(Y)
- #endif
-
- movaps -21 * SIZE(X), %xmm2
- movaps -20 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x39, %xmm0, %xmm0
- movaps %xmm0, -24 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x93, %xmm3, %xmm1
- movaps %xmm1, -21 * SIZE(X)
-
- movaps -17 * SIZE(X), %xmm0
- movaps -16 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x39, %xmm2, %xmm2
- movaps %xmm2, -20 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x93, %xmm1, %xmm3
- movaps %xmm3, -17 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 64) - PREOFFSET(X)
- #endif
-
- movaps -13 * SIZE(X), %xmm2
- movaps -12 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x39, %xmm0, %xmm0
- movaps %xmm0, -16 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x93, %xmm3, %xmm1
- movaps %xmm1, -13 * SIZE(X)
-
- movaps -9 * SIZE(X), %xmm0
- movaps -8 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x39, %xmm2, %xmm2
- movaps %xmm2, -12 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x93, %xmm1, %xmm3
- movaps %xmm3, -9 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 64) - PREOFFSET(Y)
- #endif
-
- movaps -5 * SIZE(X), %xmm2
- movaps -4 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x39, %xmm0, %xmm0
- movaps %xmm0, -8 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x93, %xmm3, %xmm1
- movaps %xmm1, -5 * SIZE(X)
-
- movaps -1 * SIZE(X), %xmm0
- movaps 0 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x39, %xmm2, %xmm2
- movaps %xmm2, -4 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x93, %xmm1, %xmm3
- movaps %xmm3, -1 * SIZE(X)
-
- subq $-32 * SIZE, X
- subq $-32 * SIZE, Y
-
- decq %rax
- jg .L21
- ALIGN_3
-
- .L23:
- testq $16, M
- jle .L24
-
- movaps -29 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x39, %xmm0, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x93, %xmm3, %xmm1
- movaps %xmm1, -29 * SIZE(X)
-
- movaps -25 * SIZE(X), %xmm0
- movaps -24 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x39, %xmm2, %xmm2
- movaps %xmm2, -28 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x93, %xmm1, %xmm3
- movaps %xmm3, -25 * SIZE(X)
-
- movaps -21 * SIZE(X), %xmm2
- movaps -20 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x39, %xmm0, %xmm0
- movaps %xmm0, -24 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x93, %xmm3, %xmm1
- movaps %xmm1, -21 * SIZE(X)
-
- movaps -17 * SIZE(X), %xmm0
- movaps -16 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x39, %xmm2, %xmm2
- movaps %xmm2, -20 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x93, %xmm1, %xmm3
- movaps %xmm3, -17 * SIZE(X)
-
- addq $16 * SIZE, X
- addq $16 * SIZE, Y
- ALIGN_3
-
- .L24:
- testq $8, M
- jle .L25
-
- movaps -29 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x39, %xmm0, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x93, %xmm3, %xmm1
- movaps %xmm1, -29 * SIZE(X)
-
- movaps -25 * SIZE(X), %xmm0
- movaps -24 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x39, %xmm2, %xmm2
- movaps %xmm2, -28 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x93, %xmm1, %xmm3
- movaps %xmm3, -25 * SIZE(X)
-
- addq $8 * SIZE, X
- addq $8 * SIZE, Y
- ALIGN_3
-
- .L25:
- testq $4, M
- jle .L26
-
- movaps -29 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x39, %xmm0, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x93, %xmm3, %xmm1
- movaps %xmm1, -29 * SIZE(X)
-
- movaps %xmm2, %xmm0
- movaps %xmm3, %xmm1
-
- addq $4 * SIZE, X
- addq $4 * SIZE, Y
- ALIGN_3
-
- .L26:
- pshufd $0x39, %xmm0, %xmm2
- pshufd $0xff, %xmm0, %xmm0
-
- movlps %xmm2, -32 * SIZE(Y)
- movss %xmm0, -30 * SIZE(Y)
-
- testq $2, M
- jle .L27
-
- movsd -29 * SIZE(X), %xmm0
- movsd -29 * SIZE(Y), %xmm1
-
- movlps %xmm0, -29 * SIZE(Y)
- movlps %xmm1, -29 * SIZE(X)
-
- addq $2 * SIZE, X
- addq $2 * SIZE, Y
- ALIGN_3
-
- .L27:
- testq $1, M
- jle .L29
-
- movss -29 * SIZE(X), %xmm0
- movss -29 * SIZE(Y), %xmm1
-
- movss %xmm0, -29 * SIZE(Y)
- movss %xmm1, -29 * SIZE(X)
- ALIGN_3
-
- .L29:
- xorq %rax,%rax
-
- RESTOREREGISTERS
-
- #ifdef WINDOWS_ABI
- popq %rbx
- #endif
-
- ret
- ALIGN_3
-
- .L30:
- testq $1 * SIZE, X
- jne .L40
-
- movhps -32 * SIZE(X), %xmm0
- movaps -32 * SIZE(Y), %xmm1
-
- movlps %xmm1, -32 * SIZE(X)
- subq $2, M
-
- movq M, %rax
- sarq $5, %rax
- jle .L33
- ALIGN_4
-
- .L31:
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 0) - PREOFFSET(X)
- #endif
-
- movaps -30 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- SHUFPD_1 %xmm2, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- SHUFPD_1 %xmm3, %xmm1
- movaps %xmm1, -30 * SIZE(X)
-
- movaps -26 * SIZE(X), %xmm0
- movaps -24 * SIZE(Y), %xmm1
-
- SHUFPD_1 %xmm0, %xmm2
- movaps %xmm2, -28 * SIZE(Y)
- SHUFPD_1 %xmm1, %xmm3
- movaps %xmm3, -26 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 0) - PREOFFSET(Y)
- #endif
-
- movaps -22 * SIZE(X), %xmm2
- movaps -20 * SIZE(Y), %xmm3
-
- SHUFPD_1 %xmm2, %xmm0
- movaps %xmm0, -24 * SIZE(Y)
- SHUFPD_1 %xmm3, %xmm1
- movaps %xmm1, -22 * SIZE(X)
-
- movaps -18 * SIZE(X), %xmm0
- movaps -16 * SIZE(Y), %xmm1
-
- SHUFPD_1 %xmm0, %xmm2
- movaps %xmm2, -20 * SIZE(Y)
- SHUFPD_1 %xmm1, %xmm3
- movaps %xmm3, -18 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 64) - PREOFFSET(X)
- #endif
-
- movaps -14 * SIZE(X), %xmm2
- movaps -12 * SIZE(Y), %xmm3
-
- SHUFPD_1 %xmm2, %xmm0
- movaps %xmm0, -16 * SIZE(Y)
- SHUFPD_1 %xmm3, %xmm1
- movaps %xmm1, -14 * SIZE(X)
-
- movaps -10 * SIZE(X), %xmm0
- movaps -8 * SIZE(Y), %xmm1
-
- SHUFPD_1 %xmm0, %xmm2
- movaps %xmm2, -12 * SIZE(Y)
- SHUFPD_1 %xmm1, %xmm3
- movaps %xmm3, -10 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 64) - PREOFFSET(Y)
- #endif
-
- movaps -6 * SIZE(X), %xmm2
- movaps -4 * SIZE(Y), %xmm3
-
- SHUFPD_1 %xmm2, %xmm0
- movaps %xmm0, -8 * SIZE(Y)
- SHUFPD_1 %xmm3, %xmm1
- movaps %xmm1, -6 * SIZE(X)
-
- movaps -2 * SIZE(X), %xmm0
- movaps 0 * SIZE(Y), %xmm1
-
- SHUFPD_1 %xmm0, %xmm2
- movaps %xmm2, -4 * SIZE(Y)
- SHUFPD_1 %xmm1, %xmm3
- movaps %xmm3, -2 * SIZE(X)
-
- subq $-32 * SIZE, X
- subq $-32 * SIZE, Y
-
- decq %rax
- jg .L31
- ALIGN_3
-
- .L33:
- testq $16, M
- jle .L34
-
- movaps -30 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- SHUFPD_1 %xmm2, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- SHUFPD_1 %xmm3, %xmm1
- movaps %xmm1, -30 * SIZE(X)
-
- movaps -26 * SIZE(X), %xmm0
- movaps -24 * SIZE(Y), %xmm1
-
- SHUFPD_1 %xmm0, %xmm2
- movaps %xmm2, -28 * SIZE(Y)
- SHUFPD_1 %xmm1, %xmm3
- movaps %xmm3, -26 * SIZE(X)
-
- movaps -22 * SIZE(X), %xmm2
- movaps -20 * SIZE(Y), %xmm3
-
- SHUFPD_1 %xmm2, %xmm0
- movaps %xmm0, -24 * SIZE(Y)
- SHUFPD_1 %xmm3, %xmm1
- movaps %xmm1, -22 * SIZE(X)
-
- movaps -18 * SIZE(X), %xmm0
- movaps -16 * SIZE(Y), %xmm1
-
- SHUFPD_1 %xmm0, %xmm2
- movaps %xmm2, -20 * SIZE(Y)
- SHUFPD_1 %xmm1, %xmm3
- movaps %xmm3, -18 * SIZE(X)
-
- addq $16 * SIZE, X
- addq $16 * SIZE, Y
- ALIGN_3
-
- .L34:
- testq $8, M
- jle .L35
-
- movaps -30 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- SHUFPD_1 %xmm2, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- SHUFPD_1 %xmm3, %xmm1
- movaps %xmm1, -30 * SIZE(X)
-
- movaps -26 * SIZE(X), %xmm0
- movaps -24 * SIZE(Y), %xmm1
-
- SHUFPD_1 %xmm0, %xmm2
- movaps %xmm2, -28 * SIZE(Y)
- SHUFPD_1 %xmm1, %xmm3
- movaps %xmm3, -26 * SIZE(X)
-
- addq $8 * SIZE, X
- addq $8 * SIZE, Y
- ALIGN_3
-
- .L35:
- testq $4, M
- jle .L36
-
- movaps -30 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- SHUFPD_1 %xmm2, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- SHUFPD_1 %xmm3, %xmm1
- movaps %xmm1, -30 * SIZE(X)
-
- movaps %xmm2, %xmm0
- movaps %xmm3, %xmm1
-
- addq $4 * SIZE, X
- addq $4 * SIZE, Y
- ALIGN_3
-
- .L36:
- movhps %xmm0, -32 * SIZE(Y)
-
- testq $2, M
- jle .L37
-
- movsd -30 * SIZE(X), %xmm0
- movsd -30 * SIZE(Y), %xmm1
-
- movlps %xmm0, -30 * SIZE(Y)
- movlps %xmm1, -30 * SIZE(X)
-
- addq $2 * SIZE, X
- addq $2 * SIZE, Y
- ALIGN_3
-
- .L37:
- testq $1, M
- jle .L39
-
- movss -30 * SIZE(X), %xmm0
- movss -30 * SIZE(Y), %xmm1
-
- movss %xmm0, -30 * SIZE(Y)
- movss %xmm1, -30 * SIZE(X)
- ALIGN_3
-
- .L39:
- xorq %rax,%rax
-
- RESTOREREGISTERS
-
- #ifdef WINDOWS_ABI
- popq %rbx
- #endif
-
- ret
- ALIGN_3
-
- .L40:
- movaps -35 * SIZE(X), %xmm0
- movaps -32 * SIZE(Y), %xmm1
-
- movss %xmm1, -32 * SIZE(X)
-
- subq $3, M
-
- movq M, %rax
- sarq $5, %rax
- jle .L43
- ALIGN_4
-
- .L41:
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 0) - PREOFFSET(X)
- #endif
-
- movaps -31 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x93, %xmm2, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x39, %xmm1, %xmm1
- movaps %xmm1, -31 * SIZE(X)
-
- movaps -27 * SIZE(X), %xmm0
- movaps -24 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x93, %xmm0, %xmm2
- movaps %xmm2, -28 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x39, %xmm3, %xmm3
- movaps %xmm3, -27 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 0) - PREOFFSET(Y)
- #endif
-
- movaps -23 * SIZE(X), %xmm2
- movaps -20 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x93, %xmm2, %xmm0
- movaps %xmm0, -24 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x39, %xmm1, %xmm1
- movaps %xmm1, -23 * SIZE(X)
-
- movaps -19 * SIZE(X), %xmm0
- movaps -16 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x93, %xmm0, %xmm2
- movaps %xmm2, -20 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x39, %xmm3, %xmm3
- movaps %xmm3, -19 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 64) - PREOFFSET(X)
- #endif
-
- movaps -15 * SIZE(X), %xmm2
- movaps -12 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x93, %xmm2, %xmm0
- movaps %xmm0, -16 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x39, %xmm1, %xmm1
- movaps %xmm1, -15 * SIZE(X)
-
- movaps -11 * SIZE(X), %xmm0
- movaps -8 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x93, %xmm0, %xmm2
- movaps %xmm2, -12 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x39, %xmm3, %xmm3
- movaps %xmm3, -11 * SIZE(X)
-
- #ifdef PREFETCHW
- PREFETCHW (PREFETCHSIZE + 64) - PREOFFSET(Y)
- #endif
-
- movaps -7 * SIZE(X), %xmm2
- movaps -4 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x93, %xmm2, %xmm0
- movaps %xmm0, -8 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x39, %xmm1, %xmm1
- movaps %xmm1, -7 * SIZE(X)
-
- movaps -3 * SIZE(X), %xmm0
- movaps 0 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x93, %xmm0, %xmm2
- movaps %xmm2, -4 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x39, %xmm3, %xmm3
- movaps %xmm3, -3 * SIZE(X)
-
- subq $-32 * SIZE, X
- subq $-32 * SIZE, Y
-
- decq %rax
- jg .L41
- ALIGN_3
-
- .L43:
- testq $16, M
- jle .L44
-
- movaps -31 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x93, %xmm2, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x39, %xmm1, %xmm1
- movaps %xmm1, -31 * SIZE(X)
-
- movaps -27 * SIZE(X), %xmm0
- movaps -24 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x93, %xmm0, %xmm2
- movaps %xmm2, -28 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x39, %xmm3, %xmm3
- movaps %xmm3, -27 * SIZE(X)
-
- movaps -23 * SIZE(X), %xmm2
- movaps -20 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x93, %xmm2, %xmm0
- movaps %xmm0, -24 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x39, %xmm1, %xmm1
- movaps %xmm1, -23 * SIZE(X)
-
- movaps -19 * SIZE(X), %xmm0
- movaps -16 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x93, %xmm0, %xmm2
- movaps %xmm2, -20 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x39, %xmm3, %xmm3
- movaps %xmm3, -19 * SIZE(X)
-
- addq $16 * SIZE, X
- addq $16 * SIZE, Y
- ALIGN_3
-
- .L44:
- testq $8, M
- jle .L45
-
- movaps -31 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x93, %xmm2, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x39, %xmm1, %xmm1
- movaps %xmm1, -31 * SIZE(X)
-
- movaps -27 * SIZE(X), %xmm0
- movaps -24 * SIZE(Y), %xmm1
-
- movss %xmm0, %xmm2
- shufps $0x93, %xmm0, %xmm2
- movaps %xmm2, -28 * SIZE(Y)
- movss %xmm1, %xmm3
- shufps $0x39, %xmm3, %xmm3
- movaps %xmm3, -27 * SIZE(X)
-
- addq $8 * SIZE, X
- addq $8 * SIZE, Y
- ALIGN_3
-
- .L45:
- testq $4, M
- jle .L46
-
- movaps -31 * SIZE(X), %xmm2
- movaps -28 * SIZE(Y), %xmm3
-
- movss %xmm2, %xmm0
- shufps $0x93, %xmm2, %xmm0
- movaps %xmm0, -32 * SIZE(Y)
- movss %xmm3, %xmm1
- shufps $0x39, %xmm1, %xmm1
- movaps %xmm1, -31 * SIZE(X)
-
- movaps %xmm2, %xmm0
- movaps %xmm3, %xmm1
-
- addq $4 * SIZE, X
- addq $4 * SIZE, Y
- ALIGN_3
-
- .L46:
- movsd -31 * SIZE(X), %xmm2
-
- pshufd $0x39, %xmm1, %xmm1
- movlps %xmm1, -31 * SIZE(X)
-
- pshufd $0xff, %xmm0, %xmm0
-
- movss %xmm0, -32 * SIZE(Y)
- movlps %xmm2, -31 * SIZE(Y)
-
- addq $3 * SIZE, X
- addq $3 * SIZE, Y
-
- testq $2, M
- jle .L47
-
- movsd -32 * SIZE(X), %xmm0
- movsd -32 * SIZE(Y), %xmm1
-
- movlps %xmm0, -32 * SIZE(Y)
- movlps %xmm1, -32 * SIZE(X)
-
- addq $2 * SIZE, X
- addq $2 * SIZE, Y
- ALIGN_3
-
- .L47:
- testq $1, M
- jle .L49
-
- movss -32 * SIZE(X), %xmm0
- movss -32 * SIZE(Y), %xmm1
-
- movss %xmm0, -32 * SIZE(Y)
- movss %xmm1, -32 * SIZE(X)
- ALIGN_3
-
- .L49:
- xorq %rax,%rax
-
- RESTOREREGISTERS
-
- #ifdef WINDOWS_ABI
- popq %rbx
- #endif
-
- ret
- ALIGN_3
-
- .L50:
- movq M, %rax
- sarq $3, %rax
- jle .L55
- ALIGN_3
-
- .L51:
- movss (X), %xmm0
- movss (Y), %xmm1
-
- movss %xmm1, (X)
- addq INCX, X
- movss %xmm0, (Y)
- addq INCY, Y
-
- movss (X), %xmm0
- movss (Y), %xmm1
-
- movss %xmm1, (X)
- addq INCX, X
- movss %xmm0, (Y)
- addq INCY, Y
-
- movss (X), %xmm0
- movss (Y), %xmm1
-
- movss %xmm1, (X)
- addq INCX, X
- movss %xmm0, (Y)
- addq INCY, Y
-
- movss (X), %xmm0
- movss (Y), %xmm1
-
- movss %xmm1, (X)
- addq INCX, X
- movss %xmm0, (Y)
- addq INCY, Y
-
- movss (X), %xmm0
- movss (Y), %xmm1
-
- movss %xmm1, (X)
- addq INCX, X
- movss %xmm0, (Y)
- addq INCY, Y
-
- movss (X), %xmm0
- movss (Y), %xmm1
-
- movss %xmm1, (X)
- addq INCX, X
- movss %xmm0, (Y)
- addq INCY, Y
-
- movss (X), %xmm0
- movss (Y), %xmm1
-
- movss %xmm1, (X)
- addq INCX, X
- movss %xmm0, (Y)
- addq INCY, Y
-
- movss (X), %xmm0
- movss (Y), %xmm1
-
- movss %xmm1, (X)
- addq INCX, X
- movss %xmm0, (Y)
- addq INCY, Y
-
- decq %rax
- jg .L51
- ALIGN_3
-
- .L55:
- movq M, %rax
- andq $7, %rax
- jle .L57
- ALIGN_3
-
- .L56:
- movss (X), %xmm0
- movss (Y), %xmm1
-
- movss %xmm1, (X)
- movss %xmm0, (Y)
-
- addq INCX, X
- addq INCY, Y
- decq %rax
- jg .L56
- ALIGN_3
-
- .L57:
- xorq %rax, %rax
-
- RESTOREREGISTERS
-
- #ifdef WINDOWS_ABI
- popq %rbx
- #endif
-
- ret
-
- EPILOGUE
|