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

```asm
<btea>:
  endbr64
  mov    %rsi,%r10
  push   %r15
  mov    %rdi,%r9
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  mov    %rdx,%rbx
  mov    (%rdi),%rsi
  cmp    $0x1,%r10
  jg     L38
  mov    $0x1,%eax
  cmp    $0xffffffffffffffff,%r10
  jl     L57
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopw   0x0(%rax,%rax,1)
L38:
  mov    $0x34,%eax
  lea    -0x8(%rdi,%r10,8),%r12
  lea    -0x1(%r10),%rbp
  xor    %r11d,%r11d
  cqto
  mov    $0x9e3779b9,%r14d
  mov    (%r12),%rcx
  idiv   %r10
  movabs $0x3b54cda56,%rdx
  imul   %r14,%rax
  lea    (%rax,%rdx,1),%r13
  nopw   0x0(%rax,%rax,1)
L60:
  add    %r14,%r11
  xor    %edx,%edx
  mov    %r11,%r10
  shr    $0x2,%r10
  jmp    L58
  cs nopw 0x0(%rax,%rax,1)
L75:
  mov    (%r9,%rdx,8),%rsi
L58:
  mov    %r10,%rdi
  mov    0x8(%r9,%rdx,8),%rax
  mov    %r11,%r8
  xor    %rdx,%rdi
  and    $0x3,%edi
  xor    %rax,%r8
  mov    (%rbx,%rdi,8),%r15
  xor    %rcx,%r15
  mov    %r15,%rdi
  lea    0x0(,%rax,4),%r15
  shr    $0x3,%rax
  add    %r8,%rdi
  mov    %rcx,%r8
  shl    $0x4,%rcx
  shr    $0x5,%r8
  xor    %rcx,%rax
  xor    %r15,%r8
  add    %rax,%r8
  xor    %r8,%rdi
  lea    (%rdi,%rsi,1),%rcx
  mov    %rcx,(%r9,%rdx,8)
  add    $0x1,%rdx
  cmp    %rbp,%rdx
  jne    L75
  xor    %rbp,%r10
  mov    (%r9),%rax
  mov    %r11,%rdx
  and    $0x3,%r10d
  mov    (%rbx,%r10,8),%rsi
  xor    %rax,%rdx
  lea    0x0(,%rax,4),%rdi
  shr    $0x3,%rax
  xor    %rcx,%rsi
  add    %rdx,%rsi
  mov    %rcx,%rdx
  shl    $0x4,%rcx
  shr    $0x5,%rdx
  xor    %rcx,%rax
  xor    %rdi,%rdx
  add    %rdx,%rax
  xor    %rsi,%rax
  add    (%r12),%rax
  mov    %rax,(%r12)
  mov    %rax,%rcx
  cmp    %r13,%r11
  je     L2
  mov    (%r9),%rsi
  jmp    L60
L57:
  mov    %r10,%rcx
  mov    $0x34,%eax
  movabs $0xffffffff61c88647,%r11
  neg    %rcx
  cqto
  idiv   %rcx
  lea    0x6(%rax),%rdi
  mov    $0x9e3779b9,%eax
  imul   %rax,%rdi
  mov    %r10,%rax
  not    %rax
  lea    (%r9,%rax,8),%rbp
  mov    %rax,%r10
  cs nopw 0x0(%rax,%rax,1)
L8:
  mov    %rdi,%r8
  mov    %r10,%rax
  shr    $0x2,%r8
  nopw   0x0(%rax,%rax,1)
L76:
  mov    %r8,%rdx
  mov    -0x8(%r9,%rax,8),%rcx
  mov    %rsi,%r13
  xor    %rax,%rdx
  xor    %rdi,%r13
  and    $0x3,%edx
  mov    (%rbx,%rdx,8),%r14
  mov    %rcx,%rdx
  shr    $0x5,%rdx
  xor    %rcx,%r14
  shl    $0x4,%rcx
  lea    (%r14,%r13,1),%r12
  lea    0x0(,%rsi,4),%r13
  shr    $0x3,%rsi
  xor    %r13,%rdx
  xor    %rcx,%rsi
  add    %rdx,%rsi
  mov    %r12,%rdx
  xor    %rsi,%rdx
  mov    (%r9,%rax,8),%rsi
  sub    %rdx,%rsi
  mov    %rsi,(%r9,%rax,8)
  sub    $0x1,%rax
  jne    L76
  mov    0x0(%rbp),%rdx
  lea    0x0(,%rsi,4),%rcx
  and    $0x3,%r8d
  mov    %rdx,%rax
  mov    %rdx,%r12
  xor    (%rbx,%r8,8),%rdx
  shr    $0x5,%rax
  shl    $0x4,%r12
  xor    %rcx,%rax
  mov    %rsi,%rcx
  xor    %rdi,%rsi
  shr    $0x3,%rcx
  add    %rsi,%rdx
  mov    (%r9),%rsi
  xor    %r12,%rcx
  add    %rcx,%rax
  xor    %rdx,%rax
  sub    %rax,%rsi
  mov    %rsi,(%r9)
  add    %r11,%rdi
  jne    L8
L2:
  pop    %rbx
  xor    %eax,%eax
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

assistant: ```c
long btea(long *v, long length, long *key) {
  unsigned long z, y = v[0], sum = 0, e, DELTA = 0x9e3779b9;
  long p, q;
  if (length > 1) {
    z = v[length - 1];
    q = 6 + 52 / length;
    while (q-- > 0) {
      sum += DELTA;
      e = (sum >> 2) & 3;
      for (p = 0; p < length - 1; p++)
        y = v[p + 1], z = v[p] += ((((z >> 5) ^ (y << 2)) + ((y >> 3) ^ (z << 4))) ^ ((sum ^ y) + (key[(p & 3) ^ e] ^ z)));
      y = v[0];
      z = v[length - 1] += ((((z >> 5) ^ (y << 2)) + ((y >> 3) ^ (z << 4))) ^ ((sum ^ y) + (key[(p & 3) ^ e] ^ z)));
    }
    return 0;
  } else if (length < -1) {
    length = -length;
    q = 6 + 52 / length;
    sum = q * DELTA;
    while (sum != 0) {
      e = (sum >> 2) & 3;
      for (p = length - 1; p > 0; p--)
        z = v[p - 1], y = v[p] -= ((((z >> 5) ^ (y << 2)) + ((y >> 3) ^ (z << 4))) ^ ((sum ^ y) + (key[(p & 3) ^ e] ^ z)));
      z = v[length - 1];
      y = v[0] -= ((((z >> 5) ^ (y << 2)) + ((y >> 3) ^ (z << 4))) ^ ((sum ^ y) + (key[(p & 3) ^ e] ^ z)));
      sum -= DELTA;
    }
    return 0;
  }
  return 1;
}
```