user: Please show me the C implementation that matches the assembly code listed below:

```asm
<line>:
  endbr64
  push   %r15
  mov    %edi,%r11d
  mov    %esi,%eax
  mov    %r9d,%r15d
  push   %r14
  sub    %ecx,%eax
  sub    %edx,%r11d
  mov    %r8d,%r14d
  push   %r13
  push   %r12
  mov    %esi,%r12d
  push   %rbp
  mov    %edi,%ebp
  push   %rbx
  sub    $0x38,%rsp
  mov    %eax,0x4(%rsp)
  or     %r11d,%eax
  mov    0x70(%rsp),%r13d
  je     L111
  mov    %ecx,%ebx
  test   %r11d,%r11d
  je     L166
  mov    0x4(%rsp),%esi
  test   %esi,%esi
  jne    L241
  test   %r11d,%r11d
  js     L56
  mov    %edx,%ebx
  cmp    %edx,%edi
  jl     L66
  nopl   0x0(%rax,%rax,1)
L276:
  mov    %ebx,%edi
  mov    %r13d,%r8d
  mov    %r15d,%ecx
  mov    %r14d,%edx
  mov    %r12d,%esi
  add    $0x1,%ebx
  call   <dot1@plt>
  cmp    %ebx,%ebp
  jge    L276
L66:
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax)
L241:
  mov    %r12d,%edi
  mov    %edx,0x10(%rsp)
  mov    %r11d,0x8(%rsp)
  call   <abs@plt>
  cmp    $0x3e8,%rax
  jg     L66
  mov    %ebx,%edi
  call   <abs@plt>
  cmp    $0x3e8,%rax
  jg     L66
  mov    0x8(%rsp),%r11d
  movl   $0xffffffff,0x18(%rsp)
  mov    0x10(%rsp),%r10d
  test   %r11d,%r11d
  js     L120
L349:
  mov    0x4(%rsp),%ecx
  movl   $0xffffffff,0x10(%rsp)
  test   %ecx,%ecx
  js     L172
L117:
  mov    %r11d,%edi
  mov    %r10d,0x1c(%rsp)
  mov    %r11d,0x14(%rsp)
  call   <abs@plt>
  mov    0x4(%rsp),%edi
  mov    %rax,0x8(%rsp)
  call   <abs@plt>
  mov    0x14(%rsp),%r11d
  mov    0x1c(%rsp),%r10d
  cmp    %rax,0x8(%rsp)
  mov    %r10d,0x14(%rsp)
  mov    %r11d,0x8(%rsp)
  jge    L115
  mov    0x4(%rsp),%eax
  mov    %r13d,%r8d
  mov    %r15d,%ecx
  mov    %r12d,%esi
  mov    %ebp,%edi
  mov    %eax,%edx
  shr    $0x1f,%edx
  add    %edx,%eax
  and    $0x1,%eax
  sub    %edx,%eax
  mov    $0x2,%edx
  cmp    $0x1,%eax
  cmove  %eax,%edx
  mov    %edx,0x28(%rsp)
  mov    %r14d,%edx
  call   <dot1@plt>
  mov    0x14(%rsp),%edi
  mov    %r13d,%r8d
  mov    %r15d,%ecx
  mov    %r14d,%edx
  mov    %ebx,%esi
  call   <dot1@plt>
  mov    0x8(%rsp),%r11d
  mov    0x4(%rsp),%eax
  mov    0x28(%rsp),%edi
  lea    (%r11,%r11,1),%r9d
  mov    %r9d,0x24(%rsp)
  sub    %eax,%r9d
  cmp    %edi,%eax
  jle    L146
  sub    %eax,%r11d
  mov    %r13d,%r8d
  mov    %edi,0x8(%rsp)
  mov    %ebx,%r13d
  lea    (%r11,%r11,1),%eax
  mov    %r12d,0x2c(%rsp)
  mov    %r9d,%ebx
  mov    %eax,0x20(%rsp)
  mov    %r15d,%eax
  mov    %ebp,%r15d
  mov    %r14d,%ebp
  mov    %eax,%r14d
  jmp    L279
  nopl   0x0(%rax,%rax,1)
L97:
  mov    0x18(%rsp),%ecx
  sub    %ecx,0x14(%rsp)
  mov    0x10(%rsp),%esi
  add    0x20(%rsp),%ebx
  add    %ecx,%r15d
  add    %esi,%r12d
  sub    %esi,%r13d
L170:
  mov    %r14d,%ecx
  mov    %ebp,%edx
  mov    %r12d,%esi
  mov    %r15d,%edi
  mov    %r8d,0x1c(%rsp)
  call   <dot1@plt>
  mov    0x1c(%rsp),%r8d
  mov    0x14(%rsp),%edi
  mov    %ebp,%edx
  mov    %r14d,%ecx
  mov    %r13d,%esi
  call   <dot1@plt>
  addl   $0x2,0x8(%rsp)
  mov    0x8(%rsp),%eax
  cmp    %eax,0x4(%rsp)
  mov    0x1c(%rsp),%r8d
  jle    L136
L279:
  test   %ebx,%ebx
  jns    L97
  mov    0x10(%rsp),%eax
  add    0x24(%rsp),%ebx
  add    %eax,%r12d
  sub    %eax,%r13d
  jmp    L170
L166:
  mov    0x4(%rsp),%edi
  test   %edi,%edi
  jns    L52
  cmp    %ecx,%esi
  jg     L66
L219:
  mov    %r12d,%esi
  mov    %r13d,%r8d
  mov    %r15d,%ecx
  mov    %r14d,%edx
  mov    %ebp,%edi
  add    $0x1,%r12d
  call   <dot1@plt>
  cmp    %r12d,%ebx
  jge    L219
  jmp    L66
  nopl   0x0(%rax)
L100:
  mov    %ebx,%esi
  mov    %r13d,%r8d
  mov    %r15d,%ecx
  mov    %r14d,%edx
  mov    %ebp,%edi
  add    $0x1,%ebx
  call   <dot1@plt>
L52:
  cmp    %ebx,%r12d
  jge    L100
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax)
L111:
  mov    %r13d,%r8d
  mov    %r9d,%ecx
  mov    %r14d,%edx
L230:
  mov    %ebp,%edi
L339:
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    1070 <dot1@plt>
  cs nopw 0x0(%rax,%rax,1)
L56:
  cmp    %edx,%edi
  jg     L66
  mov    %edx,%ebx
  nopw   0x0(%rax,%rax,1)
L89:
  mov    %ebp,%edi
  mov    %r13d,%r8d
  mov    %r15d,%ecx
  mov    %r14d,%edx
  mov    %r12d,%esi
  add    $0x1,%ebp
  call   <dot1@plt>
  cmp    %ebp,%ebx
  jge    L89
  jmp    L66
  nop
L136:
  mov    %r14d,%eax
  mov    %ebp,%r14d
  mov    %r15d,%ebp
  mov    0x10(%rsp),%esi
  mov    %eax,%r15d
  mov    0x4(%rsp),%eax
  mov    0x2c(%rsp),%r12d
  mov    %ebx,%r9d
  mov    %r8d,%r13d
  sub    $0x1,%eax
  sub    0x28(%rsp),%eax
  add    %esi,%r12d
  shr    %eax
  imul   %esi,%eax
  add    %eax,%r12d
L146:
  testb  $0x1,0x4(%rsp)
  jne    L66
  mov    0x18(%rsp),%eax
  mov    0x10(%rsp),%esi
  mov    %r13d,%r8d
  mov    %r15d,%ecx
  mov    %r14d,%edx
  add    %ebp,%eax
  test   %r9d,%r9d
  cmovns %eax,%ebp
  add    %r12d,%esi
  jmp    L230
  nopl   (%rax)
L172:
  mov    %ebx,%eax
  movl   $0x1,0x10(%rsp)
  sub    %r12d,%eax
  mov    %eax,0x4(%rsp)
  jmp    L117
  cs nopw 0x0(%rax,%rax,1)
L120:
  mov    %r10d,%r11d
  movl   $0x1,0x18(%rsp)
  sub    %ebp,%r11d
  jmp    L349
  nopl   0x0(%rax,%rax,1)
L115:
  mov    %r13d,%r8d
  mov    %r15d,%ecx
  mov    %r14d,%edx
  mov    %r12d,%esi
  mov    %ebp,%edi
  call   <dot1@plt>
  mov    0x14(%rsp),%r10d
  mov    %r15d,%ecx
  mov    %r13d,%r8d
  mov    %r14d,%edx
  mov    %ebx,%esi
  mov    %r10d,%edi
  mov    %r10d,0x1c(%rsp)
  call   <dot1@plt>
  mov    0x4(%rsp),%ecx
  mov    0x8(%rsp),%r11d
  lea    (%rcx,%rcx,1),%eax
  mov    %eax,0x24(%rsp)
  sub    %r11d,%eax
  mov    %eax,0x8(%rsp)
  cmp    $0x2,%r11d
  jle    L246
  mov    %ecx,%eax
  mov    %r13d,%r8d
  mov    %ebp,0x28(%rsp)
  mov    %r12d,%r13d
  sub    %r11d,%eax
  mov    %r11d,0x14(%rsp)
  mov    0x1c(%rsp),%r12d
  add    %eax,%eax
  movl   $0x2,0x4(%rsp)
  mov    %eax,0x20(%rsp)
  mov    %r14d,%eax
  mov    %ebx,%r14d
  mov    %eax,%ebx
  jmp    L36
  nopw   0x0(%rax,%rax,1)
L40:
  mov    0x20(%rsp),%edx
  mov    0x10(%rsp),%edi
  add    %edx,%eax
  add    %edi,%r13d
  sub    %edi,%r14d
  mov    %eax,0x8(%rsp)
L267:
  mov    0x18(%rsp),%eax
  mov    %r15d,%ecx
  mov    %ebx,%edx
  mov    %r13d,%esi
  mov    %r8d,0x1c(%rsp)
  add    %eax,%ebp
  sub    %eax,%r12d
  mov    %ebp,%edi
  call   <dot1@plt>
  mov    0x1c(%rsp),%r8d
  mov    %r15d,%ecx
  mov    %ebx,%edx
  mov    %r14d,%esi
  mov    %r12d,%edi
  call   <dot1@plt>
  addl   $0x2,0x4(%rsp)
  mov    0x4(%rsp),%eax
  cmp    %eax,0x14(%rsp)
  mov    0x1c(%rsp),%r8d
  jle    L299
L36:
  mov    0x8(%rsp),%eax
  test   %eax,%eax
  jns    L40
  mov    0x24(%rsp),%ecx
  add    %ecx,0x8(%rsp)
  jmp    L267
  nopl   0x0(%rax)
L299:
  mov    0x14(%rsp),%r11d
  mov    0x18(%rsp),%edi
  mov    %r13d,%r12d
  mov    %ebx,%r14d
  mov    0x28(%rsp),%ebp
  mov    %r8d,%r13d
  lea    -0x3(%r11),%eax
  shr    %eax
  add    %edi,%ebp
  imul   %edi,%eax
  add    %eax,%ebp
L246:
  and    $0x1,%r11d
  jne    L66
  mov    0x8(%rsp),%edx
  mov    0x10(%rsp),%eax
  mov    %r13d,%r8d
  mov    %r15d,%ecx
  mov    0x18(%rsp),%edi
  add    %r12d,%eax
  test   %edx,%edx
  mov    %r14d,%edx
  cmovns %eax,%r12d
  add    %ebp,%edi
  mov    %r12d,%esi
  jmp    L339
```

assistant: ```c
void line(int x1, int y1, int x2, int y2, int r, int g, int b) {
  int dx, dy, p, s, st, n;
  dx = x1 - x2;
  dy = y1 - y2;
  if ((dx == 0) && (dy == 0)) {
    dot1(x1, y1, r, g, b);
    return;
  }
  if (dx == 0) {
    if (dy < 0) {
      for (p = y1; p <= y2; p++)
        dot1(x1, p, r, g, b);
    } else {
      for (p = y2; p <= y1; p++)
        dot1(x1, p, r, g, b);
    }
    return;
  }
  if (dy == 0) {
    if (dx < 0) {
      for (p = x1; p <= x2; p++)
        dot1(p, y1, r, g, b);
    } else {
      for (p = x2; p <= x1; p++)
        dot1(p, y1, r, g, b);
    }
    return;
  }
  if (abs(y1) > 1000)
    return;
  if (abs(y2) > 1000)
    return;
  if (dx < 0) {
    s = 1;
    dx = -dx;
  } else
    s = -1;
  if (dy < 0) {
    st = 1;
    dy = -dy;
  } else
    st = -1;
  if (abs(dx) >= abs(dy)) {
    if (dx % 2 == 1)
      n = 1;
    else
      n = 2;
    dot1(x1, y1, r, g, b);
    dot1(x2, y2, r, g, b);
    n = 2;
    p = 2 * dy - dx;
    while (n < dx) {
      if (p >= 0) {
        y1 = y1 + st;
        y2 = y2 - st;
        p = p + 2 * (dy - dx);
      } else
        p = p + 2 * dy;
      x1 = x1 + s;
      x2 = x2 - s;
      dot1(x1, y1, r, g, b);
      dot1(x2, y2, r, g, b);
      n = n + 2;
    }
    if (dx % 2 == 0) {
      if (p >= 0)
        y1 = y1 + st;
      x1 = x1 + s;
      dot1(x1, y1, r, g, b);
    }
  } else {
    if (dy % 2 == 1)
      n = 1;
    else
      n = 2;
    dot1(x1, y1, r, g, b);
    dot1(x2, y2, r, g, b);
    p = 2 * dx - dy;
    while (n < dy) {
      if (p >= 0) {
        x1 = x1 + s;
        x2 = x2 - s;
        p = p + 2 * (dx - dy);
      } else
        p = p + 2 * dx;
      y1 = y1 + st;
      y2 = y2 - st;
      dot1(x1, y1, r, g, b);
      dot1(x2, y2, r, g, b);
      n = n + 2;
    }
    if (dy % 2 == 0) {
      if (p >= 0)
        x1 = x1 + s;
      y1 = y1 + st;
      dot1(x1, y1, r, g, b);
    }
  }
}
```