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

```asm
<Prettify>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x20,%rsp
  mov    %rdi,-0x18(%rbp)
  mov    %esi,-0x1c(%rbp)
  mov    %edx,-0x20(%rbp)
  mov    -0x1c(%rbp),%edx
  mov    -0x20(%rbp),%eax
  add    %edx,%eax
  mov    %eax,-0x8(%rbp)
  mov    -0x1c(%rbp),%eax
  cmp    -0x8(%rbp),%eax
  jg     L44
  cmpl   $0x15,-0x8(%rbp)
  jg     L44
  mov    -0x1c(%rbp),%eax
  mov    %eax,-0x10(%rbp)
  jmp    L128
L10:
  mov    -0x10(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movb   $0x30,(%rax)
  addl   $0x1,-0x10(%rbp)
L128:
  mov    -0x10(%rbp),%eax
  cmp    -0x8(%rbp),%eax
  jl     L10
  mov    -0x8(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movb   $0x2e,(%rax)
  mov    -0x8(%rbp),%eax
  cltq
  lea    0x1(%rax),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movb   $0x30,(%rax)
  mov    -0x8(%rbp),%eax
  cltq
  lea    0x2(%rax),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movb   $0x0,(%rax)
  jmp    L77
L44:
  cmpl   $0x0,-0x8(%rbp)
  jle    L55
  cmpl   $0x15,-0x8(%rbp)
  jg     L55
  mov    -0x1c(%rbp),%eax
  sub    -0x8(%rbp),%eax
  mov    -0x8(%rbp),%edx
  movslq %edx,%rcx
  mov    -0x18(%rbp),%rdx
  lea    (%rcx,%rdx,1),%rsi
  mov    -0x8(%rbp),%edx
  movslq %edx,%rdx
  lea    0x1(%rdx),%rcx
  mov    -0x18(%rbp),%rdx
  add    %rdx,%rcx
  mov    %eax,%edx
  mov    %rcx,%rdi
  call   <memmove@plt>
  mov    -0x8(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movb   $0x2e,(%rax)
  mov    -0x1c(%rbp),%eax
  cltq
  lea    0x1(%rax),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movb   $0x0,(%rax)
  jmp    L77
L55:
  cmpl   $0xfffffffb,-0x8(%rbp)
  jl     L91
  cmpl   $0x0,-0x8(%rbp)
  jg     L91
  mov    $0x2,%eax
  sub    -0x8(%rbp),%eax
  mov    %eax,-0x4(%rbp)
  mov    -0x4(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x18(%rbp),%rax
  lea    (%rdx,%rax,1),%rcx
  mov    -0x1c(%rbp),%edx
  mov    -0x18(%rbp),%rax
  mov    %rax,%rsi
  mov    %rcx,%rdi
  call   <memmove@plt>
  mov    -0x18(%rbp),%rax
  movb   $0x30,(%rax)
  mov    -0x18(%rbp),%rax
  add    $0x1,%rax
  movb   $0x2e,(%rax)
  movl   $0x2,-0xc(%rbp)
  jmp    L29
L149:
  mov    -0xc(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movb   $0x30,(%rax)
  addl   $0x1,-0xc(%rbp)
L29:
  mov    -0xc(%rbp),%eax
  cmp    -0x4(%rbp),%eax
  jl     L149
  mov    -0x1c(%rbp),%edx
  mov    -0x4(%rbp),%eax
  add    %edx,%eax
  movslq %eax,%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movb   $0x0,(%rax)
  jmp    L77
L91:
  cmpl   $0x1,-0x1c(%rbp)
  jne    L43
  mov    -0x18(%rbp),%rax
  add    $0x1,%rax
  movb   $0x65,(%rax)
  mov    -0x18(%rbp),%rax
  lea    0x2(%rax),%rdx
  mov    -0x8(%rbp),%eax
  sub    $0x1,%eax
  mov    %rdx,%rsi
  mov    %eax,%edi
  call   <WriteExponent@plt>
  jmp    L77
L43:
  mov    -0x1c(%rbp),%eax
  lea    -0x1(%rax),%edx
  mov    -0x18(%rbp),%rax
  lea    0x1(%rax),%rcx
  mov    -0x18(%rbp),%rax
  add    $0x2,%rax
  mov    %rcx,%rsi
  mov    %rax,%rdi
  call   <memmove@plt>
  mov    -0x18(%rbp),%rax
  add    $0x1,%rax
  movb   $0x2e,(%rax)
  mov    -0x1c(%rbp),%eax
  cltq
  lea    0x1(%rax),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movb   $0x65,(%rax)
  mov    -0x1c(%rbp),%eax
  cltq
  lea    0x2(%rax),%rdx
  mov    -0x18(%rbp),%rax
  add    %rax,%rdx
  mov    -0x8(%rbp),%eax
  sub    $0x1,%eax
  mov    %rdx,%rsi
  mov    %eax,%edi
  call   <WriteExponent@plt>
  jmp    L77
L77:
  nop
  leave
  ret
```

assistant: ```c
void Prettify(char *buffer, int length, int k) {
  const int kk = length + k;
  if (length <= kk && kk <= 21) {
    int i;
    for (i = length; i < kk; i++)
      buffer[i] = '0';
    buffer[kk] = '.';
    buffer[kk + 1] = '0';
    buffer[kk + 2] = '\0';
  } else if (0 < kk && kk <= 21) {
    memmove(&buffer[kk + 1], &buffer[kk], length - kk);
    buffer[kk] = '.';
    buffer[length + 1] = '\0';
  } else if (-6 < kk && kk <= 0) {
    int i;
    const int offset = 2 - kk;
    memmove(&buffer[offset], &buffer[0], length);
    buffer[0] = '0';
    buffer[1] = '.';
    for (i = 2; i < offset; i++)
      buffer[i] = '0';
    buffer[length + offset] = '\0';
  } else if (length == 1) {
    buffer[1] = 'e';
    WriteExponent(kk - 1, &buffer[2]);
  } else {
    memmove(&buffer[2], &buffer[1], length - 1);
    buffer[1] = '.';
    buffer[length + 1] = 'e';
    WriteExponent(kk - 1, &buffer[0 + length + 2]);
  }
}
```