user: 请将以下的汇编代码转换成C语言代码：

```asm
<generateMatrix>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x50,%rsp
  mov    %edi,-0x34(%rbp)
  mov    %rsi,-0x40(%rbp)
  mov    %rdx,-0x48(%rbp)
  mov    -0x34(%rbp),%eax
  cltq
  shl    $0x3,%eax
  mov    %eax,%edi
  call   <malloc@plt>
  mov    %rax,-0x10(%rbp)
  mov    -0x34(%rbp),%eax
  imul   %eax,%eax
  cltq
  shl    $0x2,%eax
  mov    %eax,%edi
  call   <malloc@plt>
  mov    %rax,-0x8(%rbp)
  mov    -0x40(%rbp),%rax
  mov    -0x34(%rbp),%edx
  mov    %edx,(%rax)
  mov    -0x34(%rbp),%eax
  cltq
  shl    $0x2,%eax
  mov    %eax,%edi
  call   <malloc@plt>
  mov    -0x48(%rbp),%rdx
  mov    %rax,(%rdx)
  movl   $0x0,-0x2c(%rbp)
  jmp    L59
L208:
  mov    -0x2c(%rbp),%eax
  imul   -0x34(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rcx
  mov    -0x2c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x10(%rbp),%rax
  add    %rdx,%rax
  mov    -0x8(%rbp),%rdx
  add    %rcx,%rdx
  mov    %rdx,(%rax)
  mov    -0x48(%rbp),%rax
  mov    (%rax),%rdx
  mov    -0x2c(%rbp),%eax
  cltq
  shl    $0x2,%rax
  add    %rax,%rdx
  mov    -0x34(%rbp),%eax
  mov    %eax,(%rdx)
  addl   $0x1,-0x2c(%rbp)
L59:
  mov    -0x2c(%rbp),%eax
  cmp    -0x34(%rbp),%eax
  jl     L208
  movl   $0x0,-0x28(%rbp)
  movl   $0x0,-0x24(%rbp)
  mov    -0x34(%rbp),%eax
  sub    $0x1,%eax
  mov    %eax,-0x20(%rbp)
  movl   $0x0,-0x1c(%rbp)
  mov    -0x34(%rbp),%eax
  sub    $0x1,%eax
  mov    %eax,-0x18(%rbp)
  movl   $0x0,-0x14(%rbp)
  jmp    L213
L192:
  cmpl   $0x3,-0x28(%rbp)
  je     L127
  cmpl   $0x3,-0x28(%rbp)
  jg     L206
  cmpl   $0x2,-0x28(%rbp)
  je     L8
  cmpl   $0x2,-0x28(%rbp)
  jg     L206
  cmpl   $0x0,-0x28(%rbp)
  je     L82
  cmpl   $0x1,-0x28(%rbp)
  je     L62
  jmp    L206
L82:
  mov    -0x1c(%rbp),%eax
  mov    %eax,-0x2c(%rbp)
  jmp    L197
L185:
  addl   $0x1,-0x14(%rbp)
  mov    -0x24(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x10(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x2c(%rbp),%eax
  cltq
  shl    $0x2,%rax
  add    %rax,%rdx
  mov    -0x14(%rbp),%eax
  mov    %eax,(%rdx)
  addl   $0x1,-0x2c(%rbp)
L197:
  mov    -0x2c(%rbp),%eax
  cmp    -0x18(%rbp),%eax
  jle    L185
  addl   $0x1,-0x24(%rbp)
  jmp    L206
L62:
  mov    -0x24(%rbp),%eax
  mov    %eax,-0x2c(%rbp)
  jmp    L12
L184:
  addl   $0x1,-0x14(%rbp)
  mov    -0x2c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x10(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x18(%rbp),%eax
  cltq
  shl    $0x2,%rax
  add    %rax,%rdx
  mov    -0x14(%rbp),%eax
  mov    %eax,(%rdx)
  addl   $0x1,-0x2c(%rbp)
L12:
  mov    -0x2c(%rbp),%eax
  cmp    -0x20(%rbp),%eax
  jle    L184
  subl   $0x1,-0x18(%rbp)
  jmp    L206
L8:
  mov    -0x18(%rbp),%eax
  mov    %eax,-0x2c(%rbp)
  jmp    L198
L121:
  addl   $0x1,-0x14(%rbp)
  mov    -0x20(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x10(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x2c(%rbp),%eax
  cltq
  shl    $0x2,%rax
  add    %rax,%rdx
  mov    -0x14(%rbp),%eax
  mov    %eax,(%rdx)
  subl   $0x1,-0x2c(%rbp)
L198:
  mov    -0x2c(%rbp),%eax
  cmp    -0x1c(%rbp),%eax
  jge    L121
  subl   $0x1,-0x20(%rbp)
  jmp    L206
L127:
  mov    -0x20(%rbp),%eax
  mov    %eax,-0x2c(%rbp)
  jmp    L147
L29:
  addl   $0x1,-0x14(%rbp)
  mov    -0x2c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x10(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x1c(%rbp),%eax
  cltq
  shl    $0x2,%rax
  add    %rax,%rdx
  mov    -0x14(%rbp),%eax
  mov    %eax,(%rdx)
  subl   $0x1,-0x2c(%rbp)
L147:
  mov    -0x2c(%rbp),%eax
  cmp    -0x24(%rbp),%eax
  jge    L29
  addl   $0x1,-0x1c(%rbp)
  nop
L206:
  addl   $0x1,-0x28(%rbp)
  mov    -0x28(%rbp),%eax
  cltd
  shr    $0x1e,%edx
  add    %edx,%eax
  and    $0x3,%eax
  sub    %edx,%eax
  mov    %eax,-0x28(%rbp)
L213:
  mov    -0x34(%rbp),%eax
  imul   %eax,%eax
  cmp    %eax,-0x14(%rbp)
  jl     L192
  mov    -0x10(%rbp),%rax
  leave
  ret
```

assistant: ```c
int **generateMatrix(int n, int *returnSize, int **returnColumnSizes) {
  int i;
  int **matrix = malloc(n * sizeof(int *));
  int *nums = malloc(n * n * sizeof(int));
  *returnSize = n;
  *returnColumnSizes = malloc(n * sizeof(int));
  for (i = 0; i < n; i++) {
    matrix[i] = &nums[i * n];
    (*returnColumnSizes)[i] = n;
  }
  int direction = 0;
  int hor_top = 0;
  int hor_bottom = n - 1;
  int ver_left = 0;
  int ver_right = n - 1;
  int num = 0;
  while (num < n * n) {
    switch (direction) {
    case 0:
      for (i = ver_left; i <= ver_right; i++) {
        matrix[hor_top][i] = ++num;
      }
      hor_top++;
      break;
    case 1:
      for (i = hor_top; i <= hor_bottom; i++) {
        matrix[i][ver_right] = ++num;
      }
      ver_right--;
      break;
    case 2:
      for (i = ver_right; i >= ver_left; i--) {
        matrix[hor_bottom][i] = ++num;
      }
      hor_bottom--;
      break;
    case 3:
      for (i = hor_bottom; i >= hor_top; i--) {
        matrix[i][ver_left] = ++num;
      }
      ver_left++;
      break;
    }
    direction++;
    direction %= 4;
  }
  return matrix;
}
```