user: Translate the below assembly code into C programming language:

```asm
<E512>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0xb30,%rsp
  mov    %rdi,-0xb08(%rbp)
  mov    %rsi,-0xb10(%rbp)
  mov    %rdx,-0xb18(%rbp)
  mov    %rcx,-0xb20(%rbp)
  mov    %r8,-0xb28(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  movl   $0x0,-0xafc(%rbp)
  jmp    L152
L294:
  mov    -0xafc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0xb08(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%edx
  mov    -0xafc(%rbp),%eax
  cltq
  mov    %edx,-0xad0(%rbp,%rax,4)
  addl   $0x1,-0xafc(%rbp)
L152:
  cmpl   $0xf,-0xafc(%rbp)
  jle    L294
  movl   $0x0,-0xafc(%rbp)
  jmp    L289
L287:
  mov    -0xafc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0xb18(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%edx
  mov    -0xafc(%rbp),%eax
  cltq
  mov    %edx,-0xa90(%rbp,%rax,4)
  addl   $0x1,-0xafc(%rbp)
L289:
  cmpl   $0x1f,-0xafc(%rbp)
  jle    L287
  mov    -0xb28(%rbp),%rdx
  mov    -0xb20(%rbp),%rcx
  lea    -0xa90(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <MessageExpansion512@plt>
  movl   $0x0,-0xafc(%rbp)
  jmp    L283
L166:
  movl   $0x0,-0xaf8(%rbp)
  jmp    L195
L263:
  mov    -0xaf8(%rbp),%eax
  add    $0x4,%eax
  cltq
  mov    -0xad0(%rbp,%rax,4),%edx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    %edx,-0xaf0(%rbp,%rax,4)
  addl   $0x1,-0xaf8(%rbp)
L195:
  cmpl   $0x3,-0xaf8(%rbp)
  jle    L263
  mov    -0xafc(%rbp),%eax
  shl    $0x5,%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  lea    -0xa90(%rbp),%rax
  add    %rax,%rdx
  lea    -0xae0(%rbp),%rcx
  lea    -0xaf0(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <roundAESkeyfirst@plt>
  movl   $0x0,-0xaf8(%rbp)
  jmp    L57
L130:
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    -0xae0(%rbp,%rax,4),%edx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    %edx,-0xaf0(%rbp,%rax,4)
  addl   $0x1,-0xaf8(%rbp)
L57:
  cmpl   $0x3,-0xaf8(%rbp)
  jle    L130
  mov    -0xafc(%rbp),%eax
  shl    $0x5,%eax
  cltq
  add    $0x4,%rax
  lea    0x0(,%rax,4),%rdx
  lea    -0xa90(%rbp),%rax
  add    %rax,%rdx
  lea    -0xae0(%rbp),%rcx
  lea    -0xaf0(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <roundAESkeyfirst@plt>
  movl   $0x0,-0xaf8(%rbp)
  jmp    L109
L209:
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    -0xae0(%rbp,%rax,4),%edx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    %edx,-0xaf0(%rbp,%rax,4)
  addl   $0x1,-0xaf8(%rbp)
L109:
  cmpl   $0x3,-0xaf8(%rbp)
  jle    L209
  mov    -0xafc(%rbp),%eax
  shl    $0x5,%eax
  cltq
  add    $0x8,%rax
  lea    0x0(,%rax,4),%rdx
  lea    -0xa90(%rbp),%rax
  add    %rax,%rdx
  lea    -0xae0(%rbp),%rcx
  lea    -0xaf0(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <roundAESkeyfirst@plt>
  movl   $0x0,-0xaf8(%rbp)
  jmp    L126
L51:
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    -0xae0(%rbp,%rax,4),%edx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    %edx,-0xaf0(%rbp,%rax,4)
  addl   $0x1,-0xaf8(%rbp)
L126:
  cmpl   $0x3,-0xaf8(%rbp)
  jle    L51
  mov    -0xafc(%rbp),%eax
  shl    $0x5,%eax
  cltq
  add    $0xc,%rax
  lea    0x0(,%rax,4),%rdx
  lea    -0xa90(%rbp),%rax
  add    %rax,%rdx
  lea    -0xae0(%rbp),%rcx
  lea    -0xaf0(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <roundAESkeyfirst@plt>
  movl   $0x0,-0xaf8(%rbp)
  jmp    L251
L25:
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    -0xad0(%rbp,%rax,4),%edx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    -0xae0(%rbp,%rax,4),%eax
  xor    %eax,%edx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    %edx,-0xad0(%rbp,%rax,4)
  addl   $0x1,-0xaf8(%rbp)
L251:
  cmpl   $0x3,-0xaf8(%rbp)
  jle    L25
  movl   $0x0,-0xaf8(%rbp)
  jmp    L113
L295:
  mov    -0xaf8(%rbp),%eax
  add    $0xc,%eax
  cltq
  mov    -0xad0(%rbp,%rax,4),%edx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    %edx,-0xaf0(%rbp,%rax,4)
  addl   $0x1,-0xaf8(%rbp)
L113:
  cmpl   $0x3,-0xaf8(%rbp)
  jle    L295
  mov    -0xafc(%rbp),%eax
  shl    $0x5,%eax
  cltq
  add    $0x10,%rax
  lea    0x0(,%rax,4),%rdx
  lea    -0xa90(%rbp),%rax
  add    %rax,%rdx
  lea    -0xae0(%rbp),%rcx
  lea    -0xaf0(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <roundAESkeyfirst@plt>
  movl   $0x0,-0xaf8(%rbp)
  jmp    L293
L230:
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    -0xae0(%rbp,%rax,4),%edx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    %edx,-0xaf0(%rbp,%rax,4)
  addl   $0x1,-0xaf8(%rbp)
L293:
  cmpl   $0x3,-0xaf8(%rbp)
  jle    L230
  mov    -0xafc(%rbp),%eax
  shl    $0x5,%eax
  cltq
  add    $0x14,%rax
  lea    0x0(,%rax,4),%rdx
  lea    -0xa90(%rbp),%rax
  add    %rax,%rdx
  lea    -0xae0(%rbp),%rcx
  lea    -0xaf0(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <roundAESkeyfirst@plt>
  movl   $0x0,-0xaf8(%rbp)
  jmp    L67
L46:
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    -0xae0(%rbp,%rax,4),%edx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    %edx,-0xaf0(%rbp,%rax,4)
  addl   $0x1,-0xaf8(%rbp)
L67:
  cmpl   $0x3,-0xaf8(%rbp)
  jle    L46
  mov    -0xafc(%rbp),%eax
  shl    $0x5,%eax
  cltq
  add    $0x18,%rax
  lea    0x0(,%rax,4),%rdx
  lea    -0xa90(%rbp),%rax
  add    %rax,%rdx
  lea    -0xae0(%rbp),%rcx
  lea    -0xaf0(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <roundAESkeyfirst@plt>
  movl   $0x0,-0xaf8(%rbp)
  jmp    L78
L299:
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    -0xae0(%rbp,%rax,4),%edx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    %edx,-0xaf0(%rbp,%rax,4)
  addl   $0x1,-0xaf8(%rbp)
L78:
  cmpl   $0x3,-0xaf8(%rbp)
  jle    L299
  mov    -0xafc(%rbp),%eax
  shl    $0x5,%eax
  cltq
  add    $0x1c,%rax
  lea    0x0(,%rax,4),%rdx
  lea    -0xa90(%rbp),%rax
  add    %rax,%rdx
  lea    -0xae0(%rbp),%rcx
  lea    -0xaf0(%rbp),%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <roundAESkeyfirst@plt>
  movl   $0x0,-0xaf8(%rbp)
  jmp    L97
L54:
  mov    -0xaf8(%rbp),%eax
  add    $0x8,%eax
  cltq
  mov    -0xad0(%rbp,%rax,4),%ecx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    -0xae0(%rbp,%rax,4),%edx
  mov    -0xaf8(%rbp),%eax
  add    $0x8,%eax
  xor    %ecx,%edx
  cltq
  mov    %edx,-0xad0(%rbp,%rax,4)
  addl   $0x1,-0xaf8(%rbp)
L97:
  cmpl   $0x3,-0xaf8(%rbp)
  jle    L54
  movl   $0x0,-0xaf8(%rbp)
  jmp    L303
L205:
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    -0xad0(%rbp,%rax,4),%eax
  mov    %eax,-0xaf4(%rbp)
  mov    -0xaf8(%rbp),%eax
  add    $0x4,%eax
  cltq
  mov    -0xad0(%rbp,%rax,4),%edx
  mov    -0xaf8(%rbp),%eax
  cltq
  mov    %edx,-0xad0(%rbp,%rax,4)
  mov    -0xaf8(%rbp),%eax
  lea    0x8(%rax),%edx
  mov    -0xaf8(%rbp),%eax
  lea    0x4(%rax),%ecx
  movslq %edx,%rax
  mov    -0xad0(%rbp,%rax,4),%edx
  movslq %ecx,%rax
  mov    %edx,-0xad0(%rbp,%rax,4)
  mov    -0xaf8(%rbp),%eax
  lea    0xc(%rax),%edx
  mov    -0xaf8(%rbp),%eax
  lea    0x8(%rax),%ecx
  movslq %edx,%rax
  mov    -0xad0(%rbp,%rax,4),%edx
  movslq %ecx,%rax
  mov    %edx,-0xad0(%rbp,%rax,4)
  mov    -0xaf8(%rbp),%eax
  add    $0xc,%eax
  cltq
  mov    -0xaf4(%rbp),%edx
  mov    %edx,-0xad0(%rbp,%rax,4)
  addl   $0x1,-0xaf8(%rbp)
L303:
  cmpl   $0x3,-0xaf8(%rbp)
  jle    L205
  addl   $0x1,-0xafc(%rbp)
L283:
  cmpl   $0xd,-0xafc(%rbp)
  jle    L166
  movl   $0x0,-0xafc(%rbp)
  jmp    L279
L6:
  mov    -0xafc(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0xb10(%rbp),%rax
  add    %rax,%rdx
  mov    -0xafc(%rbp),%eax
  cltq
  mov    -0xad0(%rbp,%rax,4),%eax
  mov    %eax,(%rdx)
  addl   $0x1,-0xafc(%rbp)
L279:
  cmpl   $0xf,-0xafc(%rbp)
  jle    L6
  nop
  mov    -0x8(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L11
  call   <__stack_chk_fail@plt>
L11:
  leave
  ret
```

assistant: ```c
void E512(uint32_t pt[16], uint32_t ct[16], uint32_t message[32], uint32_t salt[16], uint32_t counter[4]) {
  uint32_t state[16], i, j;
  uint32_t input[4], output[4], temp;
  uint32_t rk[(14 * 4 * (4) * 3)];
  for (i = 0; i < 16; i++)
    state[i] = pt[i];
  for (i = 0; i < 32; i++)
    rk[i] = message[i];
  MessageExpansion512(rk, salt, counter);
  for (i = 0; i < 14; i++) {
    for (j = 0; j < 4; j++)
      input[j] = state[4 + j];
    roundAESkeyfirst(input, output, rk + 32 * i);
    for (j = 0; j < 4; j++)
      input[j] = output[j];
    roundAESkeyfirst(input, output, rk + 32 * i + 4);
    for (j = 0; j < 4; j++)
      input[j] = output[j];
    roundAESkeyfirst(input, output, rk + 32 * i + 8);
    for (j = 0; j < 4; j++)
      input[j] = output[j];
    roundAESkeyfirst(input, output, rk + 32 * i + 12);
    for (j = 0; j < 4; j++)
      state[j] ^= output[j];
    for (j = 0; j < 4; j++)
      input[j] = state[12 + j];
    roundAESkeyfirst(input, output, rk + 32 * i + 16);
    for (j = 0; j < 4; j++)
      input[j] = output[j];
    roundAESkeyfirst(input, output, rk + 32 * i + 20);
    for (j = 0; j < 4; j++)
      input[j] = output[j];
    roundAESkeyfirst(input, output, rk + 32 * i + 24);
    for (j = 0; j < 4; j++)
      input[j] = output[j];
    roundAESkeyfirst(input, output, rk + 32 * i + 28);
    for (j = 0; j < 4; j++)
      state[8 + j] ^= output[j];
    for (j = 0; j < 4; j++) {
      temp = state[j];
      state[j] = state[j + 4];
      state[j + 4] = state[j + 8];
      state[j + 8] = state[j + 12];
      state[j + 12] = temp;
    }
  }
  for (i = 0; i < 16; i++)
    ct[i] = state[i];
  return;
}
```