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

```asm
<main>:
  endbr64
  push   %r14
  lea    D25(%rip),%r14
  push   %r13
  lea    D15(%rip),%r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0xf0,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0xe8(%rsp)
  xor    %eax,%eax
  lea    0x10(%rsp),%r12
  mov    %r12,%rdi
  call   <getline2@plt>
  test   %rax,%rax
  je     L261
  nopw   0x0(%rax,%rax,1)
L155:
  xor    %ebp,%ebp
  lea    0x80(%rsp),%rbx
  nopw   0x0(%rax,%rax,1)
L166:
  mov    %ebp,%esi
  mov    %rbx,%rdx
  mov    %r12,%rdi
  call   <getop@plt>
  mov    %eax,%ebp
  cmp    $0xffffffff,%eax
  je     L123
  mov    %rbx,%rdi
  call   <isnumfmt@plt>
  test   %rax,%rax
  jne    L26
  cmpw   $0x2b,(%rbx)
  je     L11
  cmpw   $0x2a,(%rbx)
  je     L212
  cmpw   $0x2d,(%rbx)
  je     L24
  cmpw   $0x2f,(%rbx)
  je     L156
  cmpw   $0x25,(%rbx)
  je     L160
  cmpl   $0x776f70,(%rbx)
  je     L278
  cmpl   $0x707865,(%rbx)
  je     L270
  cmpl   $0x6e6973,(%rbx)
  je     L176
  mov    %rbx,%rsi
  mov    %r14,%rdi
  xor    %eax,%eax
  call   <printf@plt>
  jmp    L166
  nopl   0x0(%rax)
L26:
  mov    %rbx,%rdi
  call   <atof@plt>
  call   <push@plt>
  jmp    L166
  nopw   0x0(%rax,%rax,1)
L11:
  xor    %eax,%eax
  call   <pop@plt>
  xor    %eax,%eax
  movsd  %xmm0,0x8(%rsp)
  call   <pop@plt>
  addsd  0x8(%rsp),%xmm0
  call   <push@plt>
  jmp    L166
  nopl   0x0(%rax)
L212:
  xor    %eax,%eax
  call   <pop@plt>
  xor    %eax,%eax
  movsd  %xmm0,0x8(%rsp)
  call   <pop@plt>
  mulsd  0x8(%rsp),%xmm0
  call   <push@plt>
  jmp    L166
  nopl   0x0(%rax)
L123:
  xor    %eax,%eax
  call   <gettop@plt>
  lea    D21(%rip),%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  xor    %eax,%eax
  call   <clearstack@plt>
  mov    %r12,%rdi
  call   <getline2@plt>
  test   %rax,%rax
  jne    L155
L261:
  mov    0xe8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L152
  add    $0xf0,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
  nopl   0x0(%rax)
L24:
  xor    %eax,%eax
  call   <swap@plt>
  xor    %eax,%eax
  call   <pop@plt>
  xor    %eax,%eax
  movsd  %xmm0,0x8(%rsp)
  call   <pop@plt>
  movsd  0x8(%rsp),%xmm1
  subsd  %xmm0,%xmm1
  movapd %xmm1,%xmm0
  call   <push@plt>
  jmp    L166
  nopl   0x0(%rax,%rax,1)
L156:
  xor    %eax,%eax
  call   <pop@plt>
  pxor   %xmm5,%xmm5
  pxor   %xmm2,%xmm2
  ucomisd %xmm5,%xmm0
  movapd %xmm0,%xmm1
  jp     L86
  je     L225
L86:
  xor    %eax,%eax
  movsd  %xmm1,0x8(%rsp)
  call   <pop@plt>
  movsd  0x8(%rsp),%xmm1
  divsd  %xmm1,%xmm0
  call   <push@plt>
  jmp    L166
  nopl   0x0(%rax)
L225:
  xor    %eax,%eax
  movsd  %xmm2,0x8(%rsp)
  call   <pop@plt>
  movsd  0x8(%rsp),%xmm2
  movapd %xmm2,%xmm0
  call   <push@plt>
  mov    %r13,%rdi
  call   <puts@plt>
  jmp    L166
  nopl   0x0(%rax)
L160:
  xor    %eax,%eax
  call   <pop@plt>
  pxor   %xmm6,%xmm6
  pxor   %xmm2,%xmm2
  ucomisd %xmm6,%xmm0
  movapd %xmm0,%xmm1
  jp     L70
  je     L225
L70:
  xor    %eax,%eax
  movsd  %xmm1,0x8(%rsp)
  call   <pop@plt>
  movsd  0x8(%rsp),%xmm1
  cvttsd2si %xmm0,%eax
  pxor   %xmm0,%xmm0
  cvttsd2si %xmm1,%ecx
  cltd
  idiv   %ecx
  cvtsi2sd %edx,%xmm0
  call   <push@plt>
  jmp    L166
  nopl   0x0(%rax,%rax,1)
L278:
  xor    %eax,%eax
  call   <pop@plt>
  xor    %eax,%eax
  movsd  %xmm0,0x8(%rsp)
  call   <pop@plt>
  movsd  0x8(%rsp),%xmm1
  call   <pow@plt>
  call   <push@plt>
  jmp    L166
  nopl   0x0(%rax)
L270:
  xor    %eax,%eax
  call   <pop@plt>
  call   <exp@plt>
  call   <push@plt>
  jmp    L166
  cs nopw 0x0(%rax,%rax,1)
L176:
  xor    %eax,%eax
  call   <pop@plt>
  call   <sin@plt>
  call   <push@plt>
  jmp    L166
L152:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: data_tag: D25
type_infered: string
name: extract_symbolic_data
arguments: data_tag: D15
type_infered: string
name: extract_symbolic_data
arguments: data_tag: D21
type_infered: string

tool: D25: Error: unknown token %s


tool: D15: Error: divisor is 0

tool: D21: result: %g


assistant: ```c
int main(int argc, char *argv[]) {
  char line[100];
  char t[100];
  double tmp;
  while (getline2(line)) {
    int start = 0;
    while ((start = getop(line, start, t)) != -1) {
      if (isnumfmt(t)) {
        push(atof(t));
      } else if (!strcmp(t, "+")) {
        push(pop() + pop());
      } else if (!strcmp(t, "*")) {
        push(pop() * pop());
      } else if (!strcmp(t, "-")) {
        swap();
        push(pop() - pop());
      } else if (!strcmp(t, "/")) {
        tmp = pop();
        if (tmp != 0) {
          push(pop() / tmp);
        } else {
          pop();
          push(0.0);
          printf("Error: divisor is 0\n");
        }
      } else if (!strcmp(t, "%")) {
        tmp = pop();
        if (tmp != 0) {
          push((int)pop() % (int)tmp);
        } else {
          pop();
          push(0.0);
          printf("Error: divisor is 0\n");
        }
      } else if (!strcmp(t, "pow")) {
        double tmp = pop();
        push(pow(pop(), tmp));
      } else if (!strcmp(t, "exp")) {
        push(exp(pop()));
      } else if (!strcmp(t, "sin")) {
        push(sin(pop()));
      } else {
        printf("Error: unknown token %s\n", t);
      }
    }
    printf("result: %g\n", gettop());
    clearstack();
  }
  return 0;
}
```