user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<append>:
  endbr64
  mov    %rdi,%rcx
  mov    %rsi,%rdx
  xor    %eax,%eax
  jmp    L42
  xchg   %ax,%ax
L161:
  add    $0x1,%rax
  cmp    $0x20,%rax
  je     L132
L42:
  cmpb   $0x0,(%rcx,%rax,1)
  movslq %eax,%rsi
  jne    L161
L11:
  xor    %eax,%eax
  jmp    L130
  nopl   0x0(%rax,%rax,1)
L216:
  add    $0x1,%rax
  cmp    $0x20,%rax
  je     L39
L130:
  cmpb   $0x0,(%rdx,%rax,1)
  mov    %eax,%edi
  jne    L216
  lea    (%rsi,%rax,1),%r11d
  cmp    $0x20,%r11d
  jg     L137
  test   %eax,%eax
  je     L25
L236:
  movslq %esi,%r9
  lea    0x1(%rdx),%r8
  add    %rcx,%r9
  mov    %r9,%rax
  sub    %r8,%rax
  cmp    $0xe,%rax
  jbe    L66
  cmp    $0x7,%edi
  jle    L66
  test   %edi,%edi
  mov    $0x1,%r8d
  cmovg  %edi,%r8d
  cmp    $0xf,%edi
  jle    L28
  movdqu (%rdx),%xmm1
  mov    %r8d,%eax
  shr    $0x4,%eax
  movups %xmm1,(%r9)
  cmp    $0x2,%eax
  je     L8
  cmp    $0x10,%r8d
  je     L211
  mov    $0x10,%r10d
  mov    $0x10,%eax
L77:
  sub    %r10d,%r8d
  push   %rbx
  lea    -0x1(%r8),%ebx
  cmp    $0x6,%ebx
  jbe    L133
  movq   (%rdx,%r10,1),%xmm0
  movq   %xmm0,(%r9,%r10,1)
  mov    %r8d,%r9d
  and    $0xfffffff8,%r9d
  add    %r9d,%eax
  cmp    %r9d,%r8d
  je     L91
L133:
  movslq %eax,%r8
  movzbl (%rdx,%r8,1),%r9d
  lea    (%rsi,%rax,1),%r8d
  movslq %r8d,%r8
  mov    %r9b,(%rcx,%r8,1)
  lea    0x1(%rax),%r8d
  cmp    %r8d,%edi
  jle    L91
  movslq %r8d,%r9
  add    %esi,%r8d
  movzbl (%rdx,%r9,1),%r9d
  movslq %r8d,%r8
  mov    %r9b,(%rcx,%r8,1)
  lea    0x2(%rax),%r8d
  cmp    %r8d,%edi
  jle    L91
  movslq %r8d,%r9
  add    %esi,%r8d
  movzbl (%rdx,%r9,1),%r9d
  movslq %r8d,%r8
  mov    %r9b,(%rcx,%r8,1)
  lea    0x3(%rax),%r8d
  cmp    %r8d,%edi
  jle    L91
  movslq %r8d,%r9
  add    %esi,%r8d
  movzbl (%rdx,%r9,1),%r9d
  movslq %r8d,%r8
  mov    %r9b,(%rcx,%r8,1)
  lea    0x4(%rax),%r8d
  cmp    %r8d,%edi
  jle    L91
  movslq %r8d,%r9
  add    %esi,%r8d
  movzbl (%rdx,%r9,1),%r9d
  movslq %r8d,%r8
  mov    %r9b,(%rcx,%r8,1)
  lea    0x5(%rax),%r8d
  cmp    %r8d,%edi
  jle    L91
  movslq %r8d,%r9
  add    %esi,%r8d
  add    $0x6,%eax
  movzbl (%rdx,%r9,1),%r9d
  movslq %r8d,%r8
  mov    %r9b,(%rcx,%r8,1)
  cmp    %eax,%edi
  jle    L91
  movslq %eax,%rdi
  add    %esi,%eax
  movzbl (%rdx,%rdi,1),%edx
  cltq
  mov    %dl,(%rcx,%rax,1)
L91:
  movslq %r11d,%rsi
  pop    %rbx
  movb   $0x0,(%rcx,%rsi,1)
  ret
  nopl   0x0(%rax,%rax,1)
L39:
  test   %esi,%esi
  jne    L172
  mov    $0x20,%edi
  mov    $0x20,%r11d
  jmp    L236
  nopl   0x0(%rax)
L132:
  mov    $0x20,%esi
  jmp    L11
  nopw   0x0(%rax,%rax,1)
L172:
  ret
  nopl   0x0(%rax)
L8:
  movdqu 0x10(%rdx),%xmm2
  movups %xmm2,0x10(%r9)
L211:
  movslq %r11d,%rsi
L25:
  movb   $0x0,(%rcx,%rsi,1)
L137:
  ret
  nopw   0x0(%rax,%rax,1)
L66:
  xor    %eax,%eax
  nopw   0x0(%rax,%rax,1)
L143:
  movzbl (%rdx,%rax,1),%esi
  mov    %sil,(%r9,%rax,1)
  add    $0x1,%rax
  cmp    %eax,%edi
  jg     L143
  jmp    L211
L28:
  xor    %r10d,%r10d
  xor    %eax,%eax
  jmp    L77
```

assistant: ```c
void append(char *o, char *p) {
  int i, j, k;
  for (i = 0; i < 32; i++)
    if (o[i] == '\0')
      break;
  for (j = 0; j < 32; j++)
    if (p[j] == '\0')
      break;
  if (i + j <= 32) {
    for (k = 0; k < j; k++)
      o[i + k] = p[k];
    o[i + k] = '\0';
  }
}
```