user: Converte this assembly snippet into its equivalent C code:

```asm
<zero_imat>:
  endbr64
  push   %r12
  push   %rbp
  movslq %esi,%rbp
  push   %rbx
  mov    %edi,%ebx
  shl    $0x3,%edi
  call   <malloc@plt>
  mov    %ebx,%edi
  mov    $0x4,%esi
  imul   %ebp,%edi
  mov    %rax,%r12
  call   <calloc@plt>
  mov    %rax,(%r12)
  test   %ebx,%ebx
  jle    L0
  cmp    $0x1,%ebx
  je     L0
  lea    -0x2(%rbx),%edx
  cmp    $0x5,%edx
  jbe    L32
  lea    -0x1(%rbx),%esi
  movdqa D8(%rip),%xmm2
  pxor   %xmm5,%xmm5
  movd   %ebp,%xmm7
  movdqa %xmm5,%xmm6
  pshufd $0x0,%xmm7,%xmm7
  movq   %rax,%xmm3
  mov    %esi,%edx
  pcmpgtd %xmm2,%xmm6
  shr    $0x2,%edx
  movdqa %xmm7,%xmm8
  punpcklqdq %xmm3,%xmm3
  sub    $0x1,%edx
  movdqa D10(%rip),%xmm4
  lea    0x8(%r12),%rax
  shl    $0x5,%rdx
  psrlq  $0x20,%xmm8
  lea    0x28(%r12,%rdx,1),%rdx
  nopw   0x0(%rax,%rax,1)
L53:
  movdqa %xmm4,%xmm1
  movdqa %xmm5,%xmm9
  paddd  %xmm2,%xmm4
  add    $0x20,%rax
  movdqa %xmm1,%xmm0
  psrlq  $0x20,%xmm1
  movdqa %xmm6,%xmm10
  pmuludq %xmm7,%xmm0
  pmuludq %xmm8,%xmm1
  pshufd $0x8,%xmm0,%xmm0
  pshufd $0x8,%xmm1,%xmm1
  punpckldq %xmm1,%xmm0
  movdqa %xmm0,%xmm1
  punpckldq %xmm0,%xmm1
  punpckhdq %xmm0,%xmm0
  pcmpgtd %xmm1,%xmm9
  pmuludq %xmm1,%xmm10
  pmuludq %xmm2,%xmm1
  pmuludq %xmm2,%xmm9
  paddq  %xmm10,%xmm9
  psllq  $0x20,%xmm9
  paddq  %xmm9,%xmm1
  movdqa %xmm6,%xmm9
  paddq  %xmm3,%xmm1
  pmuludq %xmm0,%xmm9
  movups %xmm1,-0x20(%rax)
  movdqa %xmm5,%xmm1
  pcmpgtd %xmm0,%xmm1
  pmuludq %xmm2,%xmm0
  pmuludq %xmm2,%xmm1
  paddq  %xmm9,%xmm1
  psllq  $0x20,%xmm1
  paddq  %xmm1,%xmm0
  paddq  %xmm3,%xmm0
  movups %xmm0,-0x10(%rax)
  cmp    %rdx,%rax
  jne    L53
  mov    %esi,%edx
  and    $0xfffffffc,%edx
  lea    0x1(%rdx),%ecx
  cmp    %edx,%esi
  je     L0
  mov    %ebp,%eax
  mov    (%r12),%rdi
  imul   %ecx,%eax
  movslq %ecx,%rcx
  lea    0x0(,%rcx,8),%rsi
  movslq %eax,%r8
  lea    (%rdi,%r8,4),%rdi
  mov    %rdi,(%r12,%rcx,8)
  lea    0x2(%rdx),%ecx
  cmp    %ecx,%ebx
  jle    L0
  mov    (%r12),%rcx
  add    %ebp,%eax
  add    $0x3,%edx
  movslq %eax,%rdi
  lea    (%rcx,%rdi,4),%rcx
  mov    %rcx,0x8(%r12,%rsi,1)
  cmp    %edx,%ebx
  jle    L0
  mov    (%r12),%rdx
  add    %ebp,%eax
  cltq
  lea    (%rdx,%rax,4),%rax
  mov    %rax,0x10(%r12,%rsi,1)
L0:
  mov    %r12,%rax
  pop    %rbx
  pop    %rbp
  pop    %r12
  ret
  nopw   0x0(%rax,%rax,1)
L32:
  shl    $0x2,%rbp
  lea    0x10(%r12,%rdx,8),%rsi
  lea    0x8(%r12),%rax
  mov    %rbp,%rdx
  nopl   0x0(%rax)
L77:
  mov    (%r12),%rcx
  add    $0x8,%rax
  add    %rdx,%rcx
  add    %rbp,%rdx
  mov    %rcx,-0x8(%rax)
  cmp    %rsi,%rax
  jne    L77
  mov    %r12,%rax
  pop    %rbx
  pop    %rbp
  pop    %r12
  ret
```

tool_calls: name: unpack_data
arguments: data_label: D8
data_type: byte[16]
name: unpack_data
arguments: data_label: D10
data_type: byte[16]

tool: {"D8": [0x04,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x04,0x00,0x00,0x00,0x04,0x00,0x00,0x00]}

tool: {"D10": [0x01,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x03,0x00,0x00,0x00,0x04,0x00,0x00,0x00]}

assistant: ```c
int **zero_imat(int nx, int ny) {
  int **p = (int **)malloc(sizeof(int *) * nx);
  p[0] = (int *)calloc(nx * ny, sizeof(int));
  for (int i = 0; i < nx; ++i)
    p[i] = p[0] + ny * i;
  return p;
}
```