261 lines · plain
1 .text2 .file "matmul.c"3 .section .rodata.cst8,"aM",@progbits,84 .p2align 3 # -- Begin function init_array5.LCPI0_0:6 .quad 4602678819172646912 # double 0.57 .text8 .globl init_array9 .p2align 4, 0x9010 .type init_array,@function11init_array: # @init_array12 .cfi_startproc13# %bb.0: # %entry14 pushq %rbp15 .cfi_def_cfa_offset 1616 .cfi_offset %rbp, -1617 movq %rsp, %rbp18 .cfi_def_cfa_register %rbp19 leaq B(%rip), %rax20 leaq A(%rip), %rcx21 xorl %r8d, %r8d22 movsd .LCPI0_0(%rip), %xmm0 # xmm0 = mem[0],zero23 xorl %r9d, %r9d24 .p2align 4, 0x9025.LBB0_1: # %polly.loop_header26 # =>This Loop Header: Depth=127 # Child Loop BB0_2 Depth 228 movl $1, %edi29 xorl %edx, %edx30 .p2align 4, 0x9031.LBB0_2: # %polly.loop_header132 # Parent Loop BB0_1 Depth=133 # => This Inner Loop Header: Depth=234 movl %edx, %esi35 andl $1022, %esi # imm = 0x3FE36 orl $1, %esi37 xorps %xmm1, %xmm138 cvtsi2sdl %esi, %xmm139 mulsd %xmm0, %xmm140 cvtsd2ss %xmm1, %xmm141 movss %xmm1, -4(%rcx,%rdi,4)42 movss %xmm1, -4(%rax,%rdi,4)43 leal (%r9,%rdx), %esi44 andl $1023, %esi # imm = 0x3FF45 addl $1, %esi46 xorps %xmm1, %xmm147 cvtsi2sdl %esi, %xmm148 mulsd %xmm0, %xmm149 cvtsd2ss %xmm1, %xmm150 movss %xmm1, (%rcx,%rdi,4)51 movss %xmm1, (%rax,%rdi,4)52 addq $2, %rdi53 addl %r8d, %edx54 cmpq $1537, %rdi # imm = 0x60155 jne .LBB0_256# %bb.3: # %polly.loop_exit357 # in Loop: Header=BB0_1 Depth=158 addq $1, %r959 addq $6144, %rax # imm = 0x180060 addq $6144, %rcx # imm = 0x180061 addl $2, %r8d62 cmpq $1536, %r9 # imm = 0x60063 jne .LBB0_164# %bb.4: # %polly.exiting65 popq %rbp66 .cfi_def_cfa %rsp, 867 retq68.Lfunc_end0:69 .size init_array, .Lfunc_end0-init_array70 .cfi_endproc71 # -- End function72 .globl print_array # -- Begin function print_array73 .p2align 4, 0x9074 .type print_array,@function75print_array: # @print_array76 .cfi_startproc77# %bb.0: # %entry78 pushq %rbp79 .cfi_def_cfa_offset 1680 .cfi_offset %rbp, -1681 movq %rsp, %rbp82 .cfi_def_cfa_register %rbp83 pushq %r1584 pushq %r1485 pushq %r1386 pushq %r1287 pushq %rbx88 pushq %rax89 .cfi_offset %rbx, -5690 .cfi_offset %r12, -4891 .cfi_offset %r13, -4092 .cfi_offset %r14, -3293 .cfi_offset %r15, -2494 leaq C(%rip), %r1395 xorl %eax, %eax96 movl $3435973837, %r12d # imm = 0xCCCCCCCD97 leaq .L.str(%rip), %r1498 .p2align 4, 0x9099.LBB1_1: # %for.cond1.preheader100 # =>This Loop Header: Depth=1101 # Child Loop BB1_2 Depth 2102 movq %rax, -48(%rbp) # 8-byte Spill103 movq stdout(%rip), %rsi104 xorl %ebx, %ebx105 .p2align 4, 0x90106.LBB1_2: # %for.body3107 # Parent Loop BB1_1 Depth=1108 # => This Inner Loop Header: Depth=2109 movl %ebx, %eax110 imulq %r12, %rax111 shrq $38, %rax112 leal (%rax,%rax,4), %r15d113 shll $4, %r15d114 addl $79, %r15d115 movss (%r13,%rbx,4), %xmm0 # xmm0 = mem[0],zero,zero,zero116 cvtss2sd %xmm0, %xmm0117 movb $1, %al118 movq %rsi, %rdi119 movq %r14, %rsi120 callq fprintf121 cmpl %ebx, %r15d122 jne .LBB1_4123# %bb.3: # %if.then124 # in Loop: Header=BB1_2 Depth=2125 movq stdout(%rip), %rsi126 movl $10, %edi127 callq fputc@PLT128.LBB1_4: # %for.inc129 # in Loop: Header=BB1_2 Depth=2130 addq $1, %rbx131 movq stdout(%rip), %rsi132 cmpq $1536, %rbx # imm = 0x600133 jne .LBB1_2134# %bb.5: # %for.end135 # in Loop: Header=BB1_1 Depth=1136 movl $10, %edi137 callq fputc@PLT138 movq -48(%rbp), %rax # 8-byte Reload139 addq $1, %rax140 addq $6144, %r13 # imm = 0x1800141 cmpq $1536, %rax # imm = 0x600142 jne .LBB1_1143# %bb.6: # %for.end12144 addq $8, %rsp145 popq %rbx146 popq %r12147 popq %r13148 popq %r14149 popq %r15150 popq %rbp151 .cfi_def_cfa %rsp, 8152 retq153.Lfunc_end1:154 .size print_array, .Lfunc_end1-print_array155 .cfi_endproc156 # -- End function157 .globl main # -- Begin function main158 .p2align 4, 0x90159 .type main,@function160main: # @main161 .cfi_startproc162# %bb.0: # %entry163 pushq %rbp164 .cfi_def_cfa_offset 16165 .cfi_offset %rbp, -16166 movq %rsp, %rbp167 .cfi_def_cfa_register %rbp168 pushq %r14169 pushq %rbx170 .cfi_offset %rbx, -32171 .cfi_offset %r14, -24172 callq init_array173 leaq C(%rip), %rbx174 xorl %r14d, %r14d175 xorl %esi, %esi176 movl $9437184, %edx # imm = 0x900000177 movq %rbx, %rdi178 callq memset@PLT179 leaq B(%rip), %rax180 leaq A(%rip), %rcx181 .p2align 4, 0x90182.LBB2_1: # %polly.loop_header8183 # =>This Loop Header: Depth=1184 # Child Loop BB2_2 Depth 2185 # Child Loop BB2_3 Depth 3186 movq %rax, %rdx187 xorl %esi, %esi188 .p2align 4, 0x90189.LBB2_2: # %polly.loop_header14190 # Parent Loop BB2_1 Depth=1191 # => This Loop Header: Depth=2192 # Child Loop BB2_3 Depth 3193 leaq (%r14,%r14,2), %rdi194 shlq $11, %rdi195 addq %rcx, %rdi196 movss (%rdi,%rsi,4), %xmm0 # xmm0 = mem[0],zero,zero,zero197 shufps $0, %xmm0, %xmm0 # xmm0 = xmm0[0,0,0,0]198 movl $12, %edi199 .p2align 4, 0x90200.LBB2_3: # %vector.body201 # Parent Loop BB2_1 Depth=1202 # Parent Loop BB2_2 Depth=2203 # => This Inner Loop Header: Depth=3204 movaps -48(%rdx,%rdi,4), %xmm1205 mulps %xmm0, %xmm1206 movaps -32(%rdx,%rdi,4), %xmm2207 mulps %xmm0, %xmm2208 addps -48(%rbx,%rdi,4), %xmm1209 addps -32(%rbx,%rdi,4), %xmm2210 movaps %xmm1, -48(%rbx,%rdi,4)211 movaps %xmm2, -32(%rbx,%rdi,4)212 movaps -16(%rdx,%rdi,4), %xmm1213 mulps %xmm0, %xmm1214 movaps (%rdx,%rdi,4), %xmm2215 mulps %xmm0, %xmm2216 addps -16(%rbx,%rdi,4), %xmm1217 addps (%rbx,%rdi,4), %xmm2218 movaps %xmm1, -16(%rbx,%rdi,4)219 movaps %xmm2, (%rbx,%rdi,4)220 addq $16, %rdi221 cmpq $1548, %rdi # imm = 0x60C222 jne .LBB2_3223# %bb.4: # %polly.loop_exit22224 # in Loop: Header=BB2_2 Depth=2225 addq $1, %rsi226 addq $6144, %rdx # imm = 0x1800227 cmpq $1536, %rsi # imm = 0x600228 jne .LBB2_2229# %bb.5: # %polly.loop_exit16230 # in Loop: Header=BB2_1 Depth=1231 addq $1, %r14232 addq $6144, %rbx # imm = 0x1800233 cmpq $1536, %r14 # imm = 0x600234 jne .LBB2_1235# %bb.6: # %polly.exiting236 xorl %eax, %eax237 popq %rbx238 popq %r14239 popq %rbp240 .cfi_def_cfa %rsp, 8241 retq242.Lfunc_end2:243 .size main, .Lfunc_end2-main244 .cfi_endproc245 # -- End function246 .type A,@object # @A247 .comm A,9437184,16248 .type B,@object # @B249 .comm B,9437184,16250 .type .L.str,@object # @.str251 .section .rodata.str1.1,"aMS",@progbits,1252.L.str:253 .asciz "%lf "254 .size .L.str, 5255 256 .type C,@object # @C257 .comm C,9437184,16258 259 .ident "clang version 8.0.0 (trunk 342834) (llvm/trunk 342856)"260 .section ".note.GNU-stack","",@progbits261