user: 请显示与下面列出的汇编代码相匹配的C语言实现：

```asm
<AES_cfbr_encrypt_block>:
  endbr64
  push   %rbp
  mov    %rsi,%r10
  mov    %rcx,%r11
  mov    %rsp,%rbp
  push   %r15
  mov    %rdi,%r15
  push   %r14
  push   %r13
  mov    %edx,%r13d
  push   %r12
  mov    %r8,%r12
  push   %rbx
  sub    $0x38,%rsp
  mov    D5(%rip),%rbx
  mov    %fs:0x28,%rax
  mov    %rax,-0x38(%rbp)
  xor    %eax,%eax
  mov    %rsp,%rsi
  mov    %rsp,%r14
  mov    (%rbx),%edx
  lea    (%rdx,%rdx,1),%eax
  cltq
  add    $0xf,%rax
  mov    %rax,%rcx
  and    $0xfffffffffffff000,%rax
  sub    %rax,%rsi
  and    $0xfffffffffffffff0,%rcx
  cmp    %rsi,%rsp
  je     L105
L61:
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  cmp    %rsi,%rsp
  jne    L61
L105:
  and    $0xfff,%ecx
  sub    %rcx,%rsp
  test   %rcx,%rcx
  jne    L154
  lea    -0x1(%r13),%eax
  mov    %rsp,%r8
  cmp    $0x7f,%eax
  jbe    L117
  nopl   0x0(%rax,%rax,1)
L129:
  mov    %r14,%rsp
  mov    -0x38(%rbp),%rax
  sub    %fs:0x28,%rax
  jne    L14
  lea    -0x28(%rbp),%rsp
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  pop    %rbp
  ret
  nopl   (%rax)
L117:
  mov    %r12,%rsi
  mov    %rsp,%rdi
  mov    %r9d,-0x5c(%rbp)
  mov    %r10,-0x50(%rbp)
  mov    %r8,-0x48(%rbp)
  mov    %r11,-0x58(%rbp)
  call   <memcpy@plt>
  mov    -0x58(%rbp),%rdx
  mov    %r12,%rsi
  mov    %r12,%rdi
  call   <AES_encrypt@plt>
  mov    -0x5c(%rbp),%r9d
  lea    0x7(%r13),%esi
  xor    %eax,%eax
  sar    $0x3,%esi
  mov    -0x48(%rbp),%r8
  mov    -0x50(%rbp),%r10
  test   %r9d,%r9d
  movslq %esi,%rsi
  je     L27
  nopl   0x0(%rax,%rax,1)
L40:
  mov    (%rbx),%ecx
  movzbl (%r15,%rax,1),%edx
  xor    (%r12,%rax,1),%dl
  add    %eax,%ecx
  mov    %dl,(%r10,%rax,1)
  add    $0x1,%rax
  movslq %ecx,%rcx
  mov    %dl,(%r8,%rcx,1)
  cmp    %rax,%rsi
  jne    L40
L62:
  mov    %r13d,%edx
  mov    (%rbx),%r9d
  sar    $0x3,%edx
  and    $0x7,%r13d
  je     L70
  test   %r9d,%r9d
  jle    L129
  mov    $0x8,%r9d
  movslq %edx,%rdx
  xor    %eax,%eax
  sub    %r13d,%r9d
  lea    (%r8,%rdx,1),%rdi
  nop
L45:
  movzbl (%rdi,%rax,1),%edx
  movzbl 0x1(%rdi,%rax,1),%esi
  mov    %r13d,%ecx
  shl    %cl,%edx
  mov    %r9d,%ecx
  sar    %cl,%esi
  or     %esi,%edx
  mov    %dl,(%r12,%rax,1)
  add    $0x1,%rax
  cmp    %eax,(%rbx)
  jg     L45
  jmp    L129
  cs nopw 0x0(%rax,%rax,1)
L27:
  mov    (%rbx),%ecx
  movzbl (%r15,%rax,1),%edx
  add    %eax,%ecx
  movslq %ecx,%rcx
  mov    %dl,(%r8,%rcx,1)
  xor    (%r12,%rax,1),%dl
  mov    %dl,(%r10,%rax,1)
  add    $0x1,%rax
  cmp    %rax,%rsi
  jne    L27
  jmp    L62
  cs nopw 0x0(%rax,%rax,1)
L154:
  orq    $0x0,-0x8(%rsp,%rcx,1)
  lea    -0x1(%r13),%eax
  mov    %rsp,%r8
  cmp    $0x7f,%eax
  ja     L129
  jmp    L117
  nopl   0x0(%rax,%rax,1)
L70:
  movslq %edx,%rdx
  mov    %r12,%rdi
  lea    (%r8,%rdx,1),%rsi
  mov    %r9d,%edx
  call   <memcpy@plt>
  jmp    L129
L14:
  call   <__stack_chk_fail@plt>
```

assistant: ```c
void AES_cfbr_encrypt_block(const unsigned char *in, unsigned char *out, const int nbits, const AES_KEY *key, unsigned char *ivec, const int enc) {
  int n, rem, num;
  unsigned char ovec[AES_BLOCK_SIZE * 2];
  if (nbits <= 0 || nbits > 128)
    return;
  memcpy(ovec, ivec, AES_BLOCK_SIZE);
  AES_encrypt(ivec, ivec, key);
  num = (nbits + 7) / 8;
  if (enc)
    for (n = 0; n < num; ++n)
      out[n] = (ovec[AES_BLOCK_SIZE + n] = in[n] ^ ivec[n]);
  else
    for (n = 0; n < num; ++n)
      out[n] = (ovec[AES_BLOCK_SIZE + n] = in[n]) ^ ivec[n];
  rem = nbits % 8;
  num = nbits / 8;
  if (rem == 0)
    memcpy(ivec, ovec + num, AES_BLOCK_SIZE);
  else
    for (n = 0; n < AES_BLOCK_SIZE; ++n)
      ivec[n] = ovec[n + num] << rem | ovec[n + num + 1] >> (8 - rem);
}
```