user: What would the C source look like for the assembly code provided here?

```asm
<rrpgebranch>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  mov    %edx,%r12d
  push   %rbp
  push   %rbx
  sub    $0x18,%rsp
  sub    %esi,%edx
  je     L82
  mov    %esi,%eax
  mov    %rdi,%rbp
  mov    %esi,%r13d
  mov    %ecx,%r15d
  lea    (%rdi,%rax,4),%rax
  mov    %rax,(%rsp)
L91:
  mov    $0x1,%ebx
  mov    %r15d,%ecx
  mov    $0x1,%eax
  shl    %cl,%ebx
  cmp    %edx,%ebx
  jbe    L80
  nopl   0x0(%rax,%rax,1)
L7:
  sub    $0x1,%r15d
  mov    %eax,%ebx
  mov    %r15d,%ecx
  shl    %cl,%ebx
  cmp    %edx,%ebx
  ja     L7
L80:
  add    %r13d,%ebx
  lea    -0x1(%r12),%eax
  cmp    %r12d,%ebx
  cmove  %eax,%ebx
  test   %r8d,%r8d
  je     L63
  mov    %r12d,%eax
  mov    %edx,0xc(%rsp)
  mov    0x0(%rbp,%rax,4),%esi
  cmp    $0x7fffe,%esi
  ja     L23
  shr    $0x7,%esi
  lea    D51(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  mov    0xc(%rsp),%edx
L63:
  cmp    $0x1,%edx
  je     L85
L18:
  mov    %ebx,%eax
  lea    D64(%rip),%rdi
  lea    0x0(%rbp,%rax,4),%r14
  xor    %eax,%eax
  mov    (%r14),%esi
  shr    $0x3,%esi
  call   <printf@plt>
  mov    %r12d,%eax
  mov    0x0(%rbp,%rax,4),%edx
  cmp    $0x7fffe,%edx
  ja     L1
  mov    (%r14),%esi
  shr    $0x3,%edx
  lea    D39(%rip),%rdi
  xor    %eax,%eax
  shr    $0x3,%esi
  call   <printf@plt>
L38:
  mov    (%r14),%esi
  lea    D16(%rip),%rdi
  xor    %eax,%eax
  shr    $0x7,%esi
  call   <printf@plt>
  mov    (%rsp),%rax
  mov    (%rax),%esi
  test   %esi,%esi
  je     L61
  mov    (%r14),%edx
  shr    $0x3,%esi
  lea    D39(%rip),%rdi
  xor    %eax,%eax
  shr    $0x3,%edx
  call   <printf@plt>
L86:
  cmp    $0x1,%r15d
  mov    %r12d,%edx
  mov    %ebx,%esi
  mov    %rbp,%rdi
  adc    $0xffffffff,%r15d
  xor    %r8d,%r8d
  mov    %r15d,%ecx
  call   <rrpgebranch>
  mov    %ebx,%edx
  mov    $0x1,%r8d
  sub    %r13d,%edx
  je     L82
  mov    %ebx,%r12d
  jmp    L91
  nopl   (%rax)
L1:
  mov    (%r14),%esi
  lea    D58(%rip),%rdi
  xor    %eax,%eax
  shr    $0x3,%esi
  call   <printf@plt>
  jmp    L38
  nopl   0x0(%rax)
L61:
  mov    (%r14),%esi
  lea    D98(%rip),%rdi
  xor    %eax,%eax
  shr    $0x3,%esi
  call   <printf@plt>
  jmp    L86
  cs nopw 0x0(%rax,%rax,1)
L23:
  lea    D62(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  mov    0xc(%rsp),%edx
  cmp    $0x1,%edx
  jne    L18
L85:
  lea    0x1(%rbx),%eax
  lea    D104(%rip),%rdi
  mov    0x0(%rbp,%rax,4),%eax
  cmp    $0x7fffe,%eax
  ja     L93
  mov    %eax,%ecx
  xor    %edx,%edx
  lea    D28(%rip),%rdi
  movabs $0x100000000,%rax
  div    %rcx
  mov    %eax,%esi
  xor    %eax,%eax
  shr    $0x2,%esi
  call   <printf@plt>
  lea    D99(%rip),%rdi
  jmp    L93
  nopl   (%rax)
L82:
  lea    D110(%rip),%rdi
L93:
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    1060 <puts@plt>
```

tool_calls: name: unpack_data
arguments: tag: D51
type_guessed: string
name: unpack_data
arguments: tag: D64
type_guessed: string
name: unpack_data
arguments: tag: D39
type_guessed: string
name: unpack_data
arguments: tag: D16
type_guessed: string
name: unpack_data
arguments: tag: D58
type_guessed: string
name: unpack_data
arguments: tag: D98
type_guessed: string
name: unpack_data
arguments: tag: D62
type_guessed: string
name: unpack_data
arguments: tag: D104
type_guessed: string
name: unpack_data
arguments: tag: D28
type_guessed: string
name: unpack_data
arguments: tag: D99
type_guessed: string
name: unpack_data
arguments: tag: D110
type_guessed: string

tool: D51: .x%03x:

tool: D64: 	xug x3,    0x%04X

tool: D39: 	; 0x%04X < x3 <= 0x%04X


tool: D16: 	jms .x%03x	

tool: D58: 	; 0x%04X < x3


tool: D98: 	;          x3 <= 0x%04X


tool: D62: .xfff:

tool: D104: 	jms .xdiv		; Do approximation with division

tool: D28: 	mov x1,    0x%04X


tool: D99: 	jms .xend

tool: D110: Branch: Error!

assistant: ```c
void rrpgebranch(unsigned int const *ca, unsigned int b, unsigned int h, unsigned int d, unsigned int e) {
  unsigned int w = h - b;
  unsigned int s;
  unsigned int t;
  if (w == 0U) {
    printf("Branch: Error!\n");
    return;
  }
  while ((1U << d) > w) {
    d--;
  }
  s = b + (1U << d);
  if (s == h) {
    s--;
  }
  if (e) {
    if (ca[h] < 0x7FFFFU) {
      printf(".x%03x:", (ca[h] >> 7));
    } else {
      printf(".xfff:");
    }
  }
  if (w == 1U) {
    if (ca[s + 1U] < 0x7FFFFU) {
      t = (unsigned)(0x100000000ULL / ca[s + 1U]) >> 2;
      printf("\tmov x1,    0x%04X\n", t);
      printf("\tjms .xend\n");
    } else {
      printf("\tjms .xdiv\t\t; Do approximation with division\n");
    }
  } else {
    printf("\txug x3,    0x%04X", ca[s] >> 3);
    if (ca[h] < 0x7FFFFU) {
      printf("\t; 0x%04X < x3 <= 0x%04X\n", ca[s] >> 3, ca[h] >> 3);
    } else {
      printf("\t; 0x%04X < x3\n", ca[s] >> 3);
    }
    printf("\tjms .x%03x\t", ca[s] >> 7);
    if (ca[b] != 0U) {
      printf("\t; 0x%04X < x3 <= 0x%04X\n", ca[b] >> 3, ca[s] >> 3);
    } else {
      printf("\t;          x3 <= 0x%04X\n", ca[s] >> 3);
    }
    if (d != 0U) {
      d--;
    }
    rrpgebranch(ca, s, h, d, 0U);
    rrpgebranch(ca, b, s, d, 1U);
  }
}
```