user: 请从给定的汇编指令推导出C源代码：

```asm
<flu_parse_tstamp>:
  endbr64
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x10,%rsp
  mov    %rdi,%rbp
  mov    %esi,%r14d
  mov    %fs:0x28,%rax
  mov    %rax,0x8(%rsp)
  xor    %eax,%eax
  mov    $0x2d,%esi
  call   <strchr@plt>
  test   %rax,%rax
  je     L85
  lea    0x4(%rsp),%rsi
  mov    %rbp,%rdi
  call   <ptime@plt>
  mov    $0x0,%ebx
  mov    $0x0,%r13d
  test   %eax,%eax
  je     L61
L80:
  mov    0x8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L144
  mov    %rbx,%rax
  add    $0x10,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
L85:
  mov    %rax,%r12
  mov    $0x2e,%esi
  mov    %rbp,%rdi
  call   <strchr@plt>
  mov    %rax,%rbx
  mov    $0x2e,%esi
  mov    %rbp,%rdi
  call   <strrchr@plt>
  test   %rbx,%rbx
  je     L80
  lea    0x1(%rax),%r13
  cmp    %rax,%rbx
  cmove  %r12,%r13
  lea    0x4(%rsp),%rsi
  mov    %rbp,%rdi
  call   <ptime@plt>
  test   %eax,%eax
  jne    L112
  test   %r14d,%r14d
  jne    L61
  lea    0x4(%rsp),%rdi
  call   <mktime@plt>
  mov    %eax,%ebp
  jmp    L159
L61:
  lea    D9(%rip),%rbx
  mov    %rbx,%rdi
  call   <getenv@plt>
  mov    %rax,%r12
  mov    $0x1,%edx
  lea    D15(%rip),%rsi
  mov    %rbx,%rdi
  call   <setenv@plt>
  mov    $0x0,%eax
  call   <tzset@plt>
  lea    0x4(%rsp),%rdi
  call   <mktime@plt>
  mov    %eax,%ebp
  test   %r12,%r12
  je     L102
  mov    $0x1,%edx
  mov    %r12,%rsi
  lea    D9(%rip),%rdi
  call   <setenv@plt>
L130:
  mov    $0x0,%eax
  call   <tzset@plt>
L159:
  mov    $0x8,%esi
  mov    $0x1,%edi
  call   <calloc@plt>
  mov    %rax,%rbx
  mov    %ebp,0x4(%rax)
  movl   $0x0,(%rax)
  test   %r13,%r13
  je     L80
  mov    %r13,%rdi
  call   <strlen@plt>
  mov    %rax,%rbp
  mov    $0xa,%edx
  mov    $0x0,%esi
  mov    %r13,%rdi
  call   <strtoll@plt>
  cmp    $0x3,%rbp
  je     L96
  cmp    $0x6,%rbp
  je     L35
  mov    %eax,(%rbx)
  jmp    L80
L102:
  mov    %rbx,%rdi
  call   <unsetenv@plt>
  jmp    L130
L96:
  imul   $0xf4240,%eax,%eax
  mov    %eax,(%rbx)
  jmp    L80
L35:
  imul   $0x3e8,%eax,%eax
  mov    %eax,(%rbx)
  jmp    L80
L112:
  mov    %r12,%rbx
  jmp    L80
L144:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: label: D9
type_infered: string
name: extract_symbolic_data
arguments: label: D15
type_infered: string

tool: D9: TZ

tool: D15: UTC

assistant: ```c
struct timespec *flu_parse_tstamp(char *s, int utc) {
  struct tm tm;
  char *subseconds = NULL;
  if (strchr(s, '-')) {
    utc = 1;
  } else {
    char *a = strchr(s, '.');
    char *b = strrchr(s, '.');
    if (a == NULL)
      return NULL;
    if (a != b)
      subseconds = b + 1;
  }
  int r = ptime(s, &tm);
  if (r != 0)
    return NULL;
  char *tz = NULL;
  if (utc) {
    tz = getenv("TZ");
    setenv("TZ", "UTC", 1);
    tzset();
  }
  time_t t = mktime(&tm);
  if (utc) {
    if (!tz)
      unsetenv("TZ");
    else
      setenv("TZ", tz, 1);
    tzset();
  }
  struct timespec *ts = calloc(1, sizeof(struct timespec));
  ts->tv_sec = t;
  ts->tv_nsec = 0;
  if (subseconds) {
    size_t st = strlen(subseconds);
    ts->tv_nsec = strtoll(subseconds, NULL, 10);
    if (st == 3)
      ts->tv_nsec = ts->tv_nsec * 1000 * 1000;
    else if (st == 6)
      ts->tv_nsec = ts->tv_nsec * 1000;
  }
  return ts;
}
```