user: Translate the below assembly code into C programming language:

```asm
<QRinput_mask3>:
  endbr64
  test   %edi,%edi
  jle    L70
  push   %r15
  mov    %edi,%eax
  movdqa D91(%rip),%xmm3
  pxor   %xmm5,%xmm5
  push   %r14
  shr    $0x4,%eax
  movdqa %xmm5,%xmm10
  mov    %rsi,%rcx
  push   %r13
  lea    -0x1(%rax),%r11d
  pcmpgtd %xmm3,%xmm10
  xor    %esi,%esi
  movdqa D23(%rip),%xmm11
  push   %r12
  add    $0x1,%r11
  push   %rbp
  mov    %edi,%ebp
  shl    $0x4,%r11
  push   %rbx
  and    $0xfffffff0,%ebp
  mov    %edi,%ebx
  lea    0x3(%rbp),%eax
  mov    %ebp,%r12d
  lea    0x1(%rbp),%r13d
  lea    0x2(%rbp),%r14d
  mov    %eax,-0x38(%rsp)
  lea    0x4(%rbp),%eax
  mov    %eax,-0x34(%rsp)
  lea    0x5(%rbp),%eax
  mov    %eax,-0x30(%rsp)
  lea    0x6(%rbp),%eax
  mov    %eax,-0x2c(%rsp)
  lea    0x7(%rbp),%eax
  mov    %eax,-0x28(%rsp)
  lea    0x8(%rbp),%eax
  mov    %eax,-0x24(%rsp)
  lea    0x9(%rbp),%eax
  mov    %eax,-0x20(%rsp)
  lea    0xa(%rbp),%eax
  mov    %eax,-0x1c(%rsp)
  lea    0xb(%rbp),%eax
  mov    %eax,-0x14(%rsp)
  lea    0xc(%rbp),%eax
  mov    %eax,-0x10(%rsp)
  lea    0xd(%rbp),%eax
  mov    %eax,-0xc(%rsp)
  lea    0xe(%rbp),%eax
  mov    %eax,-0x18(%rsp)
  xor    %eax,%eax
  nopl   0x0(%rax,%rax,1)
L174:
  lea    0x1(%rcx),%r9
  mov    %rdx,%r8
  sub    %r9,%r8
  cmp    $0xe,%r8
  jbe    L376
  lea    -0x1(%rdi),%r8d
  cmp    $0xe,%r8d
  jbe    L376
  movd   %esi,%xmm6
  xor    %r8d,%r8d
  pxor   %xmm7,%xmm7
  movdqa D94(%rip),%xmm9
  pshufd $0x0,%xmm6,%xmm8
  pxor   %xmm6,%xmm6
  nopl   0x0(%rax,%rax,1)
L100:
  movdqa %xmm9,%xmm2
  movdqa %xmm5,%xmm13
  movdqa %xmm10,%xmm14
  movdqa D56(%rip),%xmm12
  movdqa %xmm2,%xmm0
  movdqa %xmm10,%xmm15
  movdqa D18(%rip),%xmm1
  paddd  D25(%rip),%xmm9
  paddd  %xmm8,%xmm0
  paddd  %xmm2,%xmm12
  movdqa %xmm0,%xmm4
  paddd  %xmm8,%xmm12
  paddd  %xmm2,%xmm1
  punpckldq %xmm0,%xmm4
  paddd  %xmm8,%xmm1
  paddd  D77(%rip),%xmm2
  pcmpgtd %xmm4,%xmm13
  pmuludq %xmm4,%xmm14
  pmuludq %xmm3,%xmm4
  paddd  %xmm8,%xmm2
  pmuludq %xmm3,%xmm13
  paddq  %xmm14,%xmm13
  movdqa %xmm5,%xmm14
  psllq  $0x20,%xmm13
  paddq  %xmm13,%xmm4
  movdqa %xmm0,%xmm13
  punpckhdq %xmm0,%xmm13
  pcmpgtd %xmm13,%xmm14
  pmuludq %xmm13,%xmm15
  pmuludq %xmm3,%xmm13
  pmuludq %xmm3,%xmm14
  paddq  %xmm15,%xmm14
  movdqa %xmm10,%xmm15
  psllq  $0x20,%xmm14
  paddq  %xmm14,%xmm13
  movdqa %xmm10,%xmm14
  shufps $0xdd,%xmm13,%xmm4
  movdqa %xmm0,%xmm13
  psrad  $0x1f,%xmm13
  psubd  %xmm13,%xmm4
  movdqa %xmm4,%xmm13
  pslld  $0x1,%xmm13
  paddd  %xmm13,%xmm4
  movdqa %xmm5,%xmm13
  pcmpeqd %xmm4,%xmm0
  movdqa %xmm12,%xmm4
  punpckldq %xmm12,%xmm4
  pcmpgtd %xmm4,%xmm13
  pmuludq %xmm4,%xmm14
  pmuludq %xmm3,%xmm4
  pand   %xmm11,%xmm0
  pmuludq %xmm3,%xmm13
  paddq  %xmm14,%xmm13
  movdqa %xmm5,%xmm14
  psllq  $0x20,%xmm13
  paddq  %xmm13,%xmm4
  movdqa %xmm12,%xmm13
  punpckhdq %xmm12,%xmm13
  pcmpgtd %xmm13,%xmm14
  pmuludq %xmm13,%xmm15
  pmuludq %xmm3,%xmm13
  pmuludq %xmm3,%xmm14
  paddq  %xmm15,%xmm14
  movdqa %xmm10,%xmm15
  psllq  $0x20,%xmm14
  paddq  %xmm14,%xmm13
  movdqa %xmm10,%xmm14
  shufps $0xdd,%xmm13,%xmm4
  movdqa %xmm12,%xmm13
  psrad  $0x1f,%xmm13
  psubd  %xmm13,%xmm4
  movdqa %xmm4,%xmm13
  pslld  $0x1,%xmm13
  paddd  %xmm13,%xmm4
  movdqa %xmm5,%xmm13
  pcmpeqd %xmm4,%xmm12
  movdqa %xmm1,%xmm4
  punpckldq %xmm1,%xmm4
  pcmpgtd %xmm4,%xmm13
  pmuludq %xmm4,%xmm14
  pmuludq %xmm3,%xmm4
  pand   %xmm11,%xmm12
  pmuludq %xmm3,%xmm13
  paddq  %xmm14,%xmm13
  movdqa %xmm5,%xmm14
  psllq  $0x20,%xmm13
  paddq  %xmm13,%xmm4
  movdqa %xmm1,%xmm13
  punpckhdq %xmm1,%xmm13
  pcmpgtd %xmm13,%xmm14
  pmuludq %xmm13,%xmm15
  pmuludq %xmm3,%xmm13
  pmuludq %xmm3,%xmm14
  paddq  %xmm15,%xmm14
  movdqa %xmm10,%xmm15
  psllq  $0x20,%xmm14
  paddq  %xmm14,%xmm13
  movdqa %xmm10,%xmm14
  shufps $0xdd,%xmm13,%xmm4
  movdqa %xmm1,%xmm13
  psrad  $0x1f,%xmm13
  psubd  %xmm13,%xmm4
  movdqa %xmm4,%xmm13
  pslld  $0x1,%xmm13
  paddd  %xmm13,%xmm4
  movdqa %xmm5,%xmm13
  pcmpeqd %xmm4,%xmm1
  movdqa %xmm2,%xmm4
  punpckldq %xmm2,%xmm4
  pcmpgtd %xmm4,%xmm13
  pmuludq %xmm4,%xmm14
  pmuludq %xmm3,%xmm4
  pand   %xmm11,%xmm1
  pmuludq %xmm3,%xmm13
  paddq  %xmm14,%xmm13
  movdqa %xmm5,%xmm14
  psllq  $0x20,%xmm13
  paddq  %xmm13,%xmm4
  movdqa %xmm2,%xmm13
  punpckhdq %xmm2,%xmm13
  pcmpgtd %xmm13,%xmm14
  pmuludq %xmm13,%xmm15
  pmuludq %xmm3,%xmm13
  pmuludq %xmm3,%xmm14
  paddq  %xmm15,%xmm14
  psllq  $0x20,%xmm14
  paddq  %xmm14,%xmm13
  shufps $0xdd,%xmm13,%xmm4
  movdqa %xmm2,%xmm13
  psrad  $0x1f,%xmm13
  psubd  %xmm13,%xmm4
  movdqa %xmm4,%xmm13
  pslld  $0x1,%xmm13
  paddd  %xmm13,%xmm4
  pcmpeqd %xmm4,%xmm2
  movdqa %xmm0,%xmm4
  punpcklwd %xmm12,%xmm0
  punpckhwd %xmm12,%xmm4
  movdqa %xmm0,%xmm12
  punpckhwd %xmm4,%xmm12
  punpcklwd %xmm4,%xmm0
  movdqa %xmm1,%xmm4
  pand   %xmm11,%xmm2
  punpcklwd %xmm12,%xmm0
  pand   D78(%rip),%xmm0
  punpcklwd %xmm2,%xmm1
  punpckhwd %xmm2,%xmm4
  movdqa %xmm1,%xmm2
  punpcklwd %xmm4,%xmm1
  punpckhwd %xmm4,%xmm2
  punpcklwd %xmm2,%xmm1
  pand   D78(%rip),%xmm1
  movdqu (%rcx,%r8,1),%xmm2
  packuswb %xmm1,%xmm0
  movdqu (%rcx,%r8,1),%xmm1
  pxor   %xmm0,%xmm1
  pxor   %xmm0,%xmm0
  pcmpgtb %xmm2,%xmm0
  pand   %xmm0,%xmm2
  pandn  %xmm1,%xmm0
  por    %xmm2,%xmm0
  pxor   %xmm2,%xmm2
  movups %xmm0,(%rdx,%r8,1)
  pand   D31(%rip),%xmm0
  add    $0x10,%r8
  movdqa %xmm0,%xmm1
  punpckhbw %xmm2,%xmm0
  punpcklbw %xmm2,%xmm1
  movdqa %xmm0,%xmm2
  punpckhwd %xmm7,%xmm0
  punpcklwd %xmm7,%xmm2
  paddd  %xmm2,%xmm0
  movdqa %xmm1,%xmm2
  punpckhwd %xmm7,%xmm1
  punpcklwd %xmm7,%xmm2
  paddd  %xmm2,%xmm1
  paddd  %xmm1,%xmm0
  paddd  %xmm0,%xmm6
  cmp    %r11,%r8
  jne    L100
  movdqa %xmm6,%xmm0
  lea    (%rcx,%r12,1),%r9
  psrldq $0x8,%xmm0
  paddd  %xmm6,%xmm0
  movdqa %xmm0,%xmm1
  psrldq $0x4,%xmm1
  paddd  %xmm1,%xmm0
  movd   %xmm0,%r8d
  add    %r8d,%eax
  lea    (%rdx,%r12,1),%r8
  cmp    %ebp,%edi
  je     L262
  movzbl (%r9),%r10d
  test   %r10b,%r10b
  js     L117
  lea    (%rsi,%rbp,1),%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L117:
  mov    %r10b,(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r13d,%edi
  jle    L262
  movzbl 0x1(%r9),%r10d
  test   %r10b,%r10b
  js     L41
  lea    (%rsi,%r13,1),%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L41:
  mov    %r10b,0x1(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %edi,%r14d
  jge    L262
  movzbl 0x2(%r9),%r10d
  test   %r10b,%r10b
  js     L90
  lea    (%rsi,%r14,1),%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L90:
  mov    -0x38(%rsp),%r15d
  mov    %r10b,0x2(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r15d,%edi
  jle    L262
  movzbl 0x3(%r9),%r10d
  test   %r10b,%r10b
  js     L358
  add    %esi,%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L358:
  mov    -0x34(%rsp),%r15d
  mov    %r10b,0x3(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r15d,%edi
  jle    L262
  movzbl 0x4(%r9),%r10d
  test   %r10b,%r10b
  js     L2
  add    %esi,%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L2:
  mov    -0x30(%rsp),%r15d
  mov    %r10b,0x4(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r15d,%edi
  jle    L262
  movzbl 0x5(%r9),%r10d
  test   %r10b,%r10b
  js     L138
  add    %esi,%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L138:
  mov    -0x2c(%rsp),%r15d
  mov    %r10b,0x5(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r15d,%edi
  jle    L262
  movzbl 0x6(%r9),%r10d
  test   %r10b,%r10b
  js     L334
  add    %esi,%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L334:
  mov    -0x28(%rsp),%r15d
  mov    %r10b,0x6(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r15d,%edi
  jle    L262
  movzbl 0x7(%r9),%r10d
  test   %r10b,%r10b
  js     L284
  add    %esi,%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L284:
  mov    -0x24(%rsp),%r15d
  mov    %r10b,0x7(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r15d,%edi
  jle    L262
  movzbl 0x8(%r9),%r10d
  test   %r10b,%r10b
  js     L7
  add    %esi,%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L7:
  mov    -0x20(%rsp),%r15d
  mov    %r10b,0x8(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r15d,%edi
  jle    L262
  movzbl 0x9(%r9),%r10d
  test   %r10b,%r10b
  js     L154
  add    %esi,%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L154:
  mov    -0x1c(%rsp),%r15d
  mov    %r10b,0x9(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r15d,%edi
  jle    L262
  movzbl 0xa(%r9),%r10d
  test   %r10b,%r10b
  js     L307
  add    %esi,%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L307:
  mov    -0x14(%rsp),%r15d
  mov    %r10b,0xa(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r15d,%edi
  jle    L262
  movzbl 0xb(%r9),%r10d
  test   %r10b,%r10b
  js     L123
  add    %esi,%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L123:
  mov    -0x10(%rsp),%r15d
  mov    %r10b,0xb(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r15d,%edi
  jle    L262
  movzbl 0xc(%r9),%r10d
  test   %r10b,%r10b
  js     L8
  add    %esi,%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L8:
  mov    -0xc(%rsp),%r15d
  mov    %r10b,0xc(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    %r15d,%edi
  jle    L262
  movzbl 0xd(%r9),%r10d
  test   %r10b,%r10b
  js     L84
  add    %esi,%r15d
  imul   $0xaaaaaaab,%r15d,%r15d
  cmp    $0x55555555,%r15d
  setbe  %r15b
  xor    %r15d,%r10d
L84:
  mov    %r10b,0xd(%r8)
  and    $0x1,%r10d
  add    %r10d,%eax
  cmp    -0x18(%rsp),%edi
  jle    L262
  movzbl 0xe(%r9),%r9d
  test   %r9b,%r9b
  js     L71
  mov    -0x18(%rsp),%r10d
  add    %esi,%r10d
  imul   $0xaaaaaaab,%r10d,%r10d
  cmp    $0x55555555,%r10d
  setbe  %r10b
  xor    %r10d,%r9d
L71:
  mov    %r9b,0xe(%r8)
  and    $0x1,%r9d
  add    %r9d,%eax
  nopw   0x0(%rax,%rax,1)
L262:
  add    $0x1,%esi
  add    %rbx,%rcx
  add    %rbx,%rdx
  cmp    %esi,%edi
  jne    L174
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax)
L376:
  xor    %r8d,%r8d
L22:
  movzbl (%rcx,%r8,1),%r9d
  test   %r9b,%r9b
  js     L234
  lea    (%rsi,%r8,1),%r10d
  imul   $0xaaaaaaab,%r10d,%r10d
  cmp    $0x55555555,%r10d
  setbe  %r10b
  xor    %r10d,%r9d
L234:
  mov    %r9b,(%rdx,%r8,1)
  and    $0x1,%r9d
  add    $0x1,%r8
  add    %r9d,%eax
  cmp    %rbx,%r8
  jne    L22
  jmp    L262
L70:
  xor    %eax,%eax
  ret
```

tool_calls: name: parse_data
arguments: label: D91
datatype: byte[16]
name: parse_data
arguments: label: D23
datatype: byte[16]
name: parse_data
arguments: label: D94
datatype: byte[16]
name: parse_data
arguments: label: D56
datatype: byte[16]
name: parse_data
arguments: label: D18
datatype: byte[16]
name: parse_data
arguments: label: D25
datatype: byte[16]
name: parse_data
arguments: label: D77
datatype: byte[16]
name: parse_data
arguments: label: D78
datatype: byte[16]
name: parse_data
arguments: label: D31
datatype: byte[16]

tool: {"D91": [0x56,0x55,0x55,0x55,0x56,0x55,0x55,0x55,0x56,0x55,0x55,0x55,0x56,0x55,0x55,0x55]}

tool: {"D23": [0x01,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x01,0x00,0x00,0x00,0x01,0x00,0x00,0x00]}

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

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

tool: {"D18": [0x08,0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x08,0x00,0x00,0x00,0x08,0x00,0x00,0x00]}

tool: {"D25": [0x10,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x10,0x00,0x00,0x00,0x10,0x00,0x00,0x00]}

tool: {"D77": [0x0c,0x00,0x00,0x00,0x0c,0x00,0x00,0x00,0x0c,0x00,0x00,0x00,0x0c,0x00,0x00,0x00]}

tool: {"D78": [0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00,0xff,0x00]}

tool: {"D31": [0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01]}

assistant: ```c
int QRinput_mask3(int width, const unsigned char *s, unsigned char *d) {
  int x, y;
  unsigned int b = 0;
  for (y = 0; y < width; y++) {
    for (x = 0; x < width; x++) {
      if (*s & 0x80) {
        *d = *s;
      } else {
        *d = *s ^ (((x + y) % 3) == 0);
      }
      b += (*d & 1);
      s++;
      d++;
    }
  }
  return b;
}
```