user: 请将这段汇编代码片段转换成等效的C代码：

```asm
<print_array_dual>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %r13
  push   %r12
  push   %rbx
  sub    $0xc8,%rsp
  mov    %rdi,-0xd8(%rbp)
  mov    %esi,-0xdc(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x28(%rbp)
  xor    %eax,%eax
  mov    -0xdc(%rbp),%eax
  cltq
  shr    $0x2,%rax
  mov    %eax,-0xdc(%rbp)
  movl   $0x0,-0xc0(%rbp)
  jmp    L18
L82:
  movq   $0x0,-0xb0(%rbp)
  movq   $0x0,-0xa8(%rbp)
  movq   $0x0,-0xa0(%rbp)
  movq   $0x0,-0x98(%rbp)
  movq   $0x0,-0x90(%rbp)
  movq   $0x0,-0x88(%rbp)
  movq   $0x0,-0x80(%rbp)
  movq   $0x0,-0x78(%rbp)
  movq   $0x0,-0x70(%rbp)
  movq   $0x0,-0x68(%rbp)
  movq   $0x0,-0x60(%rbp)
  movq   $0x0,-0x58(%rbp)
  movq   $0x0,-0x50(%rbp)
  movq   $0x0,-0x48(%rbp)
  movq   $0x0,-0x40(%rbp)
  movq   $0x0,-0x38(%rbp)
  mov    -0xc0(%rbp),%eax
  mov    %eax,-0xc4(%rbp)
  jmp    L120
L48:
  mov    -0xc4(%rbp),%eax
  cmp    -0xdc(%rbp),%eax
  jge    L99
  mov    -0xc4(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0xd8(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  mov    %eax,%edi
  call   <ntoh32@plt>
  mov    %eax,-0xbc(%rbp)
  jmp    L42
L99:
  movl   $0xffffffff,-0xbc(%rbp)
L42:
  mov    -0xbc(%rbp),%eax
  sar    $0x18,%eax
  movzbl %al,%esi
  mov    -0xbc(%rbp),%eax
  sar    $0x10,%eax
  movzbl %al,%ecx
  mov    -0xbc(%rbp),%eax
  sar    $0x8,%eax
  movzbl %al,%edx
  mov    -0xbc(%rbp),%eax
  movzbl %al,%eax
  mov    %esi,%r8d
  mov    %eax,%esi
  lea    D18(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <print@plt>
  mov    -0xbc(%rbp),%eax
  sar    $0x18,%eax
  cmp    $0x1f,%al
  jbe    L106
  mov    -0xbc(%rbp),%eax
  sar    $0x18,%eax
  movzbl %al,%eax
  mov    %eax,%edi
  call   <isascii@plt>
  test   %rax,%rax
  je     L106
  mov    -0xbc(%rbp),%eax
  sar    $0x18,%eax
  movzbl %al,%r13d
  jmp    L71
L106:
  mov    $0x2e,%r13d
L71:
  mov    -0xbc(%rbp),%eax
  sar    $0x10,%eax
  cmp    $0x1f,%al
  jbe    L16
  mov    -0xbc(%rbp),%eax
  sar    $0x10,%eax
  movzbl %al,%eax
  mov    %eax,%edi
  call   <isascii@plt>
  test   %rax,%rax
  je     L16
  mov    -0xbc(%rbp),%eax
  sar    $0x10,%eax
  movzbl %al,%r12d
  jmp    L186
L16:
  mov    $0x2e,%r12d
L186:
  mov    -0xbc(%rbp),%eax
  sar    $0x8,%eax
  cmp    $0x1f,%al
  jbe    L119
  mov    -0xbc(%rbp),%eax
  sar    $0x8,%eax
  movzbl %al,%eax
  mov    %eax,%edi
  call   <isascii@plt>
  test   %rax,%rax
  je     L119
  mov    -0xbc(%rbp),%eax
  sar    $0x8,%eax
  movzbl %al,%ebx
  jmp    L8
L119:
  mov    $0x2e,%ebx
L8:
  mov    -0xbc(%rbp),%eax
  cmp    $0x1f,%al
  jbe    L166
  mov    -0xbc(%rbp),%eax
  movzbl %al,%eax
  mov    %eax,%edi
  call   <isascii@plt>
  test   %rax,%rax
  je     L166
  mov    -0xbc(%rbp),%eax
  movzbl %al,%eax
  jmp    L12
L166:
  mov    $0x2e,%eax
L12:
  lea    -0xb6(%rbp),%rdi
  mov    %r13d,%r9d
  mov    %r12d,%r8d
  mov    %ebx,%ecx
  mov    %eax,%edx
  lea    D14(%rip),%rax
  mov    %rax,%rsi
  call   <sprintf@plt>
  lea    -0xb6(%rbp),%rdx
  lea    -0xb0(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcat@plt>
  addl   $0x1,-0xc4(%rbp)
L120:
  mov    -0xc0(%rbp),%eax
  add    $0x3,%eax
  cmp    %eax,-0xc4(%rbp)
  jle    L48
  lea    -0xb0(%rbp),%rax
  mov    %rax,%rsi
  lea    D22(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <print@plt>
  addl   $0x4,-0xc0(%rbp)
L18:
  mov    -0xc0(%rbp),%eax
  cmp    -0xdc(%rbp),%eax
  jl     L82
  nop
  mov    -0x28(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L154
  call   <__stack_chk_fail@plt>
L154:
  add    $0xc8,%rsp
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %rbp
  ret
```

tool_calls: name: read_data
arguments: data_label: D18
data_type: string
name: read_data
arguments: data_label: D14
data_type: string
name: read_data
arguments: data_label: D22
data_type: string

tool: D18: %02x %02x %02x %02x - 

tool: D14: %c%c%c%c 

tool: D22: %s


assistant: ```c
void print_array_dual(const unsigned char *array, int size) {
  int idx;
  int block;
  size /= sizeof(u_int32_t);
  for (block = 0; block < size; block += 4) {
    char ascii4[6];
    char ascii[128] = {
        0,
    };
    for (idx = block; idx < block + 4; idx++) {
      u_int32_t v;
      if (idx < size)
        v = ntoh32(((u_int32_t *)array)[idx]);
      else
        v = 0xffffffff;
      print("%02x %02x %02x %02x - ", ((unsigned char)(v)), ((unsigned char)(v >> 8)), ((unsigned char)(v >> 16)), ((unsigned char)(v >> 24)));
      sprintf(ascii4, "%c%c%c%c ", ((((unsigned char)(v)) >= 32 && isascii((unsigned char)(v))) ? ((unsigned char)(v)) : '.'), ((((unsigned char)(v >> 8)) >= 32 && isascii((unsigned char)(v >> 8))) ? ((unsigned char)(v >> 8)) : '.'), ((((unsigned char)(v >> 16)) >= 32 && isascii((unsigned char)(v >> 16))) ? ((unsigned char)(v >> 16)) : '.'), ((((unsigned char)(v >> 24)) >= 32 && isascii((unsigned char)(v >> 24))) ? ((unsigned char)(v >> 24)) : '.'));
      strcat(ascii, ascii4);
    }
    print("%s\n", ascii);
  }
}
```