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

```asm
<namegen>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x258,%rsp
  mov    %rdi,0x38(%rsp)
  mov    %rcx,0x30(%rsp)
  mov    %fs:0x28,%rax
  mov    %rax,0x248(%rsp)
  xor    %eax,%eax
  add    %rdi,%rsi
  mov    %rsi,0x28(%rsp)
  movq   $0x1,0x140(%rsp)
  mov    %rdi,0x40(%rsp)
  movzbl (%rdx),%eax
  test   %al,%al
  je     L230
  mov    %rdx,%rbp
  mov    %rdi,0x18(%rsp)
  movq   $0x0,0x8(%rsp)
  mov    $0x0,%r15d
  mov    $0x0,%r12d
  movl   $0x0,0x14(%rsp)
  mov    $0x0,%ebx
  mov    $0x1,%r14d
  lea    D0(%rip),%r13
  jmp    L286
L265:
  cmp    $0x7c,%al
  jne    L290
  mov    %r14,%rax
  mov    %ebx,%ecx
  shl    %cl,%rax
  mov    %rax,0x20(%rsp)
  shr    %rax
  test   %r12,%rax
  jne    L169
  mov    0x30(%rsp),%rdi
  call   <namegen_rand32@plt>
  movslq %ebx,%rdx
  mov    0x140(%rsp,%rdx,8),%rsi
  lea    0x1(%rsi),%rcx
  mov    %rcx,0x140(%rsp,%rdx,8)
  movslq %eax,%rsi
  mov    $0xffffffff,%eax
  mov    $0x0,%edx
  div    %rcx
  cmp    %rax,%rsi
  jae    L223
  movslq %ebx,%rax
  mov    0x40(%rsp,%rax,8),%rax
  mov    %rax,0x18(%rsp)
  mov    0x20(%rsp),%rsi
  mov    %rsi,%rax
  not    %rax
  and    %rax,%r12
  mov    0x8(%rsp),%rax
  test   %rax,%rsi
  setne  %al
  movzbl %al,%eax
  mov    %eax,0x14(%rsp)
  jmp    L169
  add    $0x1,%ebx
  cmp    $0x20,%ebx
  je     L371
  mov    %r14,%rax
  mov    %ebx,%ecx
  shl    %cl,%rax
  mov    %rax,%rcx
  movslq %ebx,%rax
  movq   $0x1,0x140(%rsp,%rax,8)
  mov    0x18(%rsp),%rsi
  mov    %rsi,0x40(%rsp,%rax,8)
  mov    %rcx,%rax
  not    %rax
  and    %rax,%r15
  and    %rax,%r12
  lea    (%r12,%r12,1),%rdx
  and    %rcx,%rdx
  or     %rdx,%r12
  and    0x8(%rsp),%rax
  movslq 0x14(%rsp),%rdx
  mov    %ebx,%ecx
  shl    %cl,%rdx
  or     %rax,%rdx
  mov    %rdx,0x8(%rsp)
L169:
  add    $0x1,%rbp
  movzbl 0x0(%rbp),%eax
  test   %al,%al
  je     L205
L286:
  cmp    $0x3e,%al
  jg     L265
  cmp    $0x20,%al
  jle    L290
  lea    -0x21(%rax),%edx
  cmp    $0x1d,%dl
  ja     L290
  movzbl %dl,%edx
  movslq 0x0(%r13,%rdx,4),%rdx
  add    %r13,%rdx
  notrack jmp *%rdx
L371:
  mov    0x38(%rsp),%rax
  movb   $0x0,(%rax)
  mov    $0x3,%eax
  jmp    L4
  add    $0x1,%ebx
  cmp    $0x20,%ebx
  je     L75
  mov    %r14,%rax
  mov    %ebx,%ecx
  shl    %cl,%rax
  mov    %rax,%rcx
  movslq %ebx,%rax
  movq   $0x1,0x140(%rsp,%rax,8)
  mov    0x18(%rsp),%rsi
  mov    %rsi,0x40(%rsp,%rax,8)
  or     %rcx,%r15
  mov    %rcx,%rax
  not    %rax
  and    %rax,%r12
  lea    (%r12,%r12,1),%rdx
  and    %rcx,%rdx
  or     %rdx,%r12
  and    0x8(%rsp),%rax
  movslq 0x14(%rsp),%rdx
  mov    %ebx,%ecx
  shl    %cl,%rdx
  or     %rax,%rdx
  mov    %rdx,0x8(%rsp)
  jmp    L169
L75:
  mov    0x38(%rsp),%rax
  movb   $0x0,(%rax)
  mov    $0x3,%eax
  jmp    L4
  test   %ebx,%ebx
  je     L67
  lea    -0x1(%rbx),%edx
  mov    %r14,%rax
  mov    %ebx,%ecx
  shl    %cl,%rax
  test   %r15,%rax
  jne    L270
  mov    %edx,%ebx
  jmp    L169
L67:
  mov    0x38(%rsp),%rax
  movb   $0x0,(%rax)
  mov    $0x2,%eax
  jmp    L4
L270:
  mov    0x38(%rsp),%rax
  movb   $0x0,(%rax)
  mov    $0x2,%eax
  jmp    L4
  test   %ebx,%ebx
  je     L337
  lea    -0x1(%rbx),%edx
  mov    %r14,%rax
  mov    %ebx,%ecx
  shl    %cl,%rax
  test   %r15,%rax
  je     L343
  mov    %edx,%ebx
  jmp    L169
L337:
  mov    0x38(%rsp),%rax
  movb   $0x0,(%rax)
  mov    $0x2,%eax
  jmp    L4
L343:
  mov    0x38(%rsp),%rax
  movb   $0x0,(%rax)
  mov    $0x2,%eax
  jmp    L4
L223:
  or     0x20(%rsp),%r12
  jmp    L169
L290:
  mov    %r14,%rdx
  mov    %ebx,%ecx
  shl    %cl,%rdx
  test   %r12,%rdx
  jne    L35
  movsbl %al,%edi
  test   %r15,%rdx
  je     L173
  mov    0x18(%rsp),%rax
  cmp    %rax,0x28(%rsp)
  je     L54
  mov    0x14(%rsp),%esi
  call   <namegen_cap@plt>
  mov    0x18(%rsp),%rsi
  mov    %al,(%rsi)
  lea    0x1(%rsi),%rax
  mov    %rax,0x18(%rsp)
  movl   $0x0,0x14(%rsp)
  jmp    L169
L173:
  mov    0x14(%rsp),%r8d
  mov    0x30(%rsp),%rcx
  mov    %edi,%edx
  mov    0x28(%rsp),%rsi
  mov    0x18(%rsp),%rdi
  call   <namegen_copy@plt>
  mov    %rax,0x18(%rsp)
  movl   $0x0,0x14(%rsp)
  jmp    L169
  movl   $0x1,0x14(%rsp)
  jmp    L169
L35:
  movl   $0x0,0x14(%rsp)
  jmp    L169
L54:
  movl   $0x0,0x14(%rsp)
  jmp    L169
L205:
  test   %ebx,%ebx
  jne    L266
L369:
  mov    0x28(%rsp),%rsi
  cmp    %rsi,0x18(%rsp)
  je     L289
  mov    0x18(%rsp),%rax
  movb   $0x0,(%rax)
  mov    $0x0,%eax
L4:
  mov    0x248(%rsp),%rdx
  sub    %fs:0x28,%rdx
  jne    L17
  add    $0x258,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L266:
  mov    0x38(%rsp),%rax
  movb   $0x0,(%rax)
  mov    $0x2,%eax
  jmp    L4
L230:
  mov    0x38(%rsp),%rax
  mov    %rax,0x18(%rsp)
  jmp    L369
L289:
  movb   $0x0,-0x1(%rsi)
  mov    $0x1,%eax
  jmp    L4
L17:
  call   <__stack_chk_fail@plt>
```

assistant: ```c
int namegen(char *dst, unsigned long len, const char *pattern, unsigned long *seed) {
  int depth = 0;
  char *p = dst;
  char *e = dst + len;
  int capitalize = 0;
  char *reset[32];
  unsigned long n[32];
  unsigned long silent = 0;
  unsigned long literal = 0;
  unsigned long capstack = 0;
  n[0] = 1;
  reset[0] = dst;
  for (; *pattern; pattern++) {
    unsigned long bit;
    int c = *pattern;
    switch (c) {
    case '<':
      if (++depth == 32) {
        *dst = 0;
        return 3;
      }
      bit = 1UL << depth;
      n[depth] = 1;
      reset[depth] = p;
      literal &= ~bit;
      silent &= ~bit;
      silent |= (silent << 1) & bit;
      capstack &= ~bit;
      capstack |= (unsigned long)capitalize << depth;
      break;
    case '(':
      if (++depth == 32) {
        *dst = 0;
        return 3;
      }
      bit = 1UL << depth;
      n[depth] = 1;
      reset[depth] = p;
      literal |= bit;
      silent &= ~bit;
      silent |= (silent << 1) & bit;
      capstack &= ~bit;
      capstack |= (unsigned long)capitalize << depth;
      break;
    case '>':
      if (depth == 0) {
        *dst = 0;
        return 2;
      }
      bit = 1UL << depth--;
      if (literal & bit) {
        *dst = 0;
        return 2;
      }
      break;
    case ')':
      if (depth == 0) {
        *dst = 0;
        return 2;
      }
      bit = 1UL << depth--;
      if (!(literal & bit)) {
        *dst = 0;
        return 2;
      }
      break;
    case '|':
      bit = 1UL << depth;
      if (!(silent & (bit >> 1))) {
        if (namegen_rand32(seed) < 0xffffffffUL / ++n[depth]) {
          p = reset[depth];
          silent &= ~bit;
          capitalize = !!(capstack & bit);
        } else {
          silent |= bit;
        }
      }
      break;
    case '!':
      capitalize = 1;
      break;
    default:
      bit = 1UL << depth;
      if (!(silent & bit)) {
        if (literal & bit) {
          if (p != e)
            *p++ = namegen_cap(c, capitalize);
        } else {
          p = namegen_copy(p, e, c, seed, capitalize);
        }
      }
      capitalize = 0;
    }
  }
  if (depth) {
    *dst = 0;
    return 2;
  } else if (p == e) {
    p[-1] = 0;
    return 1;
  } else {
    *p = 0;
    return 0;
  }
}
```