void d_align_pmat(int row, int col, int offset, int bs_dummy, double *A,
                  int sda, double *B, int sdb) {
  const int bs = 4;
  int i, j;
  double *ptrA, *ptrB;
  int miss_align = offset % bs;
  i = 0;
  if (miss_align == 0) {
    for (; i < row - 3; i += 4) {
      ptrA = A + (i + offset) * sda;
      ptrB = B + i * sdb;
      j = 0;
      for (; j < col - 3; j += 4) {
        ptrB[0 + (j + 0) * bs] = ptrA[0 + (j + 0) * bs];
        ptrB[1 + (j + 0) * bs] = ptrA[1 + (j + 0) * bs];
        ptrB[2 + (j + 0) * bs] = ptrA[2 + (j + 0) * bs];
        ptrB[3 + (j + 0) * bs] = ptrA[3 + (j + 0) * bs];
        ptrB[0 + (j + 1) * bs] = ptrA[0 + (j + 1) * bs];
        ptrB[1 + (j + 1) * bs] = ptrA[1 + (j + 1) * bs];
        ptrB[2 + (j + 1) * bs] = ptrA[2 + (j + 1) * bs];
        ptrB[3 + (j + 1) * bs] = ptrA[3 + (j + 1) * bs];
        ptrB[0 + (j + 2) * bs] = ptrA[0 + (j + 2) * bs];
        ptrB[1 + (j + 2) * bs] = ptrA[1 + (j + 2) * bs];
        ptrB[2 + (j + 2) * bs] = ptrA[2 + (j + 2) * bs];
        ptrB[3 + (j + 2) * bs] = ptrA[3 + (j + 2) * bs];
        ptrB[0 + (j + 3) * bs] = ptrA[0 + (j + 3) * bs];
        ptrB[1 + (j + 3) * bs] = ptrA[1 + (j + 3) * bs];
        ptrB[2 + (j + 3) * bs] = ptrA[2 + (j + 3) * bs];
        ptrB[3 + (j + 3) * bs] = ptrA[3 + (j + 3) * bs];
      }
      for (; j < col; j++) {
        ptrB[0 + j * bs] = ptrA[0 + j * bs];
        ptrB[1 + j * bs] = ptrA[1 + j * bs];
        ptrB[2 + j * bs] = ptrA[2 + j * bs];
        ptrB[3 + j * bs] = ptrA[3 + j * bs];
      }
    }
  }
  for (; i < row; i++) {
    ptrA = A + ((offset + i) / bs) * bs * sda + ((offset + i) % bs);
    ptrB = B + (i / bs) * bs * sdb + (i % bs);
    j = 0;
    for (; j < col - 3; j += 4) {
      ptrB[(j + 0) * bs] = ptrA[(j + 0) * bs];
      ptrB[(j + 1) * bs] = ptrA[(j + 1) * bs];
      ptrB[(j + 2) * bs] = ptrA[(j + 2) * bs];
      ptrB[(j + 3) * bs] = ptrA[(j + 3) * bs];
    }
    for (; j < col; j++) {
      ptrB[j * bs] = ptrA[j * bs];
    }
  }
}


x86 assembly (clang, -O0):
<d_align_pmat>:
push   %rbp
mov    %rsp,%rbp
mov    0x18(%rbp),%eax
mov    0x10(%rbp),%rax
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %ecx,-0x10(%rbp)
mov    %r8,-0x18(%rbp)
mov    %r9d,-0x1c(%rbp)
movl   $0x4,-0x20(%rbp)
mov    -0xc(%rbp),%eax
mov    $0x4,%ecx
cltd
idiv   %ecx
mov    %edx,-0x3c(%rbp)
movl   $0x0,-0x24(%rbp)
cmpl   $0x0,-0x3c(%rbp)
jne    1595 <d_align_pmat+0x495>
jmp    114a <d_align_pmat+0x4a>
mov    -0x24(%rbp),%eax
mov    -0x4(%rbp),%ecx
sub    $0x3,%ecx
cmp    %ecx,%eax
jge    1590 <d_align_pmat+0x490>
mov    -0x18(%rbp),%rax
mov    -0x24(%rbp),%ecx
add    -0xc(%rbp),%ecx
imul   -0x1c(%rbp),%ecx
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x30(%rbp)
mov    0x10(%rbp),%rax
mov    -0x24(%rbp),%ecx
imul   0x18(%rbp),%ecx
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x38(%rbp)
movl   $0x0,-0x28(%rbp)
mov    -0x28(%rbp),%eax
mov    -0x8(%rbp),%ecx
sub    $0x3,%ecx
cmp    %ecx,%eax
jge    14b6 <d_align_pmat+0x3b6>
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x0,%ecx
shl    $0x2,%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x0,%ecx
shl    $0x2,%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x0,%ecx
shl    $0x2,%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x0,%ecx
shl    $0x2,%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x0,%ecx
shl    $0x2,%ecx
add    $0x2,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x0,%ecx
shl    $0x2,%ecx
add    $0x2,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x0,%ecx
shl    $0x2,%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x0,%ecx
shl    $0x2,%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x1,%ecx
shl    $0x2,%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x1,%ecx
shl    $0x2,%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x1,%ecx
shl    $0x2,%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x1,%ecx
shl    $0x2,%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x1,%ecx
shl    $0x2,%ecx
add    $0x2,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x1,%ecx
shl    $0x2,%ecx
add    $0x2,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x1,%ecx
shl    $0x2,%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x1,%ecx
shl    $0x2,%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x2,%ecx
shl    $0x2,%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x2,%ecx
shl    $0x2,%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x2,%ecx
shl    $0x2,%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x2,%ecx
shl    $0x2,%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x2,%ecx
shl    $0x2,%ecx
add    $0x2,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x2,%ecx
shl    $0x2,%ecx
add    $0x2,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x2,%ecx
shl    $0x2,%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x2,%ecx
shl    $0x2,%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x3,%ecx
shl    $0x2,%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x3,%ecx
shl    $0x2,%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x3,%ecx
shl    $0x2,%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x3,%ecx
shl    $0x2,%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x3,%ecx
shl    $0x2,%ecx
add    $0x2,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x3,%ecx
shl    $0x2,%ecx
add    $0x2,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x3,%ecx
shl    $0x2,%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x3,%ecx
shl    $0x2,%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x28(%rbp),%eax
add    $0x4,%eax
mov    %eax,-0x28(%rbp)
jmp    1197 <d_align_pmat+0x97>
jmp    14bb <d_align_pmat+0x3bb>
mov    -0x28(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    157d <d_align_pmat+0x47d>
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
shl    $0x2,%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
shl    $0x2,%ecx
add    $0x0,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
shl    $0x2,%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
shl    $0x2,%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
shl    $0x2,%ecx
add    $0x2,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
shl    $0x2,%ecx
add    $0x2,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
shl    $0x2,%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
shl    $0x2,%ecx
add    $0x3,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x28(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x28(%rbp)
jmp    14bb <d_align_pmat+0x3bb>
jmp    1582 <d_align_pmat+0x482>
mov    -0x24(%rbp),%eax
add    $0x4,%eax
mov    %eax,-0x24(%rbp)
jmp    114a <d_align_pmat+0x4a>
jmp    1595 <d_align_pmat+0x495>
jmp    159a <d_align_pmat+0x49a>
mov    -0x24(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    1766 <d_align_pmat+0x666>
mov    -0x18(%rbp),%rax
mov    %rax,-0x60(%rbp)
mov    -0xc(%rbp),%eax
add    -0x24(%rbp),%eax
mov    $0x4,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x60(%rbp),%rax
shl    $0x2,%ecx
imul   -0x1c(%rbp),%ecx
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x58(%rbp)
mov    -0xc(%rbp),%eax
add    -0x24(%rbp),%eax
mov    $0x4,%ecx
cltd
idiv   %ecx
mov    -0x58(%rbp),%rax
movslq %edx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x30(%rbp)
mov    0x10(%rbp),%rax
mov    %rax,-0x50(%rbp)
mov    -0x24(%rbp),%eax
mov    $0x4,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x50(%rbp),%rax
shl    $0x2,%ecx
imul   0x18(%rbp),%ecx
movslq %ecx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x48(%rbp)
mov    -0x24(%rbp),%eax
mov    $0x4,%ecx
cltd
idiv   %ecx
mov    -0x48(%rbp),%rax
movslq %edx,%rcx
shl    $0x3,%rcx
add    %rcx,%rax
mov    %rax,-0x38(%rbp)
movl   $0x0,-0x28(%rbp)
mov    -0x28(%rbp),%eax
mov    -0x8(%rbp),%ecx
sub    $0x3,%ecx
cmp    %ecx,%eax
jge    1710 <d_align_pmat+0x610>
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x0,%ecx
shl    $0x2,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x0,%ecx
shl    $0x2,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x1,%ecx
shl    $0x2,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x1,%ecx
shl    $0x2,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x2,%ecx
shl    $0x2,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x2,%ecx
shl    $0x2,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x3,%ecx
shl    $0x2,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
add    $0x3,%ecx
shl    $0x2,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x28(%rbp),%eax
add    $0x4,%eax
mov    %eax,-0x28(%rbp)
jmp    1649 <d_align_pmat+0x549>
jmp    1715 <d_align_pmat+0x615>
mov    -0x28(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1753 <d_align_pmat+0x653>
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%ecx
shl    $0x2,%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    -0x38(%rbp),%rax
mov    -0x28(%rbp),%ecx
shl    $0x2,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x28(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x28(%rbp)
jmp    1715 <d_align_pmat+0x615>
jmp    1758 <d_align_pmat+0x658>
mov    -0x24(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x24(%rbp)
jmp    159a <d_align_pmat+0x49a>
pop    %rbp
ret

x86 assembly (clang, -O2):
<d_align_pmat>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
mov    %r8,-0x30(%rsp)
mov    %edi,%ebx
xor    %r8d,%r8d
mov    %esi,%eax
mov    %rax,-0x38(%rsp)
test   $0x3,%dl
mov    %rbx,-0x20(%rsp)
jne    133f <d_align_pmat+0x23f>
cmp    $0x4,%ebx
jl     133f <d_align_pmat+0x23f>
lea    -0x3(%rbx),%r11d
lea    -0x3(%rsi),%eax
movslq %eax,%rbp
movslq %edx,%rdi
mov    %r9d,-0x24(%rsp)
movslq %r9d,%r15
mov    0x40(%rsp),%eax
movslq %eax,%r9
mov    %r9,-0x18(%rsp)
shl    $0x5,%r9
mov    %r15,%rcx
mov    %rdi,%rax
mov    %rdi,-0x8(%rsp)
imul   %rdi,%rcx
mov    -0x30(%rsp),%rdi
lea    (%rdi,%rcx,8),%r10
mov    %r15,-0x10(%rsp)
shl    $0x5,%r15
xor    %r8d,%r8d
mov    0x38(%rsp),%r14
jmp    11a3 <d_align_pmat+0xa3>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
add    $0x4,%r8
add    %r9,%r14
add    %r15,%r10
cmp    %r11,%r8
jae    1335 <d_align_pmat+0x235>
mov    $0x0,%ecx
cmp    $0x4,%esi
jl     12af <d_align_pmat+0x1af>
mov    $0x78,%edi
xor    %ecx,%ecx
nopl   0x0(%rax,%rax,1)
movsd  -0x78(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x78(%r14,%rdi,1)
movsd  -0x70(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x70(%r14,%rdi,1)
movsd  -0x68(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x68(%r14,%rdi,1)
movsd  -0x60(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x60(%r14,%rdi,1)
movsd  -0x58(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x58(%r14,%rdi,1)
movsd  -0x50(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x50(%r14,%rdi,1)
movsd  -0x48(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x48(%r14,%rdi,1)
movsd  -0x40(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x40(%r14,%rdi,1)
movsd  -0x38(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x38(%r14,%rdi,1)
movsd  -0x30(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x30(%r14,%rdi,1)
movsd  -0x28(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x28(%r14,%rdi,1)
movsd  -0x20(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x20(%r14,%rdi,1)
movsd  -0x18(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x18(%r14,%rdi,1)
movsd  -0x10(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x10(%r14,%rdi,1)
movsd  -0x8(%r10,%rdi,1),%xmm0
movsd  %xmm0,-0x8(%r14,%rdi,1)
movsd  (%r10,%rdi,1),%xmm0
movsd  %xmm0,(%r14,%rdi,1)
add    $0x4,%rcx
sub    $0xffffffffffffff80,%rdi
cmp    %rbp,%rcx
jl     11c0 <d_align_pmat+0xc0>
cmp    %esi,%ecx
jge    1190 <d_align_pmat+0x90>
mov    -0x8(%rsp),%rax
lea    (%r8,%rax,1),%rdi
imul   -0x10(%rsp),%rdi
mov    %r8,%rbx
imul   -0x18(%rsp),%rbx
mov    -0x30(%rsp),%rax
lea    (%rax,%rdi,8),%rdi
mov    0x38(%rsp),%rax
lea    (%rax,%rbx,8),%r12
mov    %ecx,%ebx
mov    -0x38(%rsp),%r13
sub    %rbx,%r13
shl    $0x2,%ecx
xchg   %ax,%ax
mov    %ecx,%ebx
movsd  (%rdi,%rbx,8),%xmm0
movsd  %xmm0,(%r12,%rbx,8)
lea    0x1(%rcx),%ebx
movsd  (%rdi,%rbx,8),%xmm0
movsd  %xmm0,(%r12,%rbx,8)
lea    0x2(%rcx),%ebx
movsd  (%rdi,%rbx,8),%xmm0
movsd  %xmm0,(%r12,%rbx,8)
lea    0x3(%rcx),%ebx
movsd  (%rdi,%rbx,8),%xmm0
movsd  %xmm0,(%r12,%rbx,8)
add    $0x4,%ecx
add    $0xffffffffffffffff,%r13
jne    12f0 <d_align_pmat+0x1f0>
jmp    1190 <d_align_pmat+0x90>
mov    -0x24(%rsp),%r9d
mov    -0x20(%rsp),%rbx
cmp    %ebx,%r8d
jge    150a <d_align_pmat+0x40a>
shl    $0x2,%r9d
lea    -0x3(%rsi),%eax
movslq %eax,%r10
mov    0x40(%rsp),%eax
lea    0x0(,%rax,4),%r14d
jmp    136d <d_align_pmat+0x26d>
add    $0x1,%r8d
cmp    %ebx,%r8d
je     150a <d_align_pmat+0x40a>
mov    %r8d,%eax
add    %edx,%eax
lea    0x3(%r8,%rdx,1),%ecx
cmovns %eax,%ecx
mov    %ecx,%edi
sar    $0x2,%edi
imul   %r9d,%edi
and    $0xfffffffc,%ecx
sub    %ecx,%eax
movslq %edi,%rcx
mov    -0x30(%rsp),%rdi
lea    (%rdi,%rcx,8),%rcx
cltq
lea    (%rcx,%rax,8),%rbp
mov    $0x0,%edi
cmp    $0x4,%esi
jl     140c <d_align_pmat+0x30c>
mov    %r8d,%eax
shr    $0x2,%eax
and    $0x1fffffff,%eax
imul   %r14d,%eax
cltq
mov    %r8d,%ecx
and    $0x3,%ecx
add    %rax,%rcx
mov    0x38(%rsp),%rax
lea    (%rax,%rcx,8),%rax
mov    $0x60,%ecx
xor    %edi,%edi
xchg   %ax,%ax
movsd  -0x60(%rbp,%rcx,1),%xmm0
movsd  %xmm0,-0x60(%rax,%rcx,1)
movsd  -0x40(%rbp,%rcx,1),%xmm0
movsd  %xmm0,-0x40(%rax,%rcx,1)
movsd  -0x20(%rbp,%rcx,1),%xmm0
movsd  %xmm0,-0x20(%rax,%rcx,1)
movsd  0x0(%rbp,%rcx,1),%xmm0
movsd  %xmm0,(%rax,%rcx,1)
add    $0x4,%rdi
sub    $0xffffffffffffff80,%rcx
cmp    %r10,%rdi
jl     13d0 <d_align_pmat+0x2d0>
cmp    %esi,%edi
jge    1360 <d_align_pmat+0x260>
mov    %r8d,%eax
and    $0x7ffffffc,%eax
mov    0x40(%rsp),%ecx
imul   %ecx,%eax
mov    %r8d,%ecx
and    $0x3,%ecx
cltq
mov    0x38(%rsp),%rbx
lea    (%rbx,%rax,8),%rax
lea    (%rax,%rcx,8),%r11
mov    %edi,%ecx
mov    -0x38(%rsp),%rax
mov    %eax,%r12d
sub    %edi,%r12d
mov    %rcx,%r15
not    %r15
add    %rax,%r15
and    $0x3,%r12
je     1495 <d_align_pmat+0x395>
lea    0x0(,%rcx,4),%rax
neg    %r12
xor    %ebx,%ebx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    %eax,%edi
and    $0xfffffffc,%edi
shl    $0x3,%rdi
movsd  0x0(%rbp,%rdi,1),%xmm0
movsd  %xmm0,(%r11,%rdi,1)
add    $0xffffffffffffffff,%rbx
add    $0x4,%rax
cmp    %rbx,%r12
jne    1470 <d_align_pmat+0x370>
sub    %rbx,%rcx
cmp    $0x3,%r15
mov    -0x20(%rsp),%rbx
jb     1360 <d_align_pmat+0x260>
mov    -0x38(%rsp),%rdi
sub    %rcx,%rdi
shl    $0x2,%rcx
mov    %ecx,%eax
and    $0xfffffffc,%eax
shl    $0x3,%rax
movsd  0x0(%rbp,%rax,1),%xmm0
movsd  %xmm0,(%r11,%rax,1)
lea    0x4(%rcx),%eax
and    $0xfffffffc,%eax
movsd  0x0(%rbp,%rax,8),%xmm0
movsd  %xmm0,(%r11,%rax,8)
lea    0x8(%rcx),%eax
and    $0xfffffffc,%eax
movsd  0x0(%rbp,%rax,8),%xmm0
movsd  %xmm0,(%r11,%rax,8)
lea    0xc(%rcx),%eax
and    $0xfffffffc,%eax
movsd  0x0(%rbp,%rax,8),%xmm0
movsd  %xmm0,(%r11,%rax,8)
add    $0x10,%rcx
add    $0xfffffffffffffffc,%rdi
jne    14b0 <d_align_pmat+0x3b0>
jmp    1360 <d_align_pmat+0x260>
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define void @d_align_pmat(i32 %0, i32 %1, i32 %2, i32 %3, double* %4, i32 %5, double* %6, i32 %7) {
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%12 = alloca i32
%13 = alloca double*
%14 = alloca i32
%15 = alloca double*
%16 = alloca i32
%17 = alloca i32
%18 = alloca i32
%19 = alloca i32
%20 = alloca double*
%21 = alloca double*
%22 = alloca i32
store i32 %0, i32* %9
store i32 %1, i32* %10
store i32 %2, i32* %11
store i32 %3, i32* %12
store double* %4, double** %13
store i32 %5, i32* %14
store double* %6, double** %15
store i32 %7, i32* %16
store i32 4, i32* %17
%23 = load i32, i32* %11
%24 = srem i32 %23, 4
store i32 %24, i32* %22
store i32 0, i32* %18
%25 = load i32, i32* %22
%26 = icmp eq i32 %25, 0
br i1 %26, label %27, label %363
27: ; preds = %8
br label %28
28: ; preds = %359, %27
%29 = load i32, i32* %18
%30 = load i32, i32* %9
%31 = sub nsw i32 %30, 3
%32 = icmp slt i32 %29, %31
br i1 %32, label %33, label %362
33: ; preds = %28
%34 = load double*, double** %13
%35 = load i32, i32* %18
%36 = load i32, i32* %11
%37 = add nsw i32 %35, %36
%38 = load i32, i32* %14
%39 = mul nsw i32 %37, %38
%40 = sext i32 %39 to i64
%41 = getelementptr inbounds double, double* %34, i64 %40
store double* %41, double** %20
%42 = load double*, double** %15
%43 = load i32, i32* %18
%44 = load i32, i32* %16
%45 = mul nsw i32 %43, %44
%46 = sext i32 %45 to i64
%47 = getelementptr inbounds double, double* %42, i64 %46
store double* %47, double** %21
store i32 0, i32* %19
br label %48
48: ; preds = %294, %33
%49 = load i32, i32* %19
%50 = load i32, i32* %10
%51 = sub nsw i32 %50, 3
%52 = icmp slt i32 %49, %51
br i1 %52, label %53, label %297
53: ; preds = %48
%54 = load double*, double** %20
%55 = load i32, i32* %19
%56 = add nsw i32 %55, 0
%57 = mul nsw i32 %56, 4
%58 = add nsw i32 0, %57
%59 = sext i32 %58 to i64
%60 = getelementptr inbounds double, double* %54, i64 %59
%61 = load double, double* %60
%62 = load double*, double** %21
%63 = load i32, i32* %19
%64 = add nsw i32 %63, 0
%65 = mul nsw i32 %64, 4
%66 = add nsw i32 0, %65
%67 = sext i32 %66 to i64
%68 = getelementptr inbounds double, double* %62, i64 %67
store double %61, double* %68
%69 = load double*, double** %20
%70 = load i32, i32* %19
%71 = add nsw i32 %70, 0
%72 = mul nsw i32 %71, 4
%73 = add nsw i32 1, %72
%74 = sext i32 %73 to i64
%75 = getelementptr inbounds double, double* %69, i64 %74
%76 = load double, double* %75
%77 = load double*, double** %21
%78 = load i32, i32* %19
%79 = add nsw i32 %78, 0
%80 = mul nsw i32 %79, 4
%81 = add nsw i32 1, %80
%82 = sext i32 %81 to i64
%83 = getelementptr inbounds double, double* %77, i64 %82
store double %76, double* %83
%84 = load double*, double** %20
%85 = load i32, i32* %19
%86 = add nsw i32 %85, 0
%87 = mul nsw i32 %86, 4
%88 = add nsw i32 2, %87
%89 = sext i32 %88 to i64
%90 = getelementptr inbounds double, double* %84, i64 %89
%91 = load double, double* %90
%92 = load double*, double** %21
%93 = load i32, i32* %19
%94 = add nsw i32 %93, 0
%95 = mul nsw i32 %94, 4
%96 = add nsw i32 2, %95
%97 = sext i32 %96 to i64
%98 = getelementptr inbounds double, double* %92, i64 %97
store double %91, double* %98
%99 = load double*, double** %20
%100 = load i32, i32* %19
%101 = add nsw i32 %100, 0
%102 = mul nsw i32 %101, 4
%103 = add nsw i32 3, %102
%104 = sext i32 %103 to i64
%105 = getelementptr inbounds double, double* %99, i64 %104
%106 = load double, double* %105
%107 = load double*, double** %21
%108 = load i32, i32* %19
%109 = add nsw i32 %108, 0
%110 = mul nsw i32 %109, 4
%111 = add nsw i32 3, %110
%112 = sext i32 %111 to i64
%113 = getelementptr inbounds double, double* %107, i64 %112
store double %106, double* %113
%114 = load double*, double** %20
%115 = load i32, i32* %19
%116 = add nsw i32 %115, 1
%117 = mul nsw i32 %116, 4
%118 = add nsw i32 0, %117
%119 = sext i32 %118 to i64
%120 = getelementptr inbounds double, double* %114, i64 %119
%121 = load double, double* %120
%122 = load double*, double** %21
%123 = load i32, i32* %19
%124 = add nsw i32 %123, 1
%125 = mul nsw i32 %124, 4
%126 = add nsw i32 0, %125
%127 = sext i32 %126 to i64
%128 = getelementptr inbounds double, double* %122, i64 %127
store double %121, double* %128
%129 = load double*, double** %20
%130 = load i32, i32* %19
%131 = add nsw i32 %130, 1
%132 = mul nsw i32 %131, 4
%133 = add nsw i32 1, %132
%134 = sext i32 %133 to i64
%135 = getelementptr inbounds double, double* %129, i64 %134
%136 = load double, double* %135
%137 = load double*, double** %21
%138 = load i32, i32* %19
%139 = add nsw i32 %138, 1
%140 = mul nsw i32 %139, 4
%141 = add nsw i32 1, %140
%142 = sext i32 %141 to i64
%143 = getelementptr inbounds double, double* %137, i64 %142
store double %136, double* %143
%144 = load double*, double** %20
%145 = load i32, i32* %19
%146 = add nsw i32 %145, 1
%147 = mul nsw i32 %146, 4
%148 = add nsw i32 2, %147
%149 = sext i32 %148 to i64
%150 = getelementptr inbounds double, double* %144, i64 %149
%151 = load double, double* %150
%152 = load double*, double** %21
%153 = load i32, i32* %19
%154 = add nsw i32 %153, 1
%155 = mul nsw i32 %154, 4
%156 = add nsw i32 2, %155
%157 = sext i32 %156 to i64
%158 = getelementptr inbounds double, double* %152, i64 %157
store double %151, double* %158
%159 = load double*, double** %20
%160 = load i32, i32* %19
%161 = add nsw i32 %160, 1
%162 = mul nsw i32 %161, 4
%163 = add nsw i32 3, %162
%164 = sext i32 %163 to i64
%165 = getelementptr inbounds double, double* %159, i64 %164
%166 = load double, double* %165
%167 = load double*, double** %21
%168 = load i32, i32* %19
%169 = add nsw i32 %168, 1
%170 = mul nsw i32 %169, 4
%171 = add nsw i32 3, %170
%172 = sext i32 %171 to i64
%173 = getelementptr inbounds double, double* %167, i64 %172
store double %166, double* %173
%174 = load double*, double** %20
%175 = load i32, i32* %19
%176 = add nsw i32 %175, 2
%177 = mul nsw i32 %176, 4
%178 = add nsw i32 0, %177
%179 = sext i32 %178 to i64
%180 = getelementptr inbounds double, double* %174, i64 %179
%181 = load double, double* %180
%182 = load double*, double** %21
%183 = load i32, i32* %19
%184 = add nsw i32 %183, 2
%185 = mul nsw i32 %184, 4
%186 = add nsw i32 0, %185
%187 = sext i32 %186 to i64
%188 = getelementptr inbounds double, double* %182, i64 %187
store double %181, double* %188
%189 = load double*, double** %20
%190 = load i32, i32* %19
%191 = add nsw i32 %190, 2
%192 = mul nsw i32 %191, 4
%193 = add nsw i32 1, %192
%194 = sext i32 %193 to i64
%195 = getelementptr inbounds double, double* %189, i64 %194
%196 = load double, double* %195
%197 = load double*, double** %21
%198 = load i32, i32* %19
%199 = add nsw i32 %198, 2
%200 = mul nsw i32 %199, 4
%201 = add nsw i32 1, %200
%202 = sext i32 %201 to i64
%203 = getelementptr inbounds double, double* %197, i64 %202
store double %196, double* %203
%204 = load double*, double** %20
%205 = load i32, i32* %19
%206 = add nsw i32 %205, 2
%207 = mul nsw i32 %206, 4
%208 = add nsw i32 2, %207
%209 = sext i32 %208 to i64
%210 = getelementptr inbounds double, double* %204, i64 %209
%211 = load double, double* %210
%212 = load double*, double** %21
%213 = load i32, i32* %19
%214 = add nsw i32 %213, 2
%215 = mul nsw i32 %214, 4
%216 = add nsw i32 2, %215
%217 = sext i32 %216 to i64
%218 = getelementptr inbounds double, double* %212, i64 %217
store double %211, double* %218
%219 = load double*, double** %20
%220 = load i32, i32* %19
%221 = add nsw i32 %220, 2
%222 = mul nsw i32 %221, 4
%223 = add nsw i32 3, %222
%224 = sext i32 %223 to i64
%225 = getelementptr inbounds double, double* %219, i64 %224
%226 = load double, double* %225
%227 = load double*, double** %21
%228 = load i32, i32* %19
%229 = add nsw i32 %228, 2
%230 = mul nsw i32 %229, 4
%231 = add nsw i32 3, %230
%232 = sext i32 %231 to i64
%233 = getelementptr inbounds double, double* %227, i64 %232
store double %226, double* %233
%234 = load double*, double** %20
%235 = load i32, i32* %19
%236 = add nsw i32 %235, 3
%237 = mul nsw i32 %236, 4
%238 = add nsw i32 0, %237
%239 = sext i32 %238 to i64
%240 = getelementptr inbounds double, double* %234, i64 %239
%241 = load double, double* %240
%242 = load double*, double** %21
%243 = load i32, i32* %19
%244 = add nsw i32 %243, 3
%245 = mul nsw i32 %244, 4
%246 = add nsw i32 0, %245
%247 = sext i32 %246 to i64
%248 = getelementptr inbounds double, double* %242, i64 %247
store double %241, double* %248
%249 = load double*, double** %20
%250 = load i32, i32* %19
%251 = add nsw i32 %250, 3
%252 = mul nsw i32 %251, 4
%253 = add nsw i32 1, %252
%254 = sext i32 %253 to i64
%255 = getelementptr inbounds double, double* %249, i64 %254
%256 = load double, double* %255
%257 = load double*, double** %21
%258 = load i32, i32* %19
%259 = add nsw i32 %258, 3
%260 = mul nsw i32 %259, 4
%261 = add nsw i32 1, %260
%262 = sext i32 %261 to i64
%263 = getelementptr inbounds double, double* %257, i64 %262
store double %256, double* %263
%264 = load double*, double** %20
%265 = load i32, i32* %19
%266 = add nsw i32 %265, 3
%267 = mul nsw i32 %266, 4
%268 = add nsw i32 2, %267
%269 = sext i32 %268 to i64
%270 = getelementptr inbounds double, double* %264, i64 %269
%271 = load double, double* %270
%272 = load double*, double** %21
%273 = load i32, i32* %19
%274 = add nsw i32 %273, 3
%275 = mul nsw i32 %274, 4
%276 = add nsw i32 2, %275
%277 = sext i32 %276 to i64
%278 = getelementptr inbounds double, double* %272, i64 %277
store double %271, double* %278
%279 = load double*, double** %20
%280 = load i32, i32* %19
%281 = add nsw i32 %280, 3
%282 = mul nsw i32 %281, 4
%283 = add nsw i32 3, %282
%284 = sext i32 %283 to i64
%285 = getelementptr inbounds double, double* %279, i64 %284
%286 = load double, double* %285
%287 = load double*, double** %21
%288 = load i32, i32* %19
%289 = add nsw i32 %288, 3
%290 = mul nsw i32 %289, 4
%291 = add nsw i32 3, %290
%292 = sext i32 %291 to i64
%293 = getelementptr inbounds double, double* %287, i64 %292
store double %286, double* %293
br label %294
294: ; preds = %53
%295 = load i32, i32* %19
%296 = add nsw i32 %295, 4
store i32 %296, i32* %19
br label %48
297: ; preds = %48
br label %298
298: ; preds = %355, %297
%299 = load i32, i32* %19
%300 = load i32, i32* %10
%301 = icmp slt i32 %299, %300
br i1 %301, label %302, label %358
302: ; preds = %298
%303 = load double*, double** %20
%304 = load i32, i32* %19
%305 = mul nsw i32 %304, 4
%306 = add nsw i32 0, %305
%307 = sext i32 %306 to i64
%308 = getelementptr inbounds double, double* %303, i64 %307
%309 = load double, double* %308
%310 = load double*, double** %21
%311 = load i32, i32* %19
%312 = mul nsw i32 %311, 4
%313 = add nsw i32 0, %312
%314 = sext i32 %313 to i64
%315 = getelementptr inbounds double, double* %310, i64 %314
store double %309, double* %315
%316 = load double*, double** %20
%317 = load i32, i32* %19
%318 = mul nsw i32 %317, 4
%319 = add nsw i32 1, %318
%320 = sext i32 %319 to i64
%321 = getelementptr inbounds double, double* %316, i64 %320
%322 = load double, double* %321
%323 = load double*, double** %21
%324 = load i32, i32* %19
%325 = mul nsw i32 %324, 4
%326 = add nsw i32 1, %325
%327 = sext i32 %326 to i64
%328 = getelementptr inbounds double, double* %323, i64 %327
store double %322, double* %328
%329 = load double*, double** %20
%330 = load i32, i32* %19
%331 = mul nsw i32 %330, 4
%332 = add nsw i32 2, %331
%333 = sext i32 %332 to i64
%334 = getelementptr inbounds double, double* %329, i64 %333
%335 = load double, double* %334
%336 = load double*, double** %21
%337 = load i32, i32* %19
%338 = mul nsw i32 %337, 4
%339 = add nsw i32 2, %338
%340 = sext i32 %339 to i64
%341 = getelementptr inbounds double, double* %336, i64 %340
store double %335, double* %341
%342 = load double*, double** %20
%343 = load i32, i32* %19
%344 = mul nsw i32 %343, 4
%345 = add nsw i32 3, %344
%346 = sext i32 %345 to i64
%347 = getelementptr inbounds double, double* %342, i64 %346
%348 = load double, double* %347
%349 = load double*, double** %21
%350 = load i32, i32* %19
%351 = mul nsw i32 %350, 4
%352 = add nsw i32 3, %351
%353 = sext i32 %352 to i64
%354 = getelementptr inbounds double, double* %349, i64 %353
store double %348, double* %354
br label %355
355: ; preds = %302
%356 = load i32, i32* %19
%357 = add nsw i32 %356, 1
store i32 %357, i32* %19
br label %298
358: ; preds = %298
br label %359
359: ; preds = %358
%360 = load i32, i32* %18
%361 = add nsw i32 %360, 4
store i32 %361, i32* %18
br label %28
362: ; preds = %28
br label %363
363: ; preds = %362, %8
br label %364
364: ; preds = %479, %363
%365 = load i32, i32* %18
%366 = load i32, i32* %9
%367 = icmp slt i32 %365, %366
br i1 %367, label %368, label %482
368: ; preds = %364
%369 = load double*, double** %13
%370 = load i32, i32* %11
%371 = load i32, i32* %18
%372 = add nsw i32 %370, %371
%373 = sdiv i32 %372, 4
%374 = mul nsw i32 %373, 4
%375 = load i32, i32* %14
%376 = mul nsw i32 %374, %375
%377 = sext i32 %376 to i64
%378 = getelementptr inbounds double, double* %369, i64 %377
%379 = load i32, i32* %11
%380 = load i32, i32* %18
%381 = add nsw i32 %379, %380
%382 = srem i32 %381, 4
%383 = sext i32 %382 to i64
%384 = getelementptr inbounds double, double* %378, i64 %383
store double* %384, double** %20
%385 = load double*, double** %15
%386 = load i32, i32* %18
%387 = sdiv i32 %386, 4
%388 = mul nsw i32 %387, 4
%389 = load i32, i32* %16
%390 = mul nsw i32 %388, %389
%391 = sext i32 %390 to i64
%392 = getelementptr inbounds double, double* %385, i64 %391
%393 = load i32, i32* %18
%394 = srem i32 %393, 4
%395 = sext i32 %394 to i64
%396 = getelementptr inbounds double, double* %392, i64 %395
store double* %396, double** %21
store i32 0, i32* %19
br label %397
397: ; preds = %455, %368
%398 = load i32, i32* %19
%399 = load i32, i32* %10
%400 = sub nsw i32 %399, 3
%401 = icmp slt i32 %398, %400
br i1 %401, label %402, label %458
402: ; preds = %397
%403 = load double*, double** %20
%404 = load i32, i32* %19
%405 = add nsw i32 %404, 0
%406 = mul nsw i32 %405, 4
%407 = sext i32 %406 to i64
%408 = getelementptr inbounds double, double* %403, i64 %407
%409 = load double, double* %408
%410 = load double*, double** %21
%411 = load i32, i32* %19
%412 = add nsw i32 %411, 0
%413 = mul nsw i32 %412, 4
%414 = sext i32 %413 to i64
%415 = getelementptr inbounds double, double* %410, i64 %414
store double %409, double* %415
%416 = load double*, double** %20
%417 = load i32, i32* %19
%418 = add nsw i32 %417, 1
%419 = mul nsw i32 %418, 4
%420 = sext i32 %419 to i64
%421 = getelementptr inbounds double, double* %416, i64 %420
%422 = load double, double* %421
%423 = load double*, double** %21
%424 = load i32, i32* %19
%425 = add nsw i32 %424, 1
%426 = mul nsw i32 %425, 4
%427 = sext i32 %426 to i64
%428 = getelementptr inbounds double, double* %423, i64 %427
store double %422, double* %428
%429 = load double*, double** %20
%430 = load i32, i32* %19
%431 = add nsw i32 %430, 2
%432 = mul nsw i32 %431, 4
%433 = sext i32 %432 to i64
%434 = getelementptr inbounds double, double* %429, i64 %433
%435 = load double, double* %434
%436 = load double*, double** %21
%437 = load i32, i32* %19
%438 = add nsw i32 %437, 2
%439 = mul nsw i32 %438, 4
%440 = sext i32 %439 to i64
%441 = getelementptr inbounds double, double* %436, i64 %440
store double %435, double* %441
%442 = load double*, double** %20
%443 = load i32, i32* %19
%444 = add nsw i32 %443, 3
%445 = mul nsw i32 %444, 4
%446 = sext i32 %445 to i64
%447 = getelementptr inbounds double, double* %442, i64 %446
%448 = load double, double* %447
%449 = load double*, double** %21
%450 = load i32, i32* %19
%451 = add nsw i32 %450, 3
%452 = mul nsw i32 %451, 4
%453 = sext i32 %452 to i64
%454 = getelementptr inbounds double, double* %449, i64 %453
store double %448, double* %454
br label %455
455: ; preds = %402
%456 = load i32, i32* %19
%457 = add nsw i32 %456, 4
store i32 %457, i32* %19
br label %397
458: ; preds = %397
br label %459
459: ; preds = %475, %458
%460 = load i32, i32* %19
%461 = load i32, i32* %10
%462 = icmp slt i32 %460, %461
br i1 %462, label %463, label %478
463: ; preds = %459
%464 = load double*, double** %20
%465 = load i32, i32* %19
%466 = mul nsw i32 %465, 4
%467 = sext i32 %466 to i64
%468 = getelementptr inbounds double, double* %464, i64 %467
%469 = load double, double* %468
%470 = load double*, double** %21
%471 = load i32, i32* %19
%472 = mul nsw i32 %471, 4
%473 = sext i32 %472 to i64
%474 = getelementptr inbounds double, double* %470, i64 %473
store double %469, double* %474
br label %475
475: ; preds = %463
%476 = load i32, i32* %19
%477 = add nsw i32 %476, 1
store i32 %477, i32* %19
br label %459
478: ; preds = %459
br label %479
479: ; preds = %478
%480 = load i32, i32* %18
%481 = add nsw i32 %480, 1
store i32 %481, i32* %18
br label %364
482: ; preds = %364
ret void
}

LLVM IR (-O2):
define void @d_align_pmat(i32 %0, i32 %1, i32 %2, i32 %3, double* nocapture %4, i32 %5, double* nocapture writeonly %6, i32 %7) {
%9 = and i32 %2, 3
%10 = icmp eq i32 %9, 0
%11 = icmp sgt i32 %0, 3
%12 = and i1 %10, %11
br i1 %12, label %13, label %135
13: ; preds = %8
%14 = add nsw i32 %0, -3
%15 = add nsw i32 %1, -3
%16 = icmp sgt i32 %1, 3
%17 = sext i32 %15 to i64
%18 = sext i32 %2 to i64
%19 = sext i32 %5 to i64
%20 = sext i32 %7 to i64
%21 = zext i32 %14 to i64
%22 = zext i32 %1 to i64
br label %23
23: ; preds = %13, %130
%24 = phi i64 [ 0, %13 ], [ %131, %130 ]
%25 = add nsw i64 %24, %18
%26 = mul nsw i64 %25, %19
%27 = getelementptr inbounds double, double* %4, i64 %26
%28 = mul nsw i64 %24, %20
%29 = getelementptr inbounds double, double* %6, i64 %28
br i1 %16, label %37, label %32
30: ; preds = %37
%31 = trunc i64 %103 to i32
br label %32
32: ; preds = %30, %23
%33 = phi i32 [ 0, %23 ], [ %31, %30 ]
%34 = icmp slt i32 %33, %1
br i1 %34, label %35, label %130
35: ; preds = %32
%36 = zext i32 %33 to i64
br label %105
37: ; preds = %23, %37
%38 = phi i64 [ %103, %37 ], [ 0, %23 ]
%39 = shl nsw i64 %38, 2
%40 = getelementptr inbounds double, double* %27, i64 %39
%41 = load double, double* %40
%42 = getelementptr inbounds double, double* %29, i64 %39
store double %41, double* %42
%43 = or i64 %39, 1
%44 = getelementptr inbounds double, double* %27, i64 %43
%45 = load double, double* %44
%46 = getelementptr inbounds double, double* %29, i64 %43
store double %45, double* %46
%47 = or i64 %39, 2
%48 = getelementptr inbounds double, double* %27, i64 %47
%49 = load double, double* %48
%50 = getelementptr inbounds double, double* %29, i64 %47
store double %49, double* %50
%51 = or i64 %39, 3
%52 = getelementptr inbounds double, double* %27, i64 %51
%53 = load double, double* %52
%54 = getelementptr inbounds double, double* %29, i64 %51
store double %53, double* %54
%55 = or i64 %39, 4
%56 = getelementptr inbounds double, double* %27, i64 %55
%57 = load double, double* %56
%58 = getelementptr inbounds double, double* %29, i64 %55
store double %57, double* %58
%59 = or i64 %39, 5
%60 = getelementptr inbounds double, double* %27, i64 %59
%61 = load double, double* %60
%62 = getelementptr inbounds double, double* %29, i64 %59
store double %61, double* %62
%63 = or i64 %39, 6
%64 = getelementptr inbounds double, double* %27, i64 %63
%65 = load double, double* %64
%66 = getelementptr inbounds double, double* %29, i64 %63
store double %65, double* %66
%67 = or i64 %39, 7
%68 = getelementptr inbounds double, double* %27, i64 %67
%69 = load double, double* %68
%70 = getelementptr inbounds double, double* %29, i64 %67
store double %69, double* %70
%71 = or i64 %39, 8
%72 = getelementptr inbounds double, double* %27, i64 %71
%73 = load double, double* %72
%74 = getelementptr inbounds double, double* %29, i64 %71
store double %73, double* %74
%75 = or i64 %39, 9
%76 = getelementptr inbounds double, double* %27, i64 %75
%77 = load double, double* %76
%78 = getelementptr inbounds double, double* %29, i64 %75
store double %77, double* %78
%79 = or i64 %39, 10
%80 = getelementptr inbounds double, double* %27, i64 %79
%81 = load double, double* %80
%82 = getelementptr inbounds double, double* %29, i64 %79
store double %81, double* %82
%83 = or i64 %39, 11
%84 = getelementptr inbounds double, double* %27, i64 %83
%85 = load double, double* %84
%86 = getelementptr inbounds double, double* %29, i64 %83
store double %85, double* %86
%87 = or i64 %39, 12
%88 = getelementptr inbounds double, double* %27, i64 %87
%89 = load double, double* %88
%90 = getelementptr inbounds double, double* %29, i64 %87
store double %89, double* %90
%91 = or i64 %39, 13
%92 = getelementptr inbounds double, double* %27, i64 %91
%93 = load double, double* %92
%94 = getelementptr inbounds double, double* %29, i64 %91
store double %93, double* %94
%95 = or i64 %39, 14
%96 = getelementptr inbounds double, double* %27, i64 %95
%97 = load double, double* %96
%98 = getelementptr inbounds double, double* %29, i64 %95
store double %97, double* %98
%99 = or i64 %39, 15
%100 = getelementptr inbounds double, double* %27, i64 %99
%101 = load double, double* %100
%102 = getelementptr inbounds double, double* %29, i64 %99
store double %101, double* %102
%103 = add nuw nsw i64 %38, 4
%104 = icmp slt i64 %103, %17
br i1 %104, label %37, label %30
105: ; preds = %35, %105
%106 = phi i64 [ %36, %35 ], [ %128, %105 ]
%107 = trunc i64 %106 to i32
%108 = shl nsw i32 %107, 2
%109 = zext i32 %108 to i64
%110 = getelementptr inbounds double, double* %27, i64 %109
%111 = load double, double* %110
%112 = getelementptr inbounds double, double* %29, i64 %109
store double %111, double* %112
%113 = or i32 %108, 1
%114 = zext i32 %113 to i64
%115 = getelementptr inbounds double, double* %27, i64 %114
%116 = load double, double* %115
%117 = getelementptr inbounds double, double* %29, i64 %114
store double %116, double* %117
%118 = or i32 %108, 2
%119 = zext i32 %118 to i64
%120 = getelementptr inbounds double, double* %27, i64 %119
%121 = load double, double* %120
%122 = getelementptr inbounds double, double* %29, i64 %119
store double %121, double* %122
%123 = or i32 %108, 3
%124 = zext i32 %123 to i64
%125 = getelementptr inbounds double, double* %27, i64 %124
%126 = load double, double* %125
%127 = getelementptr inbounds double, double* %29, i64 %124
store double %126, double* %127
%128 = add nuw nsw i64 %106, 1
%129 = icmp eq i64 %128, %22
br i1 %129, label %130, label %105
130: ; preds = %105, %32
%131 = add nuw nsw i64 %24, 4
%132 = icmp ult i64 %131, %21
br i1 %132, label %23, label %133
133: ; preds = %130
%134 = trunc i64 %131 to i32
br label %135
135: ; preds = %133, %8
%136 = phi i32 [ 0, %8 ], [ %134, %133 ]
%137 = icmp slt i32 %136, %0
br i1 %137, label %138, label %237
138: ; preds = %135
%139 = shl i32 %5, 2
%140 = add nsw i32 %1, -3
%141 = icmp sgt i32 %1, 3
%142 = sext i32 %140 to i64
%143 = zext i32 %1 to i64
br label %144
144: ; preds = %138, %234
%145 = phi i32 [ %136, %138 ], [ %235, %234 ]
%146 = add nsw i32 %145, %2
%147 = sdiv i32 %146, 4
%148 = mul i32 %139, %147
%149 = sext i32 %148 to i64
%150 = getelementptr inbounds double, double* %4, i64 %149
%151 = srem i32 %146, 4
%152 = sext i32 %151 to i64
%153 = getelementptr inbounds double, double* %150, i64 %152
%154 = and i32 %145, 2147483644
%155 = mul nsw i32 %154, %7
%156 = sext i32 %155 to i64
%157 = getelementptr inbounds double, double* %6, i64 %156
%158 = and i32 %145, 3
%159 = zext i32 %158 to i64
%160 = getelementptr inbounds double, double* %157, i64 %159
br i1 %141, label %187, label %163
161: ; preds = %187
%162 = trunc i64 %205 to i32
br label %163
163: ; preds = %161, %144
%164 = phi i32 [ 0, %144 ], [ %162, %161 ]
%165 = icmp slt i32 %164, %1
br i1 %165, label %166, label %234
166: ; preds = %163
%167 = zext i32 %164 to i64
%168 = sub nsw i64 %143, %167
%169 = xor i64 %167, -1
%170 = add nsw i64 %169, %143
%171 = and i64 %168, 3
%172 = icmp eq i64 %171, 0
br i1 %172, label %184, label %173
173: ; preds = %166, %173
%174 = phi i64 [ %181, %173 ], [ %167, %166 ]
%175 = phi i64 [ %182, %173 ], [ 0, %166 ]
%176 = shl i64 %174, 2
%177 = and i64 %176, 4294967292
%178 = getelementptr inbounds double, double* %153, i64 %177
%179 = load double, double* %178
%180 = getelementptr inbounds double, double* %160, i64 %177
store double %179, double* %180
%181 = add nuw nsw i64 %174, 1
%182 = add i64 %175, 1
%183 = icmp eq i64 %182, %171
br i1 %183, label %184, label %173
184: ; preds = %173, %166
%185 = phi i64 [ %167, %166 ], [ %181, %173 ]
%186 = icmp ult i64 %170, 3
br i1 %186, label %234, label %207
187: ; preds = %144, %187
%188 = phi i64 [ %205, %187 ], [ 0, %144 ]
%189 = shl nsw i64 %188, 2
%190 = getelementptr inbounds double, double* %153, i64 %189
%191 = load double, double* %190
%192 = getelementptr inbounds double, double* %160, i64 %189
store double %191, double* %192
%193 = or i64 %189, 4
%194 = getelementptr inbounds double, double* %153, i64 %193
%195 = load double, double* %194
%196 = getelementptr inbounds double, double* %160, i64 %193
store double %195, double* %196
%197 = or i64 %189, 8
%198 = getelementptr inbounds double, double* %153, i64 %197
%199 = load double, double* %198
%200 = getelementptr inbounds double, double* %160, i64 %197
store double %199, double* %200
%201 = or i64 %189, 12
%202 = getelementptr inbounds double, double* %153, i64 %201
%203 = load double, double* %202
%204 = getelementptr inbounds double, double* %160, i64 %201
store double %203, double* %204
%205 = add nuw nsw i64 %188, 4
%206 = icmp slt i64 %205, %142
br i1 %206, label %187, label %161
207: ; preds = %184, %207
%208 = phi i64 [ %232, %207 ], [ %185, %184 ]
%209 = shl i64 %208, 2
%210 = and i64 %209, 4294967292
%211 = getelementptr inbounds double, double* %153, i64 %210
%212 = load double, double* %211
%213 = getelementptr inbounds double, double* %160, i64 %210
store double %212, double* %213
%214 = shl i64 %208, 2
%215 = add i64 %214, 4
%216 = and i64 %215, 4294967292
%217 = getelementptr inbounds double, double* %153, i64 %216
%218 = load double, double* %217
%219 = getelementptr inbounds double, double* %160, i64 %216
store double %218, double* %219
%220 = shl i64 %208, 2
%221 = add i64 %220, 8
%222 = and i64 %221, 4294967292
%223 = getelementptr inbounds double, double* %153, i64 %222
%224 = load double, double* %223
%225 = getelementptr inbounds double, double* %160, i64 %222
store double %224, double* %225
%226 = shl i64 %208, 2
%227 = add i64 %226, 12
%228 = and i64 %227, 4294967292
%229 = getelementptr inbounds double, double* %153, i64 %228
%230 = load double, double* %229
%231 = getelementptr inbounds double, double* %160, i64 %228
store double %230, double* %231
%232 = add nuw nsw i64 %208, 4
%233 = icmp eq i64 %232, %143
br i1 %233, label %234, label %207
234: ; preds = %184, %207, %163
%235 = add nuw nsw i32 %145, 1
%236 = icmp eq i32 %235, %0
br i1 %236, label %237, label %144
237: ; preds = %234, %135
ret void
}