user: 请从给定的汇编指令推导出C源代码:

```asm
<Encrypt>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x50,%rsp
  mov    %rdi,-0x38(%rbp)
  mov    %rsi,-0x40(%rbp)
  mov    %rdx,-0x48(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  movq   $0x0,-0x10(%rbp)
  jmp    L0
L2:
  mov    -0x38(%rbp),%rax
  add    $0x1c,%rax
  mov    (%rax),%eax
  lea    0x0(,%rax,4),%edx
  mov    -0x38(%rbp),%rax
  add    $0x20,%rax
  mov    (%rax),%eax
  sar    $0x6,%eax
  xor    %edx,%eax
  mov    %eax,-0x24(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x28,%rax
  mov    (%rax),%eax
  shl    $0x5,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%rax
  add    $0x2c,%rax
  mov    (%rax),%eax
  sar    $0x3,%eax
  xor    %edx,%eax
  mov    %eax,-0x20(%rbp)
  mov    -0x24(%rbp),%eax
  xor    -0x20(%rbp),%eax
  mov    %eax,-0x30(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x4c,%rax
  mov    (%rax),%eax
  shl    $0x5,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%rax
  add    $0x50,%rax
  mov    (%rax),%eax
  sar    $0x3,%eax
  xor    %edx,%eax
  mov    %eax,-0x24(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x54,%rax
  mov    (%rax),%eax
  shl    $0x4,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%rax
  add    $0x58,%rax
  mov    (%rax),%eax
  sar    $0x4,%eax
  xor    %edx,%eax
  mov    %eax,-0x20(%rbp)
  mov    -0x24(%rbp),%eax
  xor    -0x20(%rbp),%eax
  mov    %eax,-0x2c(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x78,%rax
  mov    (%rax),%eax
  lea    0x0(,%rax,4),%edx
  mov    -0x38(%rbp),%rax
  add    $0x7c,%rax
  mov    (%rax),%eax
  sar    $0x6,%eax
  xor    %edx,%eax
  mov    %eax,-0x24(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x8c,%rax
  mov    (%rax),%eax
  shl    $0x7,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%rax
  add    $0x90,%rax
  mov    (%rax),%eax
  sar    %eax
  xor    %edx,%eax
  mov    %eax,-0x20(%rbp)
  mov    -0x24(%rbp),%eax
  xor    -0x20(%rbp),%eax
  mov    %eax,-0x28(%rbp)
  mov    -0x10(%rbp),%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x40(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%edx
  mov    -0x30(%rbp),%ecx
  mov    -0x2c(%rbp),%eax
  xor    %eax,%ecx
  mov    -0x28(%rbp),%eax
  xor    %eax,%ecx
  mov    -0x10(%rbp),%rax
  lea    0x0(,%rax,4),%rsi
  mov    -0x40(%rbp),%rax
  add    %rsi,%rax
  xor    %ecx,%edx
  mov    %edx,(%rax)
  mov    -0x38(%rbp),%rax
  add    $0x28,%rax
  mov    (%rax),%eax
  lea    0x0(,%rax,8),%edx
  mov    -0x38(%rbp),%rax
  add    $0x2c,%rax
  mov    (%rax),%eax
  sar    $0x5,%eax
  xor    %edx,%eax
  mov    %eax,-0x1c(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x28,%rax
  mov    (%rax),%eax
  shl    $0x4,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%rax
  add    $0x2c,%rax
  mov    (%rax),%eax
  sar    $0x4,%eax
  xor    %edx,%eax
  mov    %eax,-0x18(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x50,%rax
  mov    (%rax),%eax
  shl    $0x6,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%rax
  add    $0x54,%rax
  mov    (%rax),%eax
  sar    $0x2,%eax
  xor    %edx,%eax
  mov    %eax,-0x14(%rbp)
  mov    -0x1c(%rbp),%eax
  and    -0x18(%rbp),%eax
  mov    %eax,%edx
  mov    -0x30(%rbp),%eax
  xor    %edx,%eax
  xor    -0x14(%rbp),%eax
  mov    %eax,-0x30(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x54,%rax
  mov    (%rax),%eax
  lea    0x0(,%rax,4),%edx
  mov    -0x38(%rbp),%rax
  add    $0x58,%rax
  mov    (%rax),%eax
  sar    $0x6,%eax
  xor    %edx,%eax
  mov    %eax,-0x1c(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x54,%rax
  mov    (%rax),%eax
  lea    0x0(,%rax,8),%edx
  mov    -0x38(%rbp),%rax
  add    $0x58,%rax
  mov    (%rax),%eax
  sar    $0x5,%eax
  xor    %edx,%eax
  mov    %eax,-0x18(%rbp)
  mov    -0x38(%rbp),%rax
  sub    $0xffffffffffffff80,%rax
  mov    (%rax),%eax
  shl    $0x7,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%rax
  add    $0x84,%rax
  mov    (%rax),%eax
  sar    %eax
  xor    %edx,%eax
  mov    %eax,-0x14(%rbp)
  mov    -0x1c(%rbp),%eax
  and    -0x18(%rbp),%eax
  mov    %eax,%edx
  mov    -0x2c(%rbp),%eax
  xor    %edx,%eax
  xor    -0x14(%rbp),%eax
  mov    %eax,-0x2c(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x8c,%rax
  mov    (%rax),%eax
  shl    $0x5,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%rax
  add    $0x90,%rax
  mov    (%rax),%eax
  sar    $0x3,%eax
  xor    %edx,%eax
  mov    %eax,-0x1c(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x8c,%rax
  mov    (%rax),%eax
  shl    $0x6,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%rax
  add    $0x90,%rax
  mov    (%rax),%eax
  sar    $0x2,%eax
  xor    %edx,%eax
  mov    %eax,-0x18(%rbp)
  mov    -0x38(%rbp),%rax
  add    $0x1c,%rax
  mov    (%rax),%eax
  shl    $0x5,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%rax
  add    $0x20,%rax
  mov    (%rax),%eax
  sar    $0x3,%eax
  xor    %edx,%eax
  mov    %eax,-0x14(%rbp)
  mov    -0x1c(%rbp),%eax
  and    -0x18(%rbp),%eax
  mov    %eax,%edx
  mov    -0x28(%rbp),%eax
  xor    %edx,%eax
  xor    -0x14(%rbp),%eax
  mov    %eax,-0x28(%rbp)
  lea    -0x28(%rbp),%rcx
  lea    -0x2c(%rbp),%rdx
  lea    -0x30(%rbp),%rsi
  mov    -0x38(%rbp),%rax
  mov    %rax,%rdi
  call   <Rotate@plt>
  addq   $0x1,-0x10(%rbp)
L0:
  mov    -0x10(%rbp),%rax
  cmp    -0x48(%rbp),%rax
  jb     L2
  nop
  mov    -0x8(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L28
  call   <__stack_chk_fail@plt>
L28:
  leave
  ret
```

assistant: ```c
void Encrypt(uint8_t *state, uint8_t *stream, uint16_t length) {
  uint16_t i;
  uint8_t t1, t2, t3;
  uint8_t x1, x2, x3, x4, x5;
  for (i = 0; i < length; i++) {
    x1 = (state[7] << 2) ^ (state[8] >> 6);
    x4 = (state[10] << 5) ^ (state[11] >> 3);
    t1 = x1 ^ x4;
    x1 = (state[19] << 5) ^ (state[20] >> 3);
    x4 = (state[21] << 4) ^ (state[22] >> 4);
    t2 = x1 ^ x4;
    x1 = (state[30] << 2) ^ (state[31] >> 6);
    x4 = (state[35] << 7) ^ (state[36] >> 1);
    t3 = x1 ^ x4;
    stream[i] ^= t1 ^ t2 ^ t3;
    x2 = (state[10] << 3) ^ (state[11] >> 5);
    x3 = (state[10] << 4) ^ (state[11] >> 4);
    x5 = (state[20] << 6) ^ (state[21] >> 2);
    t1 = t1 ^ (x2 & x3) ^ x5;
    x2 = (state[21] << 2) ^ (state[22] >> 6);
    x3 = (state[21] << 3) ^ (state[22] >> 5);
    x5 = (state[32] << 7) ^ (state[33] >> 1);
    t2 = t2 ^ (x2 & x3) ^ x5;
    x2 = (state[35] << 5) ^ (state[36] >> 3);
    x3 = (state[35] << 6) ^ (state[36] >> 2);
    x5 = (state[7] << 5) ^ (state[8] >> 3);
    t3 = t3 ^ (x2 & x3) ^ x5;
    Rotate(state, &t1, &t2, &t3);
  }
}
```