📄 trsm_kernel_ln_4x4_penryn.s
字号:
#endif#if defined(LT) || defined(RN) movq K, %rax subq KK, %rax leaq (,%rax, SIZE), %rax leaq (AO, %rax, 4), AO leaq (BO, %rax, 2), BO#endif#ifdef LN subq $4, KK#endif#ifdef LT addq $4, KK#endif#ifdef RT movq K, %rax salq $2 + BASE_SHIFT, %rax addq %rax, AORIG#endif decq I jg,pt .L51 ALIGN_4 .L79:#ifdef LN leaq (, K, SIZE), %rax leaq (B, %rax, 2), B#endif#if defined(LT) || defined(RN) movq BO, B#endif#ifdef RN addq $2, KK#endif#ifdef RT subq $2, KK#endif ALIGN_4.L80: testq $1, N jle,pt .L999#if defined(LT) || defined(RN) movq A, AO#else movq A, AORIG#endif#ifdef RT movq K, %rax salq $BASE_SHIFT, %rax subq %rax, B subq LDC, C#endif movq C, CO1#ifndef RT addq LDC, C#endif#ifdef LN movq OFFSET, %rax addq M, %rax movq %rax, KK#endif #ifdef LT movq OFFSET, %rax movq %rax, KK#endif testq $1, M jle,pt .L90 #ifdef LN movq K, %rax salq $BASE_SHIFT, %rax subq %rax, AORIG#endif#if defined(LN) || defined(RT) movq KK, %rax leaq (, %rax, SIZE), %rax movq AORIG, AO leaq (AO, %rax, 1), AO leaq (B, %rax, 1), BO#else movq B, BO#endif movsd -16 * SIZE(AO), %xmm0 movsd -16 * SIZE(BO), %xmm2 pxor %xmm8, %xmm8 pxor %xmm9, %xmm9#if defined(LT) || defined(RN) movq KK, %rax#else movq K, %rax subq KK, %rax#endif sarq $2, %rax jle,pn .L115 ALIGN_4.L112: PREFETCH (PREFETCHSIZE + 0) * SIZE(AO) mulsd %xmm0, %xmm2 addsd %xmm2, %xmm8 movsd -15 * SIZE(AO), %xmm0 movsd -15 * SIZE(BO), %xmm2 mulsd %xmm0, %xmm2 addsd %xmm2, %xmm8 movsd -14 * SIZE(AO), %xmm0 movsd -14 * SIZE(BO), %xmm2 mulsd %xmm0, %xmm2 addsd %xmm2, %xmm8 movsd -13 * SIZE(AO), %xmm0 movsd -13 * SIZE(BO), %xmm2 mulsd %xmm0, %xmm2 addsd %xmm2, %xmm8 movsd -12 * SIZE(AO), %xmm0 movsd -12 * SIZE(BO), %xmm2 subq $-4 * SIZE, AO subq $-4 * SIZE, BO subq $1, %rax jg,pt .L112 ALIGN_4.L115:#if defined(LT) || defined(RN) movq KK, %rax#else movq K, %rax subq KK, %rax#endif andq $3, %rax # if (k & 1) je,pt .L118 ALIGN_4.L116: mulsd %xmm0, %xmm2 addsd %xmm2, %xmm8 movsd -15 * SIZE(AO), %xmm0 movsd -15 * SIZE(BO), %xmm2 addq $1 * SIZE, AO addq $1 * SIZE, BO subq $1, %rax jg,pt .L116 ALIGN_4.L118:#if defined(LN) || defined(RT) movq KK, %rax subq $1, %rax leaq (, %rax, SIZE), %rax movq AORIG, AO leaq (AO, %rax, 1), AO leaq (B, %rax, 1), BO#endif addpd %xmm9, %xmm8#if defined(LN) || defined(LT) movsd -16 * SIZE(BO), %xmm10 subsd %xmm8, %xmm10#else movsd -16 * SIZE(AO), %xmm10 subsd %xmm8, %xmm10#endif#ifdef LN movsd -16 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm10#endif#ifdef LT movsd -16 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm10#endif#ifdef RN movsd -16 * SIZE(BO), %xmm8 mulsd %xmm8, %xmm10#endif#ifdef RT movsd -16 * SIZE(BO), %xmm8 mulsd %xmm8, %xmm10#endif#ifdef LN subq $1 * SIZE, CO1#endif#if defined(LN) || defined(LT) movsd %xmm10, 0 * SIZE(CO1)#else movsd %xmm10, 0 * SIZE(CO1)#endif#if defined(LN) || defined(LT) movsd %xmm10, -16 * SIZE(BO)#else movsd %xmm10, -16 * SIZE(AO)#endif#ifndef LN addq $1 * SIZE, CO1#endif#if defined(LT) || defined(RN) movq K, %rax subq KK, %rax leaq (,%rax, SIZE), %rax leaq (AO, %rax, 1), AO leaq (BO, %rax, 1), BO#endif#ifdef LN subq $1, KK#endif#ifdef LT addq $1, KK#endif#ifdef RT movq K, %rax salq $BASE_SHIFT, %rax addq %rax, AORIG#endif ALIGN_4 .L90: testq $2, M jle,pt .L110 ALIGN_4#ifdef LN movq K, %rax salq $1 + BASE_SHIFT, %rax subq %rax, AORIG#endif#if defined(LN) || defined(RT) movq KK, %rax leaq (, %rax, SIZE), %rax movq AORIG, AO leaq (AO, %rax, 2), AO leaq (B, %rax, 1), BO#else movq B, BO#endif movaps -16 * SIZE(AO), %xmm0 pxor %xmm8, %xmm8 movsd -16 * SIZE(BO), %xmm2 pxor %xmm9, %xmm9 movhps -15 * SIZE(BO), %xmm2#if defined(LT) || defined(RN) movq KK, %rax#else movq K, %rax subq KK, %rax#endif sarq $2, %rax jle,pn .L105 ALIGN_4.L102: PREFETCH (PREFETCHSIZE + 0) * SIZE(AO) pshufd $0x44, %xmm2, %xmm3 movsd -15 * SIZE(BO), %xmm2 mulpd %xmm0, %xmm3 movaps -14 * SIZE(AO), %xmm0 addpd %xmm3, %xmm8 pshufd $0x44, %xmm2, %xmm3 movsd -14 * SIZE(BO), %xmm2 mulpd %xmm0, %xmm3 movaps -12 * SIZE(AO), %xmm0 addpd %xmm3, %xmm9 pshufd $0x44, %xmm2, %xmm3 movsd -13 * SIZE(BO), %xmm2 mulpd %xmm0, %xmm3 movaps -10 * SIZE(AO), %xmm0 addpd %xmm3, %xmm8 pshufd $0x44, %xmm2, %xmm3 movsd -12 * SIZE(BO), %xmm2 mulpd %xmm0, %xmm3 movaps -8 * SIZE(AO), %xmm0 addpd %xmm3, %xmm9 subq $-8 * SIZE, AO subq $-4 * SIZE, BO subq $1, %rax jg,pt .L102 ALIGN_4.L105:#if defined(LT) || defined(RN) movq KK, %rax#else movq K, %rax subq KK, %rax#endif andq $3, %rax # if (k & 1) je,pt .L108 ALIGN_4.L106: pshufd $0x44, %xmm2, %xmm3 movsd -15 * SIZE(BO), %xmm2 mulpd %xmm0, %xmm3 movaps -14 * SIZE(AO), %xmm0 addpd %xmm3, %xmm8 addq $2 * SIZE, AO addq $1 * SIZE, BO subq $1, %rax jg,pt .L106 ALIGN_4.L108:#if defined(LN) || defined(RT) movq KK, %rax#ifdef LN subq $2, %rax#else subq $1, %rax#endif leaq (, %rax, SIZE), %rax movq AORIG, AO leaq (AO, %rax, 2), AO leaq (B, %rax, 1), BO#endif addpd %xmm9, %xmm8#if defined(LN) || defined(LT) movapd -16 * SIZE(BO), %xmm10 subpd %xmm8, %xmm10#else movapd -16 * SIZE(AO), %xmm10 subpd %xmm8, %xmm10#endif#ifdef LN movapd %xmm10, %xmm8 unpckhpd %xmm8, %xmm8 movsd -13 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm8 movsd -14 * SIZE(AO), %xmm13 mulsd %xmm8, %xmm13 subsd %xmm13, %xmm10 movsd -16 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm10 unpcklpd %xmm8, %xmm10#endif#ifdef LT movapd %xmm10, %xmm8 unpckhpd %xmm8, %xmm8 movsd -16 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm10 movsd -15 * SIZE(AO), %xmm13 mulsd %xmm10, %xmm13 subsd %xmm13, %xmm8 movsd -13 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm8 unpcklpd %xmm8, %xmm10#endif#ifdef RN movddup -16 * SIZE(BO), %xmm8 mulpd %xmm8, %xmm10#endif#ifdef RT movddup -16 * SIZE(BO), %xmm8 mulpd %xmm8, %xmm10#endif#ifdef LN subq $2 * SIZE, CO1#endif#if defined(LN) || defined(LT) movsd %xmm10, 0 * SIZE(CO1) movhpd %xmm10, 1 * SIZE(CO1)#else movsd %xmm10, 0 * SIZE(CO1) movhpd %xmm10, 1 * SIZE(CO1)#endif#if defined(LN) || defined(LT) movapd %xmm10, -16 * SIZE(BO)#else movapd %xmm10, -16 * SIZE(AO)#endif#ifndef LN addq $2 * SIZE, CO1#endif#if defined(LT) || defined(RN) movq K, %rax subq KK, %rax leaq (,%rax, SIZE), %rax leaq (AO, %rax, 2), AO leaq (BO, %rax, 1), BO#endif#ifdef LN subq $2, KK#endif#ifdef LT addq $2, KK#endif#ifdef RT movq K, %rax salq $1 + BASE_SHIFT, %rax addq %rax, AORIG#endif ALIGN_4 .L110: movq M, I sarq $2, I # i = (m >> 2) jle,pn .L119 ALIGN_4.L91:#ifdef LN movq K, %rax salq $2 + BASE_SHIFT, %rax subq %rax, AORIG#endif#if defined(LN) || defined(RT) movq KK, %rax leaq (, %rax, SIZE), %rax movq AORIG, AO leaq (AO, %rax, 4), AO leaq (B, %rax, 1), BO#else movq B, BO#endif movaps -16 * SIZE(AO), %xmm0 movaps -14 * SIZE(AO), %xmm1 movsd -16 * SIZE(BO), %xmm2#ifdef LN prefetcht0 -4 * SIZE(CO1)#else prefetcht0 3 * SIZE(CO1)#endif pxor %xmm8, %xmm8 pxor %xmm9, %xmm9 pxor %xmm12, %xmm12 pxor %xmm13, %xmm13#if defined(LT) || defined(RN) movq KK, %rax#else movq K, %rax subq KK, %rax#endif sarq $2, %rax jle,pn .L95 ALIGN_4.L92: PREFETCH (PREFETCHSIZE + 0) * SIZE(AO) pshufd $0x44, %xmm2, %xmm3 pshufd $0x44, %xmm2, %xmm4 movsd -15 * SIZE(BO), %xmm2 mulpd %xmm0, %xmm3 movaps -12 * SIZE(AO), %xmm0 mulpd %xmm1, %xmm4 movaps -10 * SIZE(AO), %xmm1 addpd %xmm3, %xmm8 addpd %xmm4, %xmm12 pshufd $0x44, %xmm2, %xmm3 pshufd $0x44, %xmm2, %xmm4 movsd -14 * SIZE(BO), %xmm2 mulpd %xmm0, %xmm3 movaps -8 * SIZE(AO), %xmm0 mulpd %xmm1, %xmm4 movaps -6 * SIZE(AO), %xmm1 addpd %xmm3, %xmm8 addpd %xmm4, %xmm12 PREFETCH (PREFETCHSIZE + 8) * SIZE(AO) pshufd $0x44, %xmm2, %xmm3 pshufd $0x44, %xmm2, %xmm4 movsd -13 * SIZE(BO), %xmm2 mulpd %xmm0, %xmm3 movaps -4 * SIZE(AO), %xmm0 mulpd %xmm1, %xmm4 movaps -2 * SIZE(AO), %xmm1 addpd %xmm3, %xmm8 addpd %xmm4, %xmm12 pshufd $0x44, %xmm2, %xmm3 pshufd $0x44, %xmm2, %xmm4 movsd -12 * SIZE(BO), %xmm2 mulpd %xmm0, %xmm3 movaps 0 * SIZE(AO), %xmm0 mulpd %xmm1, %xmm4 movaps 2 * SIZE(AO), %xmm1 addpd %xmm3, %xmm8 addpd %xmm4, %xmm12 subq $-16 * SIZE, AO subq $ -4 * SIZE, BO subq $1, %rax jg,pt .L92 ALIGN_4.L95:#if defined(LT) || defined(RN) movq KK, %rax#else movq K, %rax subq KK, %rax#endif andq $3, %rax # if (k & 1) je,pt .L98 ALIGN_4.L96: pshufd $0x44, %xmm2, %xmm3 pshufd $0x44, %xmm2, %xmm4 movsd -15 * SIZE(BO), %xmm2 mulpd %xmm0, %xmm3 movaps -12 * SIZE(AO), %xmm0 mulpd %xmm1, %xmm4 movaps -10 * SIZE(AO), %xmm1 addpd %xmm3, %xmm8 addpd %xmm4, %xmm12 addq $4 * SIZE, AO addq $1 * SIZE, BO subq $1, %rax jg,pt .L96 ALIGN_4.L98:#if defined(LN) || defined(RT) movq KK, %rax#ifdef LN subq $4, %rax#else subq $1, %rax#endif leaq (, %rax, SIZE), %rax movq AORIG, AO leaq (AO, %rax, 4), AO leaq (B, %rax, 1), BO#endif#if defined(LN) || defined(LT) movapd -16 * SIZE(BO), %xmm10 movapd -14 * SIZE(BO), %xmm11 subpd %xmm8, %xmm10 subpd %xmm12, %xmm11#else movapd -16 * SIZE(AO), %xmm10 movapd -14 * SIZE(AO), %xmm11 subpd %xmm8, %xmm10 subpd %xmm12, %xmm11#endif#ifdef LN movapd %xmm10, %xmm8 unpckhpd %xmm8, %xmm8 movapd %xmm11, %xmm9 unpckhpd %xmm9, %xmm9 movsd -1 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm9 movsd -2 * SIZE(AO), %xmm13 mulsd %xmm9, %xmm13 subsd %xmm13, %xmm11 movsd -3 * SIZE(AO), %xmm14 mulsd %xmm9, %xmm14 subsd %xmm14, %xmm8 movsd -4 * SIZE(AO), %xmm15 mulsd %xmm9, %xmm15 subsd %xmm15, %xmm10 movsd -6 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm11 movsd -7 * SIZE(AO), %xmm13 mulsd %xmm11, %xmm13 subsd %xmm13, %xmm8 movsd -8 * SIZE(AO), %xmm14 mulsd %xmm11, %xmm14 subsd %xmm14, %xmm10 movsd -11 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm8 movsd -12 * SIZE(AO), %xmm13 mulsd %xmm8, %xmm13 subsd %xmm13, %xmm10 movsd -16 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm10 unpcklpd %xmm8, %xmm10 unpcklpd %xmm9, %xmm11#endif#ifdef LT movapd %xmm10, %xmm8 unpckhpd %xmm8, %xmm8 movapd %xmm11, %xmm9 unpckhpd %xmm9, %xmm9 movsd -16 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm10 movsd -15 * SIZE(AO), %xmm13 mulsd %xmm10, %xmm13 subsd %xmm13, %xmm8 movsd -14 * SIZE(AO), %xmm14 mulsd %xmm10, %xmm14 subsd %xmm14, %xmm11 movsd -13 * SIZE(AO), %xmm15 mulsd %xmm10, %xmm15 subsd %xmm15, %xmm9 movsd -11 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm8 movsd -10 * SIZE(AO), %xmm13 mulsd %xmm8, %xmm13 subsd %xmm13, %xmm11 movsd -9 * SIZE(AO), %xmm14 mulsd %xmm8, %xmm14 subsd %xmm14, %xmm9 movsd -6 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm11 movsd -5 * SIZE(AO), %xmm13 mulsd %xmm11, %xmm13 subsd %xmm13, %xmm9 movsd -1 * SIZE(AO), %xmm12 mulsd %xmm12, %xmm9 unpcklpd %xmm8, %xmm10 unpcklpd %xmm9, %xmm11#endif#ifdef RN movddup -16 * SIZE(BO), %xmm8 mulpd %xmm8, %xmm10 mulpd %xmm8, %xmm11#endif#ifdef RT movddup -16 * SIZE(BO), %xmm8 mulpd %xmm8, %xmm10 mulpd %xmm8, %xmm11#endif#ifdef LN subq $4 * SIZE, CO1#endif#if defined(LN) || defined(LT) movsd %xmm10, 0 * SIZE(CO1) movhpd %xmm10, 1 * SIZE(CO1) movsd %xmm11, 2 * SIZE(CO1) movhpd %xmm11, 3 * SIZE(CO1)#else movsd %xmm10, 0 * SIZE(CO1) movhpd %xmm10, 1 * SIZE(CO1) movsd %xmm11, 2 * SIZE(CO1) movhpd %xmm11, 3 * SIZE(CO1)#endif#if defined(LN) || defined(LT) movapd %xmm10, -16 * SIZE(BO) movapd %xmm11, -14 * SIZE(BO)#else movapd %xmm10, -16 * SIZE(AO) movapd %xmm11, -14 * SIZE(AO)#endif#ifndef LN addq $4 * SIZE, CO1#endif#if defined(LT) || defined(RN) movq K, %rax subq KK, %rax leaq (,%rax, SIZE), %rax leaq (AO, %rax, 4), AO leaq (BO, %rax, 1), BO#endif#ifdef LN subq $4, KK#endif#ifdef LT addq $4, KK#endif#ifdef RT movq K, %rax salq $2 + BASE_SHIFT, %rax addq %rax, AORIG#endif decq I jg,pt .L91 ALIGN_4 .L119:#ifdef LN leaq (B, K, SIZE), B#endif#if defined(LT) || defined(RN) movq BO, B#endif#ifdef RN addq $1, KK#endif#ifdef RT subq $1, KK#endif ALIGN_4.L999: movq 0(%rsp), %rbx movq 8(%rsp), %rbp movq 16(%rsp), %r12 movq 24(%rsp), %r13 movq 32(%rsp), %r14 movq 40(%rsp), %r15#ifdef WINDOWS_ABI movq 48(%rsp), %rdi movq 56(%rsp), %rsi movups 64(%rsp), %xmm6 movups 80(%rsp), %xmm7 movups 96(%rsp), %xmm8 movups 112(%rsp), %xmm9 movups 128(%rsp), %xmm10 movups 144(%rsp), %xmm11 movups 160(%rsp), %xmm12 movups 176(%rsp), %xmm13 movups 192(%rsp), %xmm14 movups 208(%rsp), %xmm15#endif addq $STACKSIZE, %rsp ret EPILOGUE
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -