user: Demonstrate the C code that generates the assembly output below:

```asm
<strtoimax>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x40,%rsp
  mov    %rdi,-0x28(%rbp)
  mov    %rsi,-0x30(%rbp)
  mov    %edx,-0x34(%rbp)
  mov    -0x28(%rbp),%rax
  mov    %rax,-0x8(%rbp)
L276:
  mov    -0x8(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x8(%rbp)
  movzbl (%rax),%eax
  mov    %al,-0x1d(%rbp)
  movzbl -0x1d(%rbp),%eax
  movzbl %al,%eax
  mov    %eax,%edi
  call   <isspace@plt>
  test   %rax,%rax
  jne    L276
  cmpb   $0x2d,-0x1d(%rbp)
  jne    L320
  movl   $0x1,-0x18(%rbp)
  mov    -0x8(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x8(%rbp)
  movzbl (%rax),%eax
  mov    %al,-0x1d(%rbp)
  jmp    L334
L320:
  movl   $0x0,-0x18(%rbp)
  cmpb   $0x2b,-0x1d(%rbp)
  jne    L334
  mov    -0x8(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x8(%rbp)
  movzbl (%rax),%eax
  mov    %al,-0x1d(%rbp)
L334:
  cmpl   $0x0,-0x34(%rbp)
  je     L83
  cmpl   $0x10,-0x34(%rbp)
  jne    L377
L83:
  cmpb   $0x30,-0x1d(%rbp)
  jne    L377
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x78,%al
  je     L410
  mov    -0x8(%rbp),%rax
  movzbl (%rax),%eax
  cmp    $0x58,%al
  jne    L377
L410:
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  cmp    $0x2f,%al
  jle    L416
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  cmp    $0x39,%al
  jle    L154
L416:
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  cmp    $0x40,%al
  jle    L125
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  cmp    $0x46,%al
  jle    L154
L125:
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  cmp    $0x60,%al
  jle    L377
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  cmp    $0x66,%al
  jg     L377
L154:
  mov    -0x8(%rbp),%rax
  add    $0x1,%rax
  movzbl (%rax),%eax
  mov    %al,-0x1d(%rbp)
  addq   $0x2,-0x8(%rbp)
  movl   $0x10,-0x34(%rbp)
L377:
  cmpl   $0x0,-0x34(%rbp)
  jne    L198
  cmpb   $0x30,-0x1d(%rbp)
  jne    L447
  mov    $0x8,%eax
  jmp    L136
L447:
  mov    $0xa,%eax
L136:
  mov    %eax,-0x34(%rbp)
L198:
  movl   $0x0,-0x14(%rbp)
  mov    -0x14(%rbp),%eax
  mov    %eax,-0x1c(%rbp)
  cmpl   $0x1,-0x34(%rbp)
  jle    L235
  cmpl   $0x24,-0x34(%rbp)
  jg     L235
  cmpl   $0x0,-0x18(%rbp)
  je     L227
  mov    D28(%rip),%rax
  mov    (%rax),%eax
  neg    %eax
  jmp    L404
L227:
  mov    D9(%rip),%rax
  mov    (%rax),%eax
L404:
  mov    %eax,-0x10(%rbp)
  mov    -0x10(%rbp),%eax
  cltd
  idivl  -0x34(%rbp)
  mov    %edx,-0xc(%rbp)
  mov    -0x10(%rbp),%eax
  cltd
  idivl  -0x34(%rbp)
  mov    %eax,-0x10(%rbp)
L122:
  cmpb   $0x2f,-0x1d(%rbp)
  jle    L77
  cmpb   $0x39,-0x1d(%rbp)
  jg     L77
  movzbl -0x1d(%rbp),%eax
  sub    $0x30,%eax
  mov    %al,-0x1d(%rbp)
  jmp    L223
L77:
  cmpb   $0x40,-0x1d(%rbp)
  jle    L381
  cmpb   $0x5a,-0x1d(%rbp)
  jg     L381
  movzbl -0x1d(%rbp),%eax
  sub    $0x37,%eax
  mov    %al,-0x1d(%rbp)
  jmp    L223
L381:
  cmpb   $0x60,-0x1d(%rbp)
  jle    L200
  cmpb   $0x7a,-0x1d(%rbp)
  jg     L200
  movzbl -0x1d(%rbp),%eax
  sub    $0x57,%eax
  mov    %al,-0x1d(%rbp)
L223:
  movsbl -0x1d(%rbp),%eax
  cmp    %eax,-0x34(%rbp)
  jle    L189
  cmpl   $0x0,-0x14(%rbp)
  js     L361
  mov    -0x1c(%rbp),%eax
  cmp    -0x10(%rbp),%eax
  jg     L361
  mov    -0x1c(%rbp),%eax
  cmp    -0x10(%rbp),%eax
  jne    L291
  movsbl -0x1d(%rbp),%eax
  cmp    %eax,-0xc(%rbp)
  jge    L291
L361:
  movl   $0xffffffff,-0x14(%rbp)
  jmp    L73
L291:
  movl   $0x1,-0x14(%rbp)
  mov    -0x1c(%rbp),%eax
  imul   -0x34(%rbp),%eax
  mov    %eax,-0x1c(%rbp)
  movsbl -0x1d(%rbp),%eax
  add    %eax,-0x1c(%rbp)
L73:
  mov    -0x8(%rbp),%rax
  lea    0x1(%rax),%rdx
  mov    %rdx,-0x8(%rbp)
  movzbl (%rax),%eax
  mov    %al,-0x1d(%rbp)
  jmp    L122
L189:
  nop
L200:
  cmpl   $0x0,-0x14(%rbp)
  jns    L70
  cmpl   $0x0,-0x18(%rbp)
  je     L98
  mov    D28(%rip),%rax
  mov    (%rax),%eax
  jmp    L296
L98:
  mov    D9(%rip),%rax
  mov    (%rax),%eax
L296:
  mov    %eax,-0x1c(%rbp)
  mov    D79(%rip),%rax
  mov    (%rax),%edx
  mov    D16(%rip),%rax
  mov    %edx,(%rax)
  jmp    L166
L70:
  cmpl   $0x0,-0x14(%rbp)
  jne    L263
  jmp    L429
L235:
  nop
L429:
  mov    D52(%rip),%rax
  mov    (%rax),%edx
  mov    D16(%rip),%rax
  mov    %edx,(%rax)
  jmp    L166
L263:
  cmpl   $0x0,-0x18(%rbp)
  je     L166
  negl   -0x1c(%rbp)
L166:
  cmpq   $0x0,-0x30(%rbp)
  je     L8
  cmpl   $0x0,-0x14(%rbp)
  je     L397
  mov    -0x8(%rbp),%rax
  sub    $0x1,%rax
  jmp    L470
L397:
  mov    -0x28(%rbp),%rax
L470:
  mov    -0x30(%rbp),%rdx
  mov    %rax,(%rdx)
L8:
  mov    -0x1c(%rbp),%eax
  leave
  ret
```

assistant: ```c
intmax_t strtoimax(const char *__restrict nptr, char **__restrict endptr, int base) {
  const char *s;
  uintmax_t acc;
  char c;
  uintmax_t cutoff;
  int neg, any, cutlim;
  s = nptr;
  do {
    c = *s++;
  } while (isspace((unsigned char)c));
  if (c == '-') {
    neg = 1;
    c = *s++;
  } else {
    neg = 0;
    if (c == '+')
      c = *s++;
  }
  if ((base == 0 || base == 16) && c == '0' && (*s == 'x' || *s == 'X') && ((s[1] >= '0' && s[1] <= '9') || (s[1] >= 'A' && s[1] <= 'F') || (s[1] >= 'a' && s[1] <= 'f'))) {
    c = s[1];
    s += 2;
    base = 16;
  }
  if (base == 0)
    base = c == '0' ? 8 : 10;
  acc = any = 0;
  if (base < 2 || base > 36)
    goto noconv;
  cutoff = neg ? (uintmax_t) - (INTMAX_MIN + INTMAX_MAX) + INTMAX_MAX : INTMAX_MAX;
  cutlim = cutoff % base;
  cutoff /= base;
  for (;; c = *s++) {
    if (c >= '0' && c <= '9')
      c -= '0';
    else if (c >= 'A' && c <= 'Z')
      c -= 'A' - 10;
    else if (c >= 'a' && c <= 'z')
      c -= 'a' - 10;
    else
      break;
    if (c >= base)
      break;
    if (any < 0 || acc > cutoff || (acc == cutoff && c > cutlim))
      any = -1;
    else {
      any = 1;
      acc *= base;
      acc += c;
    }
  }
  if (any < 0) {
    acc = neg ? INTMAX_MIN : INTMAX_MAX;
    errno = ERANGE;
  } else if (!any) {
  noconv:
    errno = EINVAL;
  } else if (neg)
    acc = -acc;
  if (endptr != NULL)
    *endptr = (char *)(any ? s - 1 : nptr);
  return (acc);
}
```