user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x40,%rsp
  movl   $0x0,-0x40(%rbp)
  movl   $0x0,-0x3c(%rbp)
  jmp    L141
L142:
  mov    $0x0,%eax
  call   <gang@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x3c(%rbp)
L141:
  cmpl   $0x9,-0x3c(%rbp)
  jle    L142
  movl   $0x0,-0x38(%rbp)
  jmp    L81
L163:
  mov    $0x0,%eax
  call   <worker@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x38(%rbp)
L81:
  cmpl   $0x9,-0x38(%rbp)
  jle    L163
  movl   $0x0,-0x34(%rbp)
  jmp    L265
L7:
  mov    $0x0,%eax
  call   <vector@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x34(%rbp)
L265:
  cmpl   $0x9,-0x34(%rbp)
  jle    L7
  movl   $0x0,-0x30(%rbp)
  jmp    L91
L104:
  mov    $0x0,%eax
  call   <gang@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x30(%rbp)
L91:
  cmpl   $0x9,-0x30(%rbp)
  jle    L104
  movl   $0x0,-0x2c(%rbp)
  jmp    L298
L240:
  mov    $0x0,%eax
  call   <gang@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x2c(%rbp)
L298:
  cmpl   $0x9,-0x2c(%rbp)
  jle    L240
  movl   $0x0,-0x28(%rbp)
  jmp    L297
L69:
  mov    $0x0,%eax
  call   <gang@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x28(%rbp)
L297:
  cmpl   $0x9,-0x28(%rbp)
  jle    L69
  movl   $0x0,-0x24(%rbp)
  jmp    L250
L79:
  mov    $0x0,%eax
  call   <worker@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x24(%rbp)
L250:
  cmpl   $0x9,-0x24(%rbp)
  jle    L79
  movl   $0x0,-0x20(%rbp)
  jmp    L89
L181:
  mov    $0x0,%eax
  call   <worker@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x20(%rbp)
L89:
  cmpl   $0x9,-0x20(%rbp)
  jle    L181
  movl   $0x0,-0x1c(%rbp)
  jmp    L255
L2:
  mov    $0x0,%eax
  call   <worker@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x1c(%rbp)
L255:
  cmpl   $0x9,-0x1c(%rbp)
  jle    L2
  movl   $0x0,-0x18(%rbp)
  jmp    L57
L135:
  mov    $0x0,%eax
  call   <vector@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x18(%rbp)
L57:
  cmpl   $0x9,-0x18(%rbp)
  jle    L135
  movl   $0x0,-0x14(%rbp)
  jmp    L198
L151:
  mov    $0x0,%eax
  call   <vector@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x14(%rbp)
L198:
  cmpl   $0x9,-0x14(%rbp)
  jle    L151
  movl   $0x0,-0x10(%rbp)
  jmp    L217
L279:
  mov    $0x0,%eax
  call   <vector@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x10(%rbp)
L217:
  cmpl   $0x9,-0x10(%rbp)
  jle    L279
  movl   $0x0,-0xc(%rbp)
  jmp    L275
L90:
  mov    $0x0,%eax
  call   <seq@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0xc(%rbp)
L275:
  cmpl   $0x9,-0xc(%rbp)
  jle    L90
  movl   $0x0,-0x8(%rbp)
  jmp    L14
L75:
  mov    $0x0,%eax
  call   <seq@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x8(%rbp)
L14:
  cmpl   $0x9,-0x8(%rbp)
  jle    L75
  movl   $0x0,-0x4(%rbp)
  jmp    L25
L47:
  mov    $0x0,%eax
  call   <seq@plt>
  mov    %eax,%edx
  mov    -0x40(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x40(%rbp)
  addl   $0x1,-0x4(%rbp)
L25:
  cmpl   $0x9,-0x4(%rbp)
  jle    L47
  mov    $0x0,%eax
  leave
  ret
```

assistant: ```c
int main() {
  int red = 0;
#pragma acc parallel copy(red)
  {
#pragma acc loop reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += gang();
#pragma acc loop reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += worker();
#pragma acc loop reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += vector();
#pragma acc loop gang reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += gang();
#pragma acc loop worker reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += gang();
#pragma acc loop vector reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += gang();
#pragma acc loop gang reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += worker();
#pragma acc loop worker reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += worker();
#pragma acc loop vector reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += worker();
#pragma acc loop gang reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += vector();
#pragma acc loop worker reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += vector();
#pragma acc loop vector reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += vector();
#pragma acc loop gang reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += seq();
#pragma acc loop worker reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += seq();
#pragma acc loop vector reduction(+ : red)
    for (int i = 0; i < 10; i++)
      red += seq();
  }
  return 0;
}
```