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

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x70,%rsp
  mov    %edi,-0x54(%rbp)
  mov    %rsi,-0x60(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  movl   $0x0,-0x40(%rbp)
  movl   $0x2,-0x2c(%rbp)
  movss  D11(%rip),%xmm0
  movss  %xmm0,-0x28(%rbp)
  pxor   %xmm0,%xmm0
  movss  %xmm0,-0x3c(%rbp)
  movss  -0x28(%rbp),%xmm0
  movss  %xmm0,-0x38(%rbp)
  movss  D121(%rip),%xmm0
  movss  %xmm0,-0x24(%rbp)
  movl   $0x0,-0x34(%rbp)
  movl   $0x0,-0x30(%rbp)
  movl   $0x1,-0x44(%rbp)
  jmp    L30
L45:
  mov    -0x44(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x60(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rax
  lea    D32(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L26
  movl   $0x1,-0x34(%rbp)
L26:
  mov    -0x44(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x60(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rax
  lea    D123(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcmp@plt>
  test   %eax,%eax
  jne    L29
  movl   $0x1,-0x30(%rbp)
L29:
  addl   $0x1,-0x44(%rbp)
L30:
  mov    -0x44(%rbp),%eax
  cmp    -0x54(%rbp),%eax
  jl     L45
  mov    $0x190,%esi
  mov    $0x190,%edi
  mov    $0x0,%eax
  call   <prefsize@plt>
  lea    D53(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <winopen@plt>
  mov    $0x1b,%edi
  mov    $0x0,%eax
  call   <qdevice@plt>
  mov    $0x51,%edi
  mov    $0x0,%eax
  call   <qdevice@plt>
  mov    $0x106,%edi
  mov    $0x0,%eax
  call   <unqdevice@plt>
  nop
L91:
  lea    -0x46(%rbp),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <qread@plt>
  cmp    $0x105,%eax
  jne    L91
  mov    $0x0,%eax
  call   <doublebuffer@plt>
  mov    $0x0,%eax
  call   <gconfig@plt>
  mov    $0x0,%edi
  mov    $0x0,%eax
  call   <polymode@plt>
  cmpl   $0x0,-0x30(%rbp)
  je     L42
  mov    $0x1,%edi
  mov    $0x0,%eax
  call   <polymode@plt>
L42:
  cmpl   $0x0,-0x34(%rbp)
  je     L52
  mov    $0x1,%edi
  mov    $0x0,%eax
  call   <backface@plt>
L52:
  movsd  D98(%rip),%xmm1
  movsd  D169(%rip),%xmm0
  mov    D25(%rip),%rax
  movapd %xmm1,%xmm2
  movapd %xmm0,%xmm1
  movq   %rax,%xmm0
  mov    $0x190,%edi
  mov    $0x3,%eax
  call   <perspective@plt>
  pxor   %xmm0,%xmm0
  cvtss2sd -0x24(%rbp),%xmm0
  mov    $0x0,%edi
  pxor   %xmm5,%xmm5
  pxor   %xmm4,%xmm4
  pxor   %xmm3,%xmm3
  movapd %xmm0,%xmm2
  pxor   %xmm1,%xmm1
  mov    D151(%rip),%rax
  movq   %rax,%xmm0
  mov    $0x6,%eax
  call   <lookat@plt>
  mov    $0x0,%eax
  call   <maketetra@plt>
L5:
  movl   $0x0,-0x40(%rbp)
  jmp    L60
L48:
  mov    $0x0,%edi
  mov    $0x0,%eax
  call   <color@plt>
  mov    $0x0,%eax
  call   <clear@plt>
  mov    -0x2c(%rbp),%eax
  mov    $0x78,%esi
  mov    %eax,%edi
  mov    $0x0,%eax
  call   <rotate@plt>
  mov    -0x2c(%rbp),%eax
  mov    $0x7a,%esi
  mov    %eax,%edi
  mov    $0x0,%eax
  call   <rotate@plt>
  mov    $0x1,%edi
  mov    $0x0,%eax
  call   <color@plt>
  mov    $0x0,%eax
  call   <pushmatrix@plt>
  mov    $0x78,%esi
  mov    $0x384,%edi
  mov    $0x0,%eax
  call   <rotate@plt>
  pxor   %xmm0,%xmm0
  cvtss2sd -0x28(%rbp),%xmm0
  movapd %xmm0,%xmm2
  pxor   %xmm1,%xmm1
  mov    D151(%rip),%rax
  movq   %rax,%xmm0
  mov    $0x3,%eax
  call   <circ@plt>
  mov    $0x0,%eax
  call   <popmatrix@plt>
  mov    $0x4,%edi
  mov    $0x0,%eax
  call   <color@plt>
  pxor   %xmm2,%xmm2
  pxor   %xmm1,%xmm1
  mov    D151(%rip),%rax
  movq   %rax,%xmm0
  mov    $0x3,%eax
  call   <move@plt>
  pxor   %xmm0,%xmm0
  cvtss2sd -0x38(%rbp),%xmm0
  pxor   %xmm6,%xmm6
  cvtss2sd -0x3c(%rbp),%xmm6
  movq   %xmm6,%rax
  movapd %xmm0,%xmm2
  pxor   %xmm1,%xmm1
  movq   %rax,%xmm0
  mov    $0x3,%eax
  call   <draw@plt>
  mov    $0x0,%eax
  call   <pushmatrix@plt>
  pxor   %xmm0,%xmm0
  cvtss2sd -0x38(%rbp),%xmm0
  pxor   %xmm7,%xmm7
  cvtss2sd -0x3c(%rbp),%xmm7
  movq   %xmm7,%rax
  movapd %xmm0,%xmm2
  pxor   %xmm1,%xmm1
  movq   %rax,%xmm0
  mov    $0x3,%eax
  call   <translate@plt>
  mov    -0x40(%rbp),%eax
  mov    $0x78,%esi
  mov    %eax,%edi
  mov    $0x0,%eax
  call   <rotate@plt>
  mov    -0x40(%rbp),%eax
  mov    $0x79,%esi
  mov    %eax,%edi
  mov    $0x0,%eax
  call   <rotate@plt>
  mov    -0x40(%rbp),%eax
  mov    $0x7a,%esi
  mov    %eax,%edi
  mov    $0x0,%eax
  call   <rotate@plt>
  movsd  D115(%rip),%xmm1
  movsd  D115(%rip),%xmm0
  mov    D115(%rip),%rax
  movapd %xmm1,%xmm2
  movapd %xmm0,%xmm1
  movq   %rax,%xmm0
  mov    $0x3,%eax
  call   <scale@plt>
  mov    $0x1,%edi
  mov    $0x0,%eax
  call   <callobj@plt>
  mov    $0x0,%eax
  call   <popmatrix@plt>
  pxor   %xmm3,%xmm3
  cvtss2sd -0x28(%rbp),%xmm3
  movsd  %xmm3,-0x68(%rbp)
  pxor   %xmm1,%xmm1
  cvtsi2sdl -0x40(%rbp),%xmm1
  movsd  D26(%rip),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  D49(%rip),%xmm1
  divsd  %xmm1,%xmm0
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  call   <cos@plt>
  mulsd  -0x68(%rbp),%xmm0
  cvtsd2ss %xmm0,%xmm0
  movss  %xmm0,-0x38(%rbp)
  pxor   %xmm4,%xmm4
  cvtss2sd -0x28(%rbp),%xmm4
  movsd  %xmm4,-0x68(%rbp)
  pxor   %xmm1,%xmm1
  cvtsi2sdl -0x40(%rbp),%xmm1
  movsd  D26(%rip),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  D49(%rip),%xmm1
  divsd  %xmm1,%xmm0
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  call   <sin@plt>
  mulsd  -0x68(%rbp),%xmm0
  cvtsd2ss %xmm0,%xmm0
  movss  %xmm0,-0x3c(%rbp)
  mov    $0x0,%eax
  call   <swapbuffers@plt>
  mov    $0x0,%eax
  call   <qtest@plt>
  test   %eax,%eax
  je     L62
  mov    $0x0,%eax
  call   <gexit@plt>
  mov    $0x0,%edi
  call   <exit@plt>
L62:
  mov    -0x2c(%rbp),%eax
  add    %eax,-0x40(%rbp)
L60:
  cmpl   $0xe0f,-0x40(%rbp)
  jle    L48
  jmp    L5
```

tool_calls: name: read_data
arguments: tag: D11
type_guessed: f32
name: read_data
arguments: tag: D121
type_guessed: f32
name: read_data
arguments: tag: D32
type_guessed: string
name: read_data
arguments: tag: D123
type_guessed: string
name: read_data
arguments: tag: D53
type_guessed: string
name: read_data
arguments: tag: D98
type_guessed: f64
name: read_data
arguments: tag: D169
type_guessed: f64
name: read_data
arguments: tag: D25
type_guessed: f64
name: read_data
arguments: tag: D151
type_guessed: f64
name: read_data
arguments: tag: D115
type_guessed: f64
name: read_data
arguments: tag: D26
type_guessed: f64
name: read_data
arguments: tag: D49
type_guessed: byte[8]

tool: D11: 1.6

tool: D121: 5

tool: D32: -b

tool: D123: -f

tool: D53: tetra

tool: D98: 15

tool: D169: 0.001

tool: D25: 1

tool: D151: 0

tool: D115: 0.4

tool: D26: 3.1415926535

tool: {"D49": [0x00,0x00,0x00,0x00,0x00,0x80,0x66,0x40]}

assistant: ```c
main(argc, argv) int argc;
char **argv;
{
  char dev[20];
  int i, but;
  int rotval = 0, drotval = 2;
  float R = 1.6, tx = 0.0, tz = R, zeye = 5.0;
  int do_backface = 0;
  int do_fill = 0;
  short val;
  for (i = 1; i < argc; i++) {
    if (!strcmp(argv[i], "-b"))
      do_backface = 1;
    if (!strcmp(argv[i], "-f"))
      do_fill = 1;
  }
  prefsize(400L, 400L);
  winopen("tetra");
  qdevice('\033');
  qdevice('Q');
  unqdevice(262);
  while (qread(&val) != 261)
    ;
  doublebuffer();
  gconfig();
  polymode(0);
  if (do_fill)
    polymode(1);
  if (do_backface)
    backface(1);
  perspective(400, 1.0, 0.001, 15.0);
  lookat(0.0, 0.0, zeye, 0.0, 0.0, 0.0, 0);
  maketetra();
  do {
    for (rotval = 0; rotval < 3600; rotval += drotval) {
      color(0);
      clear();
      rotate(drotval, 'x');
      rotate(drotval, 'z');
      color(1);
      pushmatrix();
      rotate(900, 'x');
      circ(0.0, 0.0, R);
      popmatrix();
      color(4);
      move(0.0, 0.0, 0.0);
      draw(tx, 0.0, tz);
      pushmatrix();
      translate(tx, 0.0, tz);
      rotate(rotval, 'x');
      rotate(rotval, 'y');
      rotate(rotval, 'z');
      scale(0.4, 0.4, 0.4);
      callobj(1L);
      popmatrix();
      tz = R * cos((double)(rotval * 3.1415926535 / 180));
      tx = R * sin((double)(rotval * 3.1415926535 / 180));
      swapbuffers();
      if (qtest()) {
        gexit();
        exit(0);
      }
    }
  } while (1);
}
```