user: 请从给定的汇编指令推导出C源代码：

```asm
<wireworld>:
  endbr64
  push   %r15
  mov    %edx,%r15d
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  mov    %esi,%ebp
  push   %rbx
  mov    %rdi,%rbx
  sub    $0x28,%rsp
  mov    %rdi,0x18(%rsp)
  mov    %edx,0xc(%rsp)
  call   <copy_world@plt>
  mov    %rax,0x10(%rsp)
  test   %r15d,%r15d
  jle    L335
  test   %ebp,%ebp
  jle    L335
  lea    -0x1(%rbp),%r12d
  xor    %r10d,%r10d
  lea    -0x1(%r15),%r14d
  mov    %rax,%rdi
  cmp    %r12d,%ebp
  mov    %r12d,%r11d
  cmovle %ebp,%r11d
  cs nopw 0x0(%rax,%rax,1)
L388:
  mov    (%rbx),%rcx
  test   %r12d,%r12d
  jne    L439
  xor    %eax,%eax
L153:
  movslq %eax,%rdx
  lea    -0x4(,%rdx,4),%rdx
  jmp    L200
  nopl   0x0(%rax,%rax,1)
L159:
  mov    (%rdi),%rsi
  movl   $0x0,(%rsi,%rdx,1)
L86:
  add    $0x1,%eax
  cmp    %eax,%ebp
  jle    L547
L200:
  mov    %rdx,%r8
  add    $0x4,%rdx
  mov    0x4(%rcx,%r8,1),%esi
  test   %esi,%esi
  je     L159
  cmp    $0x1,%esi
  je     L467
  cmp    $0x2,%esi
  je     L140
  cmp    $0x3,%esi
  jne    L86
  mov    (%rdi),%rsi
  add    $0x1,%eax
  movl   $0x1,(%rsi,%rdx,1)
  cmp    %eax,%ebp
  jg     L200
  nopl   (%rax)
L547:
  add    $0x1,%r10d
  add    $0x8,%rbx
  add    $0x8,%rdi
  cmp    %r10d,0xc(%rsp)
  jne    L388
L335:
  mov    0xc(%rsp),%edx
  mov    0x18(%rsp),%rdi
  mov    %ebp,%esi
  call   <free_world@plt>
  mov    0x10(%rsp),%rax
  add    $0x28,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nop
L467:
  test   %eax,%eax
  jle    L453
  test   %r10d,%r10d
  jle    L453
  mov    -0x8(%rbx),%r9
  xor    %esi,%esi
  cmpl   $0x2,(%r9,%r8,1)
  sete   %sil
L489:
  xor    %r13d,%r13d
  cmpl   $0x2,(%r9,%rdx,1)
  sete   %r13b
  add    %r13d,%esi
  cmp    %r12d,%eax
  jge    L187
  cmpl   $0x2,0x8(%r9,%r8,1)
  jne    L28
  add    $0x1,%esi
L28:
  test   %eax,%eax
  je     L366
  cmpl   $0x2,(%rcx,%r8,1)
  je     L452
L366:
  cmpl   $0x2,0x8(%rcx,%r8,1)
  jne    L313
  add    $0x1,%esi
  nopl   (%rax)
L313:
  cmp    %r10d,%r14d
  jle    L83
  mov    0x8(%rbx),%r9
  test   %eax,%eax
  je     L298
  cmpl   $0x2,(%r9,%r8,1)
  sete   %r8b
  movzbl %r8b,%r8d
  add    %r8d,%esi
L298:
  xor    %r8d,%r8d
  cmpl   $0x2,(%r9,%rdx,1)
  sete   %r8b
  add    %r8d,%esi
L83:
  sub    $0x1,%esi
  cmp    $0x1,%esi
  ja     L86
  mov    (%rdi),%rsi
  movl   $0x2,(%rsi,%rdx,1)
  jmp    L86
  nopw   0x0(%rax,%rax,1)
L453:
  xor    %esi,%esi
  test   %r10d,%r10d
  jne    L70
L187:
  test   %eax,%eax
  je     L451
  cmpl   $0x2,(%rcx,%r8,1)
  je     L452
L451:
  cmp    %eax,%r12d
  jle    L313
  jmp    L366
  nopl   0x0(%rax)
L140:
  mov    (%rdi),%rsi
  movl   $0x3,(%rsi,%rdx,1)
  jmp    L86
  nopw   0x0(%rax,%rax,1)
L439:
  mov    $0xfffffffffffffffc,%rsi
  mov    $0x4,%edx
  xor    %eax,%eax
  jmp    L286
L510:
  mov    (%rdi),%r8
  movl   $0x0,-0x4(%r8,%rdx,1)
L93:
  add    $0x1,%eax
  add    $0x4,%rdx
  add    $0x4,%rsi
  cmp    %r11d,%eax
  jge    L303
L286:
  mov    -0x4(%rcx,%rdx,1),%r8d
  lea    -0x4(%rdx),%r9
  test   %r8d,%r8d
  je     L510
  cmp    $0x1,%r8d
  je     L340
  cmp    $0x2,%r8d
  je     L509
  cmp    $0x3,%r8d
  jne    L93
  mov    (%rdi),%r8
  add    $0x1,%eax
  add    $0x4,%rdx
  add    $0x4,%rsi
  movl   $0x1,(%r8,%r9,1)
  cmp    %r11d,%eax
  jl     L286
  nopl   0x0(%rax,%rax,1)
L303:
  cmp    %eax,%ebp
  jg     L153
  jmp    L547
  nopl   (%rax)
L340:
  test   %r10d,%r10d
  jle    L25
  test   %eax,%eax
  jle    L25
  mov    -0x8(%rbx),%r13
  xor    %r8d,%r8d
  cmpl   $0x2,0x0(%r13,%rsi,1)
  sete   %r8b
L103:
  xor    %r15d,%r15d
  cmpl   $0x2,0x0(%r13,%r9,1)
  sete   %r15b
  add    %r15d,%r8d
  cmp    %r12d,%eax
  jge    L229
  cmpl   $0x2,0x0(%r13,%rdx,1)
  sete   %r13b
  movzbl %r13b,%r13d
  add    %r13d,%r8d
  test   %eax,%eax
  je     L486
  cmpl   $0x2,-0x8(%rcx,%rdx,1)
  je     L529
L486:
  xor    %r13d,%r13d
  cmpl   $0x2,(%rcx,%rdx,1)
  sete   %r13b
  add    %r13d,%r8d
L40:
  cmp    %r10d,%r14d
  jle    L419
  mov    0x8(%rbx),%r13
  test   %eax,%eax
  je     L478
  xor    %r15d,%r15d
  cmpl   $0x2,0x0(%r13,%rsi,1)
  sete   %r15b
  add    %r15d,%r8d
L478:
  xor    %r15d,%r15d
  cmpl   $0x2,0x0(%r13,%r9,1)
  sete   %r15b
  add    %r15d,%r8d
  cmpl   $0x2,0x0(%r13,%rdx,1)
  sete   %r13b
  movzbl %r13b,%r13d
  add    %r13d,%r8d
L419:
  sub    $0x1,%r8d
  cmp    $0x1,%r8d
  ja     L93
  mov    (%rdi),%r8
  movl   $0x2,(%r8,%r9,1)
  jmp    L93
  nopl   (%rax)
L25:
  xor    %r8d,%r8d
  test   %r10d,%r10d
  jne    L322
L229:
  test   %eax,%eax
  je     L283
  cmpl   $0x2,-0x8(%rcx,%rdx,1)
  je     L529
L283:
  cmp    %eax,%r12d
  jle    L40
  jmp    L486
  nopl   (%rax)
L509:
  mov    (%rdi),%r8
  movl   $0x3,(%r8,%r9,1)
  jmp    L93
  nopl   0x0(%rax,%rax,1)
L322:
  mov    -0x8(%rbx),%r13
  jmp    L103
  nopl   0x0(%rax)
L70:
  mov    -0x8(%rbx),%r9
  jmp    L489
  nopl   0x0(%rax)
L529:
  add    $0x1,%r8d
  jmp    L283
  cs nopw 0x0(%rax,%rax,1)
L452:
  add    $0x1,%esi
  jmp    L451
```

assistant: ```c
int **wireworld(int **world, int SIZE_X, int SIZE_Y) {
  int **newWorld = copy_world(world, SIZE_X, SIZE_Y);
  int i;
  int j;
  for (i = 0; i < SIZE_Y; i++) {
    for (j = 0; j < SIZE_X; j++) {
      if (world[i][j] == 0)
        newWorld[i][j] = 0;
      else if (world[i][j] == 1) {
        int sum = 0;
        if (i > 0 && j > 0 && world[i - 1][j - 1] == 2)
          sum++;
        if (i > 0 && world[i - 1][j] == 2)
          sum++;
        if (i > 0 && j < SIZE_X - 1 && world[i - 1][j + 1] == 2)
          sum++;
        if (j > 0 && world[i][j - 1] == 2)
          sum++;
        if (j < SIZE_X - 1 && world[i][j + 1] == 2)
          sum++;
        if (i < SIZE_Y - 1 && j > 0 && world[i + 1][j - 1] == 2)
          sum++;
        if (i < SIZE_Y - 1 && world[i + 1][j] == 2)
          sum++;
        if (i < SIZE_Y - 1 && j < SIZE_X - 1 && world[i + 1][j + 1] == 2)
          sum++;
        if (sum == 1 || sum == 2)
          newWorld[i][j] = 2;
      } else if (world[i][j] == 2)
        newWorld[i][j] = 3;
      else if (world[i][j] == 3)
        newWorld[i][j] = 1;
    }
  }
  free_world(world, SIZE_X, SIZE_Y);
  return newWorld;
}
```