user: 请将以下的汇编代码转换成C语言代码:

```asm
<encryptablock>:
  endbr64
  push   %r15
  pxor   %xmm0,%xmm0
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  mov    %rdi,%rbp
  mov    %rsi,%rdi
  push   %rbx
  lea    0x6(%rbp),%r15
  lea    0xd(%rbp),%r14
  lea    0xc(%rbp),%r13
  sub    $0x148,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x138(%rsp)
  xor    %eax,%eax
  lea    0x80(%rsp),%rbx
  lea    0x70(%rsp),%r12
  movaps %xmm0,0x80(%rsp)
  mov    %rbx,%rsi
  movaps %xmm0,0x90(%rsp)
  movaps %xmm0,0xa0(%rsp)
  movaps %xmm0,0xb0(%rsp)
  movaps %xmm0,0xc0(%rsp)
  movaps %xmm0,0xd0(%rsp)
  movaps %xmm0,0xe0(%rsp)
  movaps %xmm0,0xf0(%rsp)
  movaps %xmm0,0x100(%rsp)
  movaps %xmm0,0x110(%rsp)
  movaps %xmm0,0x120(%rsp)
  movaps %xmm0,0x70(%rsp)
  mov    %rbx,0x68(%rsp)
  call   <expandkey@plt>
  mov    %rbx,%rdi
  xor    %edx,%edx
  mov    %r12,%rsi
  call   <getroundkey@plt>
  mov    %r12,%rsi
  mov    %rbp,%rdi
  lea    0x7(%rbp),%rbx
  call   <addroundkey@plt>
  lea    0x5(%rbp),%rax
  lea    0x3(%rbp),%r11
  mov    $0x1,%r8d
  mov    %rax,0x8(%rsp)
  lea    0x4(%rbp),%rax
  lea    0x2(%rbp),%r10
  mov    %rax,0x10(%rsp)
  lea    0xb(%rbp),%rax
  lea    0x1(%rbp),%r9
  mov    %rax,0x18(%rsp)
  lea    0xa(%rbp),%rax
  mov    %rax,0x20(%rsp)
  lea    0x9(%rbp),%rax
  mov    %rax,0x28(%rsp)
  lea    0x8(%rbp),%rax
  mov    %rax,0x30(%rsp)
  lea    0xf(%rbp),%rax
  mov    %rax,0x38(%rsp)
  lea    0xe(%rbp),%rax
  mov    %rax,0x40(%rsp)
  mov    %r11,0x48(%rsp)
  mov    %r10,0x50(%rsp)
  mov    %r9,0x58(%rsp)
  mov    %rbx,0x60(%rsp)
  mov    %r8d,%ebx
  nopw   0x0(%rax,%rax,1)
L17:
  mov    0x48(%rsp),%rcx
  mov    0x50(%rsp),%rdx
  mov    %rbp,%rdi
  mov    0x58(%rsp),%rsi
  call   <subbytes@plt>
  mov    0x60(%rsp),%rcx
  mov    0x8(%rsp),%rsi
  mov    %r15,%rdx
  mov    0x10(%rsp),%rdi
  call   <subbytes@plt>
  mov    0x18(%rsp),%rcx
  mov    0x20(%rsp),%rdx
  mov    0x28(%rsp),%rsi
  mov    0x30(%rsp),%rdi
  call   <subbytes@plt>
  mov    0x38(%rsp),%rcx
  mov    %r14,%rsi
  mov    %r13,%rdi
  mov    0x40(%rsp),%rdx
  call   <subbytes@plt>
  mov    %rbp,%rdi
  call   <rotate_word@plt>
  mov    0x48(%rsp),%rcx
  mov    0x50(%rsp),%rdx
  mov    %rbp,%rdi
  mov    0x58(%rsp),%rsi
  call   <mixcolumns@plt>
  mov    0x60(%rsp),%rcx
  mov    0x8(%rsp),%rsi
  mov    %r15,%rdx
  mov    0x10(%rsp),%rdi
  call   <mixcolumns@plt>
  mov    0x18(%rsp),%rcx
  mov    0x20(%rsp),%rdx
  mov    0x28(%rsp),%rsi
  mov    0x30(%rsp),%rdi
  call   <mixcolumns@plt>
  mov    0x38(%rsp),%rcx
  mov    %r14,%rsi
  mov    %r13,%rdi
  mov    0x40(%rsp),%rdx
  call   <mixcolumns@plt>
  mov    0x68(%rsp),%rdi
  mov    %ebx,%edx
  mov    %r12,%rsi
  add    $0x1,%ebx
  call   <getroundkey@plt>
  mov    %r12,%rsi
  mov    %rbp,%rdi
  call   <addroundkey@plt>
  cmp    $0xa,%ebx
  jne    L17
  mov    0x48(%rsp),%r11
  mov    0x50(%rsp),%r10
  mov    %rbp,%rdi
  mov    0x58(%rsp),%r9
  mov    0x60(%rsp),%rbx
  mov    %r11,%rcx
  mov    %r10,%rdx
  mov    %r9,%rsi
  call   <subbytes@plt>
  mov    0x8(%rsp),%rsi
  mov    %rbx,%rcx
  mov    %r15,%rdx
  mov    0x10(%rsp),%rdi
  call   <subbytes@plt>
  mov    0x18(%rsp),%rcx
  mov    0x20(%rsp),%rdx
  mov    0x28(%rsp),%rsi
  mov    0x30(%rsp),%rdi
  call   <subbytes@plt>
  mov    0x38(%rsp),%rcx
  mov    %r14,%rsi
  mov    %r13,%rdi
  mov    0x40(%rsp),%rdx
  call   <subbytes@plt>
  mov    %rbp,%rdi
  call   <rotate_word@plt>
  mov    0x68(%rsp),%rdi
  mov    %r12,%rsi
  mov    $0xa,%edx
  call   <getroundkey@plt>
  mov    %r12,%rsi
  mov    %rbp,%rdi
  call   <addroundkey@plt>
  mov    0x138(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L3
  add    $0x148,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L3:
  call   <__stack_chk_fail@plt>
```

assistant: ```c
void encryptablock(unsigned char *state, unsigned char *key) {
  unsigned char expandedkey[176] = {0};
  unsigned char roundkey[16] = {0};
  expandkey(key, expandedkey);
  getroundkey(expandedkey, roundkey, 0);
  addroundkey(state, roundkey);
  for (int i = 1; i < 10; i++) {
    subbytes(&state[0], &state[1], &state[2], &state[3]);
    subbytes(&state[4], &state[5], &state[6], &state[7]);
    subbytes(&state[8], &state[9], &state[10], &state[11]);
    subbytes(&state[12], &state[13], &state[14], &state[15]);
    rotate_word(state);
    mixcolumns(&state[0], &state[1], &state[2], &state[3]);
    mixcolumns(&state[4], &state[5], &state[6], &state[7]);
    mixcolumns(&state[8], &state[9], &state[10], &state[11]);
    mixcolumns(&state[12], &state[13], &state[14], &state[15]);
    getroundkey(expandedkey, roundkey, i);
    addroundkey(state, roundkey);
  }
  subbytes(&state[0], &state[1], &state[2], &state[3]);
  subbytes(&state[4], &state[5], &state[6], &state[7]);
  subbytes(&state[8], &state[9], &state[10], &state[11]);
  subbytes(&state[12], &state[13], &state[14], &state[15]);
  rotate_word(state);
  getroundkey(expandedkey, roundkey, 10);
  addroundkey(state, roundkey);
}
```