user: 请将以下的汇编代码转换成C语言代码：

```asm
<findMedianSortedArrays>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x38,%rsp
  mov    %rdi,0x18(%rsp)
  mov    %esi,0xc(%rsp)
  mov    %rdx,0x10(%rsp)
  mov    %ecx,0x24(%rsp)
  cmp    %ecx,%esi
  jl     L80
  mov    %ecx,0xc(%rsp)
  mov    %esi,0x24(%rsp)
  mov    %rdx,0x18(%rsp)
  mov    %rdi,0x10(%rsp)
L80:
  mov    0x24(%rsp),%eax
  mov    0xc(%rsp),%ebx
  lea    0x1(%rbx,%rax,1),%edx
  mov    %ebx,%ecx
  add    %eax,%ecx
  mov    %edx,%eax
  shr    $0x1f,%eax
  mov    %ecx,0x28(%rsp)
  add    %edx,%eax
  sar    %eax
  mov    %eax,0x2c(%rsp)
  mov    %eax,%edx
  sub    $0x1,%ebx
  js     L87
  lea    0x1(%rcx),%edx
  xor    %ebp,%ebp
  lea    D38(%rip),%r13
  mov    %edx,%eax
  shr    $0x1f,%eax
  add    %edx,%eax
  sar    %eax
  mov    %eax,0x20(%rsp)
  jmp    L182
  nopl   0x0(%rax)
L228:
  mov    0x18(%rsp),%rcx
  movslq %r14d,%rax
  movslq %r12d,%rdx
  xor    %r10d,%r10d
  lea    0x0(,%rdx,4),%rdi
  mov    -0x4(%rcx,%rax,4),%r15d
  mov    0x10(%rsp),%rcx
  mov    (%rcx,%rdx,4),%r12d
  cmp    %r12d,%r15d
  setle  %r10b
  test   %sil,%sil
  je     L44
L180:
  mov    $0x1,%edx
  mov    %r10d,%esi
  mov    %r13,%rdi
  call   <printf@plt>
  cmp    %r12d,%r15d
  jle    L20
L229:
  lea    -0x1(%r14),%ebx
  cmp    %ebx,%ebp
  jg     L64
L182:
  mov    %ebx,%edx
  lea    D50(%rip),%rdi
  lea    0x0(%rbp,%rbx,1),%r15d
  mov    %ebp,%esi
  call   <printf@plt>
  mov    %r15d,%r14d
  mov    0x20(%rsp),%r12d
  lea    D48(%rip),%rdi
  sar    %r14d
  sub    %r14d,%r12d
  mov    %r14d,%esi
  mov    %r12d,%edx
  call   <printf@plt>
  test   %r12d,%r12d
  setle  %sil
  cmp    %r14d,0xc(%rsp)
  setle  %al
  or     %eax,%esi
  cmp    $0x1,%r15d
  jle    L90
  cmp    %r12d,0x24(%rsp)
  jg     L228
L90:
  test   %sil,%sil
  jne    L68
  mov    0x10(%rsp),%rdi
  mov    0x18(%rsp),%rcx
  movslq %r12d,%rdx
  movslq %r14d,%rax
  mov    -0x4(%rdi,%rdx,4),%edi
  cmp    %edi,(%rcx,%rax,4)
  jge    L68
  xor    %edx,%edx
  mov    $0x1,%esi
  mov    %r13,%rdi
  call   <printf@plt>
L215:
  lea    0x1(%r14),%ebp
  cmp    %ebx,%ebp
  jle    L182
L64:
  mov    0x2c(%rsp),%edx
  sub    %ebp,%edx
  test   %ebp,%ebp
  je     L87
L30:
  mov    0x18(%rsp),%rcx
  movslq %ebp,%rax
  mov    -0x4(%rcx,%rax,4),%r13d
  test   %edx,%edx
  jle    L174
  mov    0x10(%rsp),%rcx
  movslq %edx,%rax
  mov    -0x4(%rcx,%rax,4),%eax
  cmp    %eax,%r13d
  cmovl  %eax,%r13d
L174:
  cmp    %ebp,0xc(%rsp)
  jg     L115
  mov    0x10(%rsp),%rcx
  movslq %edx,%rax
  mov    (%rcx,%rax,4),%ebx
L58:
  mov    %ebp,%esi
  lea    D3(%rip),%rdi
  call   <printf@plt>
  mov    %ebx,%edx
  mov    %r13d,%esi
  lea    D43(%rip),%rdi
  call   <printf@plt>
  testb  $0x1,0x28(%rsp)
  je     L10
  add    $0x38,%rsp
  pxor   %xmm0,%xmm0
  pop    %rbx
  cvtsi2sd %r13d,%xmm0
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopw   0x0(%rax,%rax,1)
L115:
  mov    0x18(%rsp),%rcx
  movslq %ebp,%rax
  mov    (%rcx,%rax,4),%ebx
  cmp    %edx,0x24(%rsp)
  jle    L58
  mov    0x10(%rsp),%rcx
  movslq %edx,%rax
  mov    (%rcx,%rax,4),%eax
  cmp    %eax,%ebx
  cmovg  %eax,%ebx
  jmp    L58
  nopl   0x0(%rax,%rax,1)
L10:
  add    %ebx,%r13d
  pxor   %xmm0,%xmm0
  cvtsi2sd %r13d,%xmm0
  mulsd  D21(%rip),%xmm0
  add    $0x38,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax,%rax,1)
L68:
  mov    $0x1,%edx
  mov    $0x1,%esi
  mov    %r13,%rdi
  mov    %r14d,%ebp
  call   <printf@plt>
  mov    0x2c(%rsp),%edx
  sub    %ebp,%edx
  test   %ebp,%ebp
  jne    L30
L87:
  mov    0x10(%rsp),%rcx
  movslq %edx,%rax
  xor    %ebp,%ebp
  mov    -0x4(%rcx,%rax,4),%r13d
  jmp    L174
  nopw   0x0(%rax,%rax,1)
L44:
  mov    0x18(%rsp),%rdx
  mov    (%rdx,%rax,4),%eax
  cmp    %eax,-0x4(%rcx,%rdi,1)
  jle    L180
  xor    %edx,%edx
  mov    %r10d,%esi
  mov    %r13,%rdi
  call   <printf@plt>
  cmp    %r12d,%r15d
  jg     L229
  jmp    L215
L20:
  mov    %r14d,%ebp
  jmp    L64
```

tool_calls: name: disassemble_data
arguments: label: D38
data_type: string
name: disassemble_data
arguments: label: D50
data_type: string
name: disassemble_data
arguments: label: D48
data_type: string
name: disassemble_data
arguments: label: D3
data_type: string
name: disassemble_data
arguments: label: D43
data_type: string
name: disassemble_data
arguments: label: D21
data_type: byte[8]

tool: D38: f1: %d, f2: %d


tool: D50: lo: %d, hi: %d


tool: D48: i: %d, j: %d


tool: D3: fi: %d, fj: %d


tool: D43: maxL: %d, minR: %d


tool: {"D21": [0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x3f]}

assistant: ```c
double findMedianSortedArrays(int *nums1, int nums1Size, int *nums2, int nums2Size) {
  int lo, hi;
  if (nums1Size >= nums2Size) {
    int *p = nums1;
    nums1 = nums2;
    nums2 = p;
    int t = nums1Size;
    nums1Size = nums2Size;
    nums2Size = t;
  }
  lo = 0;
  hi = nums1Size - 1;
  int aidx = -1;
  while (lo <= hi) {
    printf("lo: %d, hi: %d\n", lo, hi);
    int i = (lo + hi) / 2;
    int j = (nums1Size + nums2Size + 1) / 2 - i;
    printf("i: %d, j: %d\n", i, j);
    int f1, f2;
    f1 = i - 1 < 0 || j >= nums2Size || nums1[i - 1] <= nums2[j];
    f2 = j - 1 < 0 || i >= nums1Size || nums2[j - 1] <= nums1[i];
    printf("f1: %d, f2: %d\n", f1, f2);
    if (f1 && f2) {
      aidx = i;
      break;
    }
    if (!f1) {
      hi = i - 1;
    } else if (!f2) {
      lo = i + 1;
    }
  }
  if (aidx == -1)
    aidx = lo;
  int i = aidx;
  int j = (1 + nums1Size + nums2Size) / 2 - i;
  int maxL, minR;
  if (i < 1)
    maxL = nums2[j - 1];
  else if (j < 1)
    maxL = nums1[i - 1];
  else
    maxL = ((nums1[i - 1]) > (nums2[j - 1]) ? (nums1[i - 1]) : (nums2[j - 1]));
  if (i >= nums1Size)
    minR = nums2[j];
  else if (j >= nums2Size)
    minR = nums1[i];
  else
    minR = ((nums1[i]) < (nums2[j]) ? (nums1[i]) : (nums2[j]));
  printf("fi: %d, fj: %d\n", i, j);
  printf("maxL: %d, minR: %d\n", maxL, minR);
  if ((nums1Size + nums2Size) & 1) {
    return maxL;
  } else {
    return (maxL + minR) / 2.0;
  }
}
```