user: What would the C source look like for the assembly code provided here?

```asm
<SARParseLatitudeDMS>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x78,%rsp
  mov    %rdi,0x8(%rsp)
  mov    %rsi,%r15
  mov    %fs:0x28,%rax
  mov    %rax,0x68(%rsp)
  xor    %eax,%eax
  test   %rsi,%rsi
  je     L106
  movl   $0x0,(%rsi)
L106:
  mov    0x8(%rsp),%rbx
  test   %rbx,%rbx
  je     L194
  movzbl (%rbx),%edi
  test   %dil,%dil
  je     L35
  mov    $0x0,%r13d
  mov    $0x0,%r12d
  mov    $0x0,%ebp
  mov    $0x1,%r14d
L14:
  cmp    $0x20,%dil
  je     L120
  cmp    $0x9,%dil
  je     L120
  movsbl %dil,%edi
  call   <toupper@plt>
  cmp    $0x27,%al
  cmove  %r14d,%r12d
  movsbl (%rbx),%edi
  call   <toupper@plt>
  cmp    $0x53,%al
  cmove  %r14d,%r13d
  add    $0x1,%rbx
  add    $0x1,%ebp
  movzbl (%rbx),%edi
  test   %dil,%dil
  jne    L14
L120:
  test   %ebp,%ebp
  jg     L226
  movb   $0x0,0x10(%rsp)
L249:
  mov    $0x4f,%eax
  cmp    %eax,%ebp
  cmovg  %eax,%ebp
  movslq %ebp,%rbp
  movb   $0x0,0x10(%rsp,%rbp,1)
  test   %r12d,%r12d
  jne    L24
  test   %r15,%r15
  je     L131
  lea    0x10(%rsp),%rdi
  call   <atof@plt>
  test   %r13d,%r13d
  je     L276
  comiss D6(%rip),%xmm0
  jbe    L276
  xorps  D44(%rip),%xmm0
  movss  %xmm0,(%r15)
  jmp    L131
L226:
  mov    $0x50,%edx
  cmp    %edx,%ebp
  cmovle %ebp,%edx
  lea    0x10(%rsp),%rdi
  mov    0x8(%rsp),%rsi
  call   <strncpy@plt>
  jmp    L249
L24:
  lea    0x10(%rsp),%rdi
  mov    $0x27,%esi
  call   <strchr@plt>
  mov    %rax,%rbx
  test   %rax,%rax
  je     L70
  movb   $0x0,(%rax)
  lea    0x10(%rsp),%rdi
  call   <atoi@plt>
  mov    %eax,%ebp
  add    $0x1,%rbx
  mov    $0x22,%esi
  mov    %rbx,%rdi
  call   <strchr@plt>
  mov    %rax,%r12
  test   %rax,%rax
  je     L38
  movb   $0x0,(%rax)
  mov    %rbx,%rdi
  call   <atoi@plt>
  mov    %eax,%ebx
  add    $0x1,%r12
  mov    $0x22,%esi
  mov    %r12,%rdi
  call   <strchr@plt>
  test   %rax,%rax
  je     L260
  movb   $0x0,(%rax)
  mov    %r12,%rdi
  call   <atoi@plt>
L141:
  mov    $0x0,%r12d
  test   %r15,%r15
  je     L131
  test   %r13d,%r13d
  je     L64
  pxor   %xmm0,%xmm0
  cvtsi2ss %ebp,%xmm0
  comiss D6(%rip),%xmm0
  jbe    L64
  neg    %ebp
  pxor   %xmm0,%xmm0
  cvtsi2ss %ebp,%xmm0
  pxor   %xmm1,%xmm1
  cvtsi2ss %ebx,%xmm1
  movss  D12(%rip),%xmm2
  divss  %xmm2,%xmm1
  subss  %xmm1,%xmm0
  pxor   %xmm1,%xmm1
  cvtsi2ss %eax,%xmm1
  divss  %xmm2,%xmm1
  divss  D70(%rip),%xmm1
  subss  %xmm1,%xmm0
  movss  %xmm0,(%r15)
  jmp    L131
L70:
  lea    0x10(%rsp),%rdi
  call   <atoi@plt>
  mov    %eax,%ebp
  mov    $0x0,%ebx
  mov    $0x0,%eax
  jmp    L141
L38:
  mov    %rbx,%rdi
  call   <atoi@plt>
  mov    %eax,%ebx
  mov    $0x0,%eax
  jmp    L141
L260:
  mov    %r12,%rdi
  call   <atoi@plt>
  jmp    L141
L64:
  test   %ebp,%ebp
  js     L10
  pxor   %xmm0,%xmm0
  cvtsi2ss %ebx,%xmm0
  movss  D12(%rip),%xmm2
  divss  %xmm2,%xmm0
  pxor   %xmm1,%xmm1
  cvtsi2ss %ebp,%xmm1
  addss  %xmm1,%xmm0
  pxor   %xmm1,%xmm1
  cvtsi2ss %eax,%xmm1
  divss  %xmm2,%xmm1
  divss  D70(%rip),%xmm1
  addss  %xmm1,%xmm0
  movss  %xmm0,(%r15)
  mov    $0x0,%r12d
  jmp    L131
L10:
  pxor   %xmm0,%xmm0
  cvtsi2ss %ebp,%xmm0
  pxor   %xmm1,%xmm1
  cvtsi2ss %ebx,%xmm1
  movss  D12(%rip),%xmm2
  divss  %xmm2,%xmm1
  subss  %xmm1,%xmm0
  pxor   %xmm1,%xmm1
  cvtsi2ss %eax,%xmm1
  divss  %xmm2,%xmm1
  divss  D70(%rip),%xmm1
  subss  %xmm1,%xmm0
  movss  %xmm0,(%r15)
  mov    $0x0,%r12d
  jmp    L131
L276:
  movss  %xmm0,(%r15)
L131:
  mov    0x68(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L164
  mov    %r12d,%eax
  add    $0x78,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L194:
  mov    $0xffffffff,%r12d
  jmp    L131
L35:
  mov    $0xffffffff,%r12d
  jmp    L131
L164:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: parse_data
arguments: label: D6
type_guessed: byte[4]
name: parse_data
arguments: label: D44
type_guessed: byte[16]
name: parse_data
arguments: label: D12
type_guessed: byte[4]
name: parse_data
arguments: label: D70
type_guessed: byte[4]

tool: {"D6": [0x00,0x00,0x00,0x00]}

tool: {"D44": [0x00,0x00,0x00,0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00]}

tool: {"D12": [0x00,0x00,0x70,0x42]}

tool: {"D70": [0x00,0x00,0xc8,0x42]}

assistant: ```c
int SARParseLatitudeDMS(const char *string, float *dms) {
  const char *sp;
  int in_len, is_traditional = 0, is_south = 0;
  int lstring_len = 80;
  char *sp2, *sp3;
  char lstring[80];
  if (dms != NULL)
    *dms = 0.0f;
  if ((string != NULL) ? (*string == '\0') : 1)
    return (-1);
  sp = string;
  in_len = 0;
  while ((*sp != '\0') && !(((*sp) == ' ') || ((*sp) == '\t'))) {
    if (toupper(*sp) == '\'')
      is_traditional = 1;
    if (toupper(*sp) == 'S')
      is_south = 1;
    sp++;
    in_len++;
  }
  if (in_len > 0)
    strncpy(lstring, string, (((in_len) < (lstring_len)) ? (in_len) : (lstring_len)));
  else
    *lstring = '\0';
  lstring[(((in_len) < (lstring_len - 1)) ? (in_len) : (lstring_len - 1))] = '\0';
  if (is_traditional) {
    int d = 0, m = 0, s = 0;
    sp2 = lstring;
    if (sp2 != NULL) {
      sp3 = strchr(sp2, '\'');
      if (sp3 != NULL) {
        *sp3 = '\0';
        d = (((sp2) != NULL) ? atoi(sp2) : 0);
        sp2 = sp3 + 1;
      } else {
        d = (((sp2) != NULL) ? atoi(sp2) : 0);
        sp2 = NULL;
      }
    }
    if (sp2 != NULL) {
      sp3 = strchr(sp2, '"');
      if (sp3 != NULL) {
        *sp3 = '\0';
        m = (((sp2) != NULL) ? atoi(sp2) : 0);
        sp2 = sp3 + 1;
      } else {
        m = (((sp2) != NULL) ? atoi(sp2) : 0);
        sp2 = NULL;
      }
    }
    if (sp2 != NULL) {
      sp3 = strchr(sp2, '"');
      if (sp3 != NULL) {
        *sp3 = '\0';
        s = (((sp2) != NULL) ? atoi(sp2) : 0);
        sp2 = sp3 + 1;
      } else {
        s = (((sp2) != NULL) ? atoi(sp2) : 0);
        sp2 = NULL;
      }
    }
    if (dms != NULL) {
      if (is_south && (d > 0.0f))
        *dms = (float)-d - ((float)m / 60.0f) - ((float)s / 60.0f / 100.0f);
      else if (d < 0)
        *dms = (float)d - ((float)m / 60.0f) - ((float)s / 60.0f / 100.0f);
      else
        *dms = (float)d + ((float)m / 60.0f) + ((float)s / 60.0f / 100.0f);
    }
  } else {
    sp2 = lstring;
    if (dms != NULL) {
      float d = (float)(((sp2) != NULL) ? atof(sp2) : 0.0f);
      if (is_south && (d > 0.0f))
        *dms = -d;
      else
        *dms = d;
    }
  }
  return (0);
}
```