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

```asm
<RandomFunc>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x20,%rsp
  mov    %rdi,-0x18(%rbp)
  mov    %rsi,-0x20(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  mov    -0x18(%rbp),%rax
  movzwl (%rax),%eax
  add    $0x7296,%ax
  mov    %ax,-0xa(%rbp)
  movw   $0x0,-0xc(%rbp)
  jmp    L24
L51:
  movzwl -0xa(%rbp),%eax
  cmp    %ax,-0xc(%rbp)
  jae    L68
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  movzwl %ax,%edx
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  movzwl %ax,%eax
  and    $0xe,%eax
  or     $0x1,%eax
  mov    %eax,%ecx
  sar    %cl,%edx
  mov    %edx,%eax
  mov    %eax,%esi
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  movzwl %ax,%edx
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  movzwl %ax,%eax
  and    $0xe,%eax
  or     $0x1,%eax
  mov    %eax,%ecx
  mov    $0x10,%eax
  sub    %ecx,%eax
  mov    %eax,%ecx
  shl    %cl,%edx
  mov    %edx,%eax
  or     %esi,%eax
  mov    %ax,-0xa(%rbp)
  jmp    L62
L68:
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  movzwl %ax,%edx
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  shr    $0x2,%ax
  movzwl %ax,%eax
  and    $0xe,%eax
  or     $0x1,%eax
  mov    %eax,%ecx
  shl    %cl,%edx
  mov    %edx,%eax
  mov    %eax,%esi
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  movzwl %ax,%edx
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  shr    $0x2,%ax
  movzwl %ax,%eax
  and    $0xe,%eax
  or     $0x1,%eax
  mov    %eax,%ecx
  mov    $0x10,%eax
  sub    %ecx,%eax
  mov    %eax,%ecx
  sar    %cl,%edx
  mov    %edx,%eax
  or     %esi,%eax
  mov    %ax,-0xa(%rbp)
L62:
  movzwl -0xa(%rbp),%eax
  cmp    %ax,-0xc(%rbp)
  jae    L21
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  mov    %eax,%edi
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  movzwl %ax,%edx
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  movzwl %ax,%eax
  and    $0xe,%eax
  or     $0x1,%eax
  mov    %edx,%esi
  mov    %eax,%ecx
  sar    %cl,%esi
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  movzwl %ax,%edx
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  movzwl %ax,%eax
  and    $0xe,%eax
  or     $0x1,%eax
  mov    %eax,%ecx
  mov    $0x10,%eax
  sub    %ecx,%eax
  mov    %eax,%ecx
  shl    %cl,%edx
  mov    %edx,%eax
  or     %esi,%eax
  shl    $0x2,%eax
  and    $0x1c,%eax
  or     %eax,%edi
  mov    %edi,%edx
  movzwl -0xc(%rbp),%eax
  cltq
  mov    %dx,-0xa(%rbp,%rax,2)
  jmp    L61
L21:
  movzwl -0xa(%rbp),%edx
  movzwl -0xc(%rbp),%eax
  cltq
  movzwl -0xa(%rbp,%rax,2),%eax
  or     %edx,%eax
  mov    %ax,-0xa(%rbp)
L61:
  movzwl -0xc(%rbp),%eax
  add    $0x1,%eax
  mov    %ax,-0xc(%rbp)
L24:
  mov    -0x18(%rbp),%rax
  add    $0x2,%rax
  movzwl (%rax),%eax
  cmp    %ax,-0xc(%rbp)
  jb     L51
  movzwl -0xa(%rbp),%eax
  lea    -0x89(%rax),%edx
  mov    -0x20(%rbp),%rax
  mov    %dx,(%rax)
  nop
  mov    -0x8(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L32
  call   <__stack_chk_fail@plt>
L32:
  leave
  ret
```

assistant: ```c
void RandomFunc(unsigned short input[1], unsigned short output[1]) {
  unsigned short state[1];
  unsigned short local1;
  {
    state[0UL] = (input[0UL] - 51238316UL) - (unsigned short)47038;
    local1 = 0UL;
    while (local1 < input[1UL]) {
      if (state[0UL] > local1) {
        state[0UL] = (state[local1] >> ((state[local1] & (unsigned short)15) | 1UL)) | (state[local1] << (16 - ((state[local1] & (unsigned short)15) | 1UL)));
      } else {
        state[0UL] = (state[local1] << (((state[local1] >> (unsigned short)2) & (unsigned short)15) | 1UL)) | (state[local1] >> (16 - (((state[local1] >> (unsigned short)2) & (unsigned short)15) | 1UL)));
      }
      if (state[0UL] > local1) {
        state[local1] |= (((state[local1] >> ((state[local1] & (unsigned short)15) | 1UL)) | (state[local1] << (16 - ((state[local1] & (unsigned short)15) | 1UL)))) & (unsigned short)7) << 2UL;
      } else {
        state[0UL] |= state[local1];
      }
      local1++;
    }
    output[0UL] = state[0UL] + (unsigned short)65399;
  }
}
```