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

```asm
<evaluate>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %rbx
  sub    $0x68,%rsp
  mov    %rdi,-0x68(%rbp)
  mov    %esi,-0x6c(%rbp)
  mov    %edx,-0x70(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x18(%rbp)
  xor    %eax,%eax
  mov    %rsp,%rax
  mov    %rax,%rsi
  movl   $0x0,-0x4c(%rbp)
  mov    -0x6c(%rbp),%eax
  imul   %eax,%eax
  cltq
  sub    $0x1,%rax
  mov    %rax,-0x28(%rbp)
  mov    -0x6c(%rbp),%eax
  imul   %eax,%eax
  cltq
  mov    %rax,%r8
  mov    $0x0,%r9d
  mov    -0x6c(%rbp),%eax
  imul   %eax,%eax
  cltq
  mov    %rax,%rcx
  mov    $0x0,%ebx
  mov    -0x6c(%rbp),%eax
  imul   %eax,%eax
  cltq
  mov    $0x10,%edx
  sub    $0x1,%rdx
  add    %rdx,%rax
  mov    $0x10,%edi
  mov    $0x0,%edx
  div    %rdi
  imul   $0x10,%rax,%rax
  mov    %rax,%rcx
  and    $0xfffffffffffff000,%rcx
  mov    %rsp,%rdx
  sub    %rcx,%rdx
L399:
  cmp    %rdx,%rsp
  je     L572
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  jmp    L399
L572:
  mov    %rax,%rdx
  and    $0xfff,%edx
  sub    %rdx,%rsp
  mov    %rax,%rdx
  and    $0xfff,%edx
  test   %rdx,%rdx
  je     L617
  and    $0xfff,%eax
  sub    $0x8,%rax
  add    %rsp,%rax
  orq    $0x0,(%rax)
L617:
  mov    %rsp,%rax
  add    $0x0,%rax
  mov    %rax,-0x20(%rbp)
  movl   $0x0,-0x5c(%rbp)
  jmp    L93
L600:
  movl   $0x0,-0x58(%rbp)
  jmp    L65
L68:
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  movslq %eax,%rdx
  mov    -0x68(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  movzbl %al,%edx
  mov    -0x70(%rbp),%eax
  mov    %eax,%ecx
  sar    %cl,%edx
  mov    %edx,%eax
  and    $0x1,%eax
  test   %eax,%eax
  je     L720
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movb   $0x31,(%rdx,%rax,1)
  jmp    L253
L720:
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movb   $0x30,(%rdx,%rax,1)
L253:
  addl   $0x1,-0x58(%rbp)
L65:
  mov    -0x58(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L68
  addl   $0x1,-0x5c(%rbp)
L93:
  mov    -0x5c(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L600
  movl   $0x0,-0x5c(%rbp)
  jmp    L262
L203:
  mov    -0x20(%rbp),%rdx
  mov    -0x5c(%rbp),%eax
  cltq
  movzbl (%rdx,%rax,1),%eax
  mov    %al,-0x5d(%rbp)
  movl   $0x0,-0x54(%rbp)
  movl   $0x0,-0x58(%rbp)
  jmp    L105
L774:
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    %al,-0x5d(%rbp)
  jne    L539
  addl   $0x1,-0x54(%rbp)
  jmp    L120
L539:
  cmpl   $0x5,-0x54(%rbp)
  jle    L36
  mov    -0x54(%rbp),%eax
  sub    $0x2,%eax
  add    %eax,-0x4c(%rbp)
L36:
  movl   $0x0,-0x54(%rbp)
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  mov    %al,-0x5d(%rbp)
L120:
  addl   $0x1,-0x58(%rbp)
L105:
  mov    -0x58(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L774
  cmpl   $0x5,-0x54(%rbp)
  jle    L788
  mov    -0x54(%rbp),%eax
  sub    $0x2,%eax
  add    %eax,-0x4c(%rbp)
L788:
  addl   $0x1,-0x5c(%rbp)
L262:
  mov    -0x5c(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L203
  movl   $0x0,-0x58(%rbp)
  jmp    L746
L733:
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  mov    %al,-0x5d(%rbp)
  movl   $0x0,-0x54(%rbp)
  movl   $0x0,-0x5c(%rbp)
  jmp    L444
L16:
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    %al,-0x5d(%rbp)
  jne    L18
  addl   $0x1,-0x54(%rbp)
  jmp    L264
L18:
  cmpl   $0x5,-0x54(%rbp)
  jle    L52
  mov    -0x54(%rbp),%eax
  sub    $0x2,%eax
  add    %eax,-0x4c(%rbp)
L52:
  movl   $0x0,-0x54(%rbp)
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  mov    %al,-0x5d(%rbp)
L264:
  addl   $0x1,-0x5c(%rbp)
L444:
  mov    -0x5c(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L16
  cmpl   $0x5,-0x54(%rbp)
  jle    L41
  mov    -0x54(%rbp),%eax
  sub    $0x2,%eax
  add    %eax,-0x4c(%rbp)
L41:
  addl   $0x1,-0x58(%rbp)
L746:
  mov    -0x58(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L733
  movl   $0x0,-0x5c(%rbp)
  jmp    L498
L816:
  movl   $0x0,-0x58(%rbp)
  jmp    L520
L53:
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%ecx
  mov    -0x58(%rbp),%eax
  add    $0x1,%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    %al,%cl
  jne    L642
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%ecx
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    $0x1,%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    %al,%cl
  jne    L642
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%ecx
  mov    -0x58(%rbp),%eax
  add    $0x1,%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    $0x1,%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    %al,%cl
  jne    L642
  addl   $0x3,-0x4c(%rbp)
L642:
  addl   $0x1,-0x58(%rbp)
L520:
  mov    -0x6c(%rbp),%eax
  sub    $0x1,%eax
  cmp    %eax,-0x58(%rbp)
  jl     L53
  addl   $0x1,-0x5c(%rbp)
L498:
  mov    -0x6c(%rbp),%eax
  sub    $0x1,%eax
  cmp    %eax,-0x5c(%rbp)
  jl     L816
  movl   $0x0,-0x5c(%rbp)
  jmp    L811
L425:
  movl   $0x0,-0x58(%rbp)
  jmp    L163
L324:
  movl   $0x0,-0x48(%rbp)
  movl   $0x0,-0x50(%rbp)
  jmp    L546
L315:
  mov    -0x58(%rbp),%edx
  mov    -0x50(%rbp),%eax
  add    %edx,%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    $0x31,%al
  jne    L807
  mov    -0x50(%rbp),%eax
  mov    $0x40,%edx
  mov    %eax,%ecx
  sar    %cl,%edx
  mov    %edx,%eax
  add    %eax,-0x48(%rbp)
L807:
  addl   $0x1,-0x50(%rbp)
L546:
  cmpl   $0x6,-0x50(%rbp)
  jle    L315
  cmpl   $0x5d,-0x48(%rbp)
  jne    L260
  movl   $0x0,-0x30(%rbp)
  mov    -0x58(%rbp),%eax
  sub    $0x4,%eax
  mov    %eax,-0x38(%rbp)
  jmp    L486
L777:
  cmpl   $0x0,-0x38(%rbp)
  jns    L158
  addl   $0x1,-0x30(%rbp)
  jmp    L0
L158:
  mov    -0x38(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    $0x30,%al
  jne    L462
  addl   $0x1,-0x30(%rbp)
  jmp    L0
L462:
  movl   $0x0,-0x30(%rbp)
L0:
  addl   $0x1,-0x38(%rbp)
L486:
  mov    -0x38(%rbp),%eax
  cmp    -0x58(%rbp),%eax
  jl     L777
  movl   $0x0,-0x34(%rbp)
  mov    -0x58(%rbp),%eax
  add    $0x7,%eax
  mov    %eax,-0x3c(%rbp)
  jmp    L81
L451:
  mov    -0x3c(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L729
  addl   $0x1,-0x34(%rbp)
  jmp    L243
L729:
  mov    -0x3c(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    $0x30,%al
  jne    L326
  addl   $0x1,-0x34(%rbp)
  jmp    L243
L326:
  movl   $0x0,-0x34(%rbp)
L243:
  addl   $0x1,-0x3c(%rbp)
L81:
  mov    -0x58(%rbp),%eax
  add    $0xa,%eax
  cmp    %eax,-0x3c(%rbp)
  jle    L451
  cmpl   $0x4,-0x30(%rbp)
  je     L389
  cmpl   $0x4,-0x34(%rbp)
  jne    L260
L389:
  addl   $0x28,-0x4c(%rbp)
L260:
  addl   $0x1,-0x58(%rbp)
L163:
  mov    -0x6c(%rbp),%eax
  sub    $0x7,%eax
  cmp    %eax,-0x58(%rbp)
  jl     L324
  addl   $0x1,-0x5c(%rbp)
L811:
  mov    -0x5c(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L425
  movl   $0x0,-0x58(%rbp)
  jmp    L231
L679:
  movl   $0x0,-0x5c(%rbp)
  jmp    L351
L49:
  movl   $0x0,-0x48(%rbp)
  movl   $0x0,-0x50(%rbp)
  jmp    L545
L335:
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %eax,%edx
  mov    -0x50(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    $0x31,%al
  jne    L239
  mov    -0x50(%rbp),%eax
  mov    $0x40,%edx
  mov    %eax,%ecx
  sar    %cl,%edx
  mov    %edx,%eax
  add    %eax,-0x48(%rbp)
L239:
  addl   $0x1,-0x50(%rbp)
L545:
  cmpl   $0x6,-0x50(%rbp)
  jle    L335
  cmpl   $0x5d,-0x48(%rbp)
  jne    L543
  movl   $0x0,-0x30(%rbp)
  mov    -0x5c(%rbp),%eax
  sub    $0x4,%eax
  mov    %eax,-0x38(%rbp)
  jmp    L578
L271:
  cmpl   $0x0,-0x38(%rbp)
  jns    L78
  addl   $0x1,-0x30(%rbp)
  jmp    L226
L78:
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    $0x30,%al
  jne    L585
  addl   $0x1,-0x30(%rbp)
  jmp    L226
L585:
  movl   $0x0,-0x30(%rbp)
L226:
  addl   $0x1,-0x38(%rbp)
L578:
  mov    -0x38(%rbp),%eax
  cmp    -0x5c(%rbp),%eax
  jl     L271
  movl   $0x0,-0x34(%rbp)
  mov    -0x5c(%rbp),%eax
  add    $0x7,%eax
  mov    %eax,-0x3c(%rbp)
  jmp    L453
L358:
  mov    -0x3c(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L393
  addl   $0x1,-0x34(%rbp)
  jmp    L258
L393:
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x3c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    $0x30,%al
  jne    L422
  addl   $0x1,-0x34(%rbp)
  jmp    L258
L422:
  movl   $0x0,-0x34(%rbp)
L258:
  addl   $0x1,-0x3c(%rbp)
L453:
  mov    -0x5c(%rbp),%eax
  add    $0xa,%eax
  cmp    %eax,-0x3c(%rbp)
  jle    L358
  cmpl   $0x4,-0x30(%rbp)
  je     L268
  cmpl   $0x4,-0x34(%rbp)
  jne    L543
L268:
  addl   $0x28,-0x4c(%rbp)
L543:
  addl   $0x1,-0x5c(%rbp)
L351:
  mov    -0x6c(%rbp),%eax
  sub    $0x7,%eax
  cmp    %eax,-0x5c(%rbp)
  jl     L49
  addl   $0x1,-0x58(%rbp)
L231:
  mov    -0x58(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L679
  movl   $0x0,-0x44(%rbp)
  movl   $0x0,-0x5c(%rbp)
  jmp    L275
L355:
  movl   $0x0,-0x58(%rbp)
  jmp    L69
L294:
  mov    -0x58(%rbp),%eax
  imul   -0x6c(%rbp),%eax
  mov    %eax,%edx
  mov    -0x5c(%rbp),%eax
  add    %edx,%eax
  mov    -0x20(%rbp),%rdx
  cltq
  movzbl (%rdx,%rax,1),%eax
  cmp    $0x31,%al
  jne    L367
  addl   $0x1,-0x44(%rbp)
L367:
  addl   $0x1,-0x58(%rbp)
L69:
  mov    -0x58(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L294
  addl   $0x1,-0x5c(%rbp)
L275:
  mov    -0x5c(%rbp),%eax
  cmp    -0x6c(%rbp),%eax
  jl     L355
  mov    -0x6c(%rbp),%eax
  imul   %eax,%eax
  mov    %eax,%ebx
  mov    -0x44(%rbp),%eax
  cltd
  idiv   %ebx
  imul   $0x64,%eax,%eax
  mov    %eax,-0x2c(%rbp)
  cmpl   $0x32,-0x2c(%rbp)
  jg     L518
  mov    $0x32,%eax
  sub    -0x2c(%rbp),%eax
  movslq %eax,%rdx
  imul   $0x66666667,%rdx,%rdx
  shr    $0x20,%rdx
  sar    %edx
  sar    $0x1f,%eax
  mov    %eax,%ecx
  mov    %edx,%eax
  sub    %ecx,%eax
  mov    %eax,-0x40(%rbp)
  jmp    L26
L518:
  mov    -0x2c(%rbp),%eax
  sub    $0x32,%eax
  movslq %eax,%rdx
  imul   $0x66666667,%rdx,%rdx
  shr    $0x20,%rdx
  sar    %edx
  sar    $0x1f,%eax
  mov    %eax,%ecx
  mov    %edx,%eax
  sub    %ecx,%eax
  mov    %eax,-0x40(%rbp)
L26:
  mov    -0x40(%rbp),%edx
  mov    %edx,%eax
  shl    $0x2,%eax
  add    %edx,%eax
  add    %eax,%eax
  add    %eax,-0x4c(%rbp)
  mov    -0x4c(%rbp),%eax
  mov    %rsi,%rsp
  mov    -0x18(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L812
  call   <__stack_chk_fail@plt>
L812:
  mov    -0x8(%rbp),%rbx
  leave
  ret
```

assistant: ```c
int evaluate(unsigned char *eval, const int size, const int pattern) {
  int x, y, block, weight;
  int result = 0;
  char state;
  int p;
  int dark_mods;
  int percentage, k;
  int a, b, afterCount, beforeCount;
  char local[size * size];
  for (x = 0; x < size; x++) {
    for (y = 0; y < size; y++) {
      if ((eval[(y * size) + x] & (0x01 << pattern)) != 0) {
        local[(y * size) + x] = '1';
      } else {
        local[(y * size) + x] = '0';
      }
    }
  }
  for (x = 0; x < size; x++) {
    state = local[x];
    block = 0;
    for (y = 0; y < size; y++) {
      if (local[(y * size) + x] == state) {
        block++;
      } else {
        if (block > 5) {
          result += (3 + (block - 5));
        }
        block = 0;
        state = local[(y * size) + x];
      }
    }
    if (block > 5) {
      result += (3 + (block - 5));
    }
  }
  for (y = 0; y < size; y++) {
    state = local[y * size];
    block = 0;
    for (x = 0; x < size; x++) {
      if (local[(y * size) + x] == state) {
        block++;
      } else {
        if (block > 5) {
          result += (3 + (block - 5));
        }
        block = 0;
        state = local[(y * size) + x];
      }
    }
    if (block > 5) {
      result += (3 + (block - 5));
    }
  }
  for (x = 0; x < size - 1; x++) {
    for (y = 0; y < size - 1; y++) {
      if (((local[(y * size) + x] == local[((y + 1) * size) + x]) && (local[(y * size) + x] == local[(y * size) + (x + 1)])) && (local[(y * size) + x] == local[((y + 1) * size) + (x + 1)])) {
        result += 3;
      }
    }
  }
  for (x = 0; x < size; x++) {
    for (y = 0; y < (size - 7); y++) {
      p = 0;
      for (weight = 0; weight < 7; weight++) {
        if (local[((y + weight) * size) + x] == '1') {
          p += (0x40 >> weight);
        }
      }
      if (p == 0x5d) {
        beforeCount = 0;
        for (b = (y - 4); b < y; b++) {
          if (b < 0) {
            beforeCount++;
          } else {
            if (local[(b * size) + x] == '0') {
              beforeCount++;
            } else {
              beforeCount = 0;
            }
          }
        }
        afterCount = 0;
        for (a = (y + 7); a <= (y + 10); a++) {
          if (a >= size) {
            afterCount++;
          } else {
            if (local[(a * size) + x] == '0') {
              afterCount++;
            } else {
              afterCount = 0;
            }
          }
        }
        if ((beforeCount == 4) || (afterCount == 4)) {
          result += 40;
        }
      }
    }
  }
  for (y = 0; y < size; y++) {
    for (x = 0; x < (size - 7); x++) {
      p = 0;
      for (weight = 0; weight < 7; weight++) {
        if (local[(y * size) + x + weight] == '1') {
          p += (0x40 >> weight);
        }
      }
      if (p == 0x5d) {
        beforeCount = 0;
        for (b = (x - 4); b < x; b++) {
          if (b < 0) {
            beforeCount++;
          } else {
            if (local[(y * size) + b] == '0') {
              beforeCount++;
            } else {
              beforeCount = 0;
            }
          }
        }
        afterCount = 0;
        for (a = (x + 7); a <= (x + 10); a++) {
          if (a >= size) {
            afterCount++;
          } else {
            if (local[(y * size) + a] == '0') {
              afterCount++;
            } else {
              afterCount = 0;
            }
          }
        }
        if ((beforeCount == 4) || (afterCount == 4)) {
          result += 40;
        }
      }
    }
  }
  dark_mods = 0;
  for (x = 0; x < size; x++) {
    for (y = 0; y < size; y++) {
      if (local[(y * size) + x] == '1') {
        dark_mods++;
      }
    }
  }
  percentage = 100 * (dark_mods / (size * size));
  if (percentage <= 50) {
    k = ((100 - percentage) - 50) / 5;
  } else {
    k = (percentage - 50) / 5;
  }
  result += 10 * k;
  return result;
}
```