#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */
struct tm {
  int tm_wday;
  int tm_mon;
  size_t tm_mday;
  size_t tm_hour;
  size_t tm_min;
  size_t tm_sec;
  int tm_year;
  int tm_gmtoff;
  char *tm_zone;
  int /*<<< orphan*/ tm_yday;
};

/* Variables and functions */
char *getenv(char *);
int /*<<< orphan*/ islower(char);
int iso8601wknum(struct tm const *);
scalar_t__ malloc(int);
size_t max(int, int /*<<< orphan*/);
int /*<<< orphan*/ min(size_t, int);
scalar_t__ realloc(char *, int);
int /*<<< orphan*/ sprintf(char *, char *, long, ...);
int /*<<< orphan*/ *strchr(char const *, char);
scalar_t__ strcmp(char *, char *);
int /*<<< orphan*/ strcpy(char *, char const *);
int strlen(char const *);
char toupper(char);
int /*<<< orphan*/ tzset();
int weeknumber(struct tm const *, int);
size_t strftime(char *s, size_t maxsize, const char *format,
                const struct tm *timeptr) {
  char *endp = s + maxsize;
  char *start = s;
  auto char tbuf[100];
  long off;
  int i, w;
  long y;
  static short first = 1;
  static char *savetz = NULL;
  static int savetzlen = 0;
  char *tz;
  static const char *days_a[] = {
      "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat",
  };
  static const char *days_l[] = {
      "Sunday",   "Monday", "Tuesday",  "Wednesday",
      "Thursday", "Friday", "Saturday",
  };
  static const char *months_a[] = {
      "Jan", "Feb", "Mar", "Apr", "May", "Jun",
      "Jul", "Aug", "Sep", "Oct", "Nov", "Dec",
  };
  static const char *months_l[] = {
      "January", "February", "March",     "April",   "May",      "June",
      "July",    "August",   "September", "October", "November", "December",
  };
  static const char *ampm[] = {
      "AM",
      "PM",
  };
  if (s == NULL || format == NULL || timeptr == NULL || maxsize == 0)
    return 0;
  if (strchr(format, '%') == NULL && strlen(format) + 1 >= maxsize)
    return 0;
  tz = getenv("TZ");
  if (first) {
    if (tz != NULL) {
      int tzlen = strlen(tz);
      savetz = (char *)malloc(tzlen + 1);
      if (savetz != NULL) {
        savetzlen = tzlen + 1;
        strcpy(savetz, tz);
      }
    }
    tzset();
    first = 0;
  }
  if (tz && savetz && (tz[0] != savetz[0] || strcmp(tz, savetz) != 0)) {
    i = strlen(tz) + 1;
    if (i > savetzlen) {
      savetz = (char *)realloc(savetz, i);
      if (savetz) {
        savetzlen = i;
        strcpy(savetz, tz);
      }
    } else
      strcpy(savetz, tz);
    tzset();
  }
  for (; *format && s < endp - 1; format++) {
    tbuf[0] = '\0';
    if (*format != '%') {
      *s++ = *format;
      continue;
    }
  again:
    switch (*++format) {
    case '\0':
      *s++ = '%';
      goto out;
    case '%':
      *s++ = '%';
      continue;
    case 'a':
      if (timeptr->tm_wday < 0 || timeptr->tm_wday > 6)
        strcpy(tbuf, "?");
      else
        strcpy(tbuf, days_a[timeptr->tm_wday]);
      break;
    case 'A':
      if (timeptr->tm_wday < 0 || timeptr->tm_wday > 6)
        strcpy(tbuf, "?");
      else
        strcpy(tbuf, days_l[timeptr->tm_wday]);
      break;
    case 'h':
    case 'b':
      if (timeptr->tm_mon < 0 || timeptr->tm_mon > 11)
        strcpy(tbuf, "?");
      else
        strcpy(tbuf, months_a[timeptr->tm_mon]);
      break;
    case 'B':
      if (timeptr->tm_mon < 0 || timeptr->tm_mon > 11)
        strcpy(tbuf, "?");
      else
        strcpy(tbuf, months_l[timeptr->tm_mon]);
      break;
    case 'c':
      strftime(tbuf, sizeof tbuf, "%a %b %e %H:%M:%S %Y", timeptr);
      break;
    case 'd':
      i = max(1, min(timeptr->tm_mday, 31));
      sprintf(tbuf, "%02d", i);
      break;
    case 'H':
      i = max(0, min(timeptr->tm_hour, 23));
      sprintf(tbuf, "%02d", i);
      break;
    case 'I':
      i = max(0, min(timeptr->tm_hour, 23));
      if (i == 0)
        i = 12;
      else if (i > 12)
        i -= 12;
      sprintf(tbuf, "%02d", i);
      break;
    case 'j':
      sprintf(tbuf, "%03d", timeptr->tm_yday + 1);
      break;
    case 'm':
      i = max(0, min(timeptr->tm_mon, 11));
      sprintf(tbuf, "%02d", i + 1);
      break;
    case 'M':
      i = max(0, min(timeptr->tm_min, 59));
      sprintf(tbuf, "%02d", i);
      break;
    case 'p':
      i = max(0, min(timeptr->tm_hour, 23));
      if (i < 12)
        strcpy(tbuf, ampm[0]);
      else
        strcpy(tbuf, ampm[1]);
      break;
    case 'S':
      i = max(0, min(timeptr->tm_sec, 60));
      sprintf(tbuf, "%02d", i);
      break;
    case 'U':
      sprintf(tbuf, "%02d", weeknumber(timeptr, 0));
      break;
    case 'w':
      i = max(0, min(timeptr->tm_wday, 6));
      sprintf(tbuf, "%d", i);
      break;
    case 'W':
      sprintf(tbuf, "%02d", weeknumber(timeptr, 1));
      break;
    case 'x':
      strftime(tbuf, sizeof tbuf, "%m/%d/%y", timeptr);
      break;
    case 'X':
      strftime(tbuf, sizeof tbuf, "%H:%M:%S", timeptr);
      break;
    case 'y':
      i = timeptr->tm_year % 100;
      sprintf(tbuf, "%02d", i);
      break;
    case 'Y':
      sprintf(tbuf, "%ld", 1900L + timeptr->tm_year);
      break;
    case 'z':
      off = timeptr->tm_gmtoff / 60;
      if (off < 0) {
        tbuf[0] = '-';
        off = -off;
      } else {
        tbuf[0] = '+';
      }
      sprintf(tbuf + 1, "%02d%02d", off / 60, off % 60);
      break;
    case 'Z':
      strcpy(tbuf, timeptr->tm_zone);
      break;
    case 'n':
      tbuf[0] = '\n';
      tbuf[1] = '\0';
      break;
    case 't':
      tbuf[0] = '\t';
      tbuf[1] = '\0';
      break;
    case 'D':
      strftime(tbuf, sizeof tbuf, "%m/%d/%y", timeptr);
      break;
    case 'e':
      sprintf(tbuf, "%2d", max(1, min(timeptr->tm_mday, 31)));
      break;
    case 'r':
      strftime(tbuf, sizeof tbuf, "%I:%M:%S %p", timeptr);
      break;
    case 'R':
      strftime(tbuf, sizeof tbuf, "%H:%M", timeptr);
      break;
    case 'T':
      strftime(tbuf, sizeof tbuf, "%H:%M:%S", timeptr);
      break;
    case 'k':
      sprintf(tbuf, "%2d", max(0, min(timeptr->tm_hour, 23)));
      break;
    case 'l':
      i = max(0, min(timeptr->tm_hour, 23));
      if (i == 0)
        i = 12;
      else if (i > 12)
        i -= 12;
      sprintf(tbuf, "%2d", i);
      break;
    case 'v':
      sprintf(tbuf, "%2d-%3.3s-%4ld", max(1, min(timeptr->tm_mday, 31)),
              months_a[max(0, min(timeptr->tm_mon, 11))],
              timeptr->tm_year + 1900L);
      for (i = 3; i < 6; i++)
        if (islower(tbuf[i]))
          tbuf[i] = toupper(tbuf[i]);
      break;
    case 'C':
      sprintf(tbuf, "%02ld", (timeptr->tm_year + 1900L) / 100);
      break;
    case 'E':
    case 'O':
      goto again;
    case 'V':
      sprintf(tbuf, "%02d", iso8601wknum(timeptr));
      break;
    case 'u':
      sprintf(tbuf, "%d", timeptr->tm_wday == 0 ? 7 : timeptr->tm_wday);
      break;
    case 'G':
    case 'g':
      w = iso8601wknum(timeptr);
      if (timeptr->tm_mon == 11 && w == 1)
        y = 1900L + timeptr->tm_year + 1;
      else if (timeptr->tm_mon == 0 && w >= 52)
        y = 1900L + timeptr->tm_year - 1;
      else
        y = 1900L + timeptr->tm_year;
      if (*format == 'G')
        sprintf(tbuf, "%ld", y);
      else
        sprintf(tbuf, "%02ld", y % 100);
      break;
    default:
      tbuf[0] = '%';
      tbuf[1] = *format;
      tbuf[2] = '\0';
      break;
    }
    i = strlen(tbuf);
    if (i) {
      if (s + i < endp - 1) {
        strcpy(s, tbuf);
        s += i;
      } else
        return 0;
    }
  }
out:
  if (s < endp && *format == '\0') {
    *s = '\0';
    return (s - start);
  } else
    return 0;
}


x86 assembly (clang, -O0):
<strftime>:
push   %rbp
mov    %rsp,%rbp
sub    $0x120,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %rdx,-0x20(%rbp)
mov    %rcx,-0x28(%rbp)
mov    -0x10(%rbp),%rax
add    -0x18(%rbp),%rax
mov    %rax,-0x30(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x38(%rbp)
cmpq   $0x0,-0x10(%rbp)
je     125b <strftime+0x5b>
cmpq   $0x0,-0x20(%rbp)
je     125b <strftime+0x5b>
cmpq   $0x0,-0x28(%rbp)
je     125b <strftime+0x5b>
cmpq   $0x0,-0x18(%rbp)
jne    1268 <strftime+0x68>
movq   $0x0,-0x8(%rbp)
jmp    2043 <strftime+0xe43>
mov    -0x20(%rbp),%rdi
mov    $0x25,%esi
call   1080 <strchr@plt>
cmp    $0x0,%rax
jne    12a5 <strftime+0xa5>
mov    -0x20(%rbp),%rdi
call   1070 <strlen@plt>
add    $0x1,%eax
cltq
cmp    -0x18(%rbp),%rax
jb     12a5 <strftime+0xa5>
movq   $0x0,-0x8(%rbp)
jmp    2043 <strftime+0xe43>
lea    0x201d(%rip),%rdi
call   1030 <getenv@plt>
mov    %rax,-0xc0(%rbp)
cmpw   $0x0,0x3df0(%rip)
je     1340 <strftime+0x140>
cmpq   $0x0,-0xc0(%rbp)
je     1330 <strftime+0x130>
mov    -0xc0(%rbp),%rdi
call   1070 <strlen@plt>
mov    %eax,-0xc4(%rbp)
mov    -0xc4(%rbp),%edi
add    $0x1,%edi
call   10e0 <malloc@plt>
mov    %rax,0x3f1d(%rip)
cmpq   $0x0,0x3f15(%rip)
je     132b <strftime+0x12b>
mov    -0xc4(%rbp),%eax
add    $0x1,%eax
mov    %eax,0x3f08(%rip)
mov    0x3ef9(%rip),%rdi
mov    -0xc0(%rbp),%rsi
call   1040 <strcpy@plt>
jmp    1330 <strftime+0x130>
mov    $0x0,%al
call   10d0 <tzset@plt>
movw   $0x0,0x3d70(%rip)
cmpq   $0x0,-0xc0(%rbp)
je     1421 <strftime+0x221>
cmpq   $0x0,0x3ec2(%rip)
je     1421 <strftime+0x221>
mov    -0xc0(%rbp),%rax
movsbl (%rax),%eax
mov    0x3eab(%rip),%rcx
movsbl (%rcx),%ecx
cmp    %ecx,%eax
jne    1395 <strftime+0x195>
mov    -0xc0(%rbp),%rdi
mov    0x3e92(%rip),%rsi
call   10c0 <strcmp@plt>
cmp    $0x0,%rax
je     1421 <strftime+0x221>
mov    -0xc0(%rbp),%rdi
call   1070 <strlen@plt>
add    $0x1,%eax
mov    %eax,-0xac(%rbp)
mov    -0xac(%rbp),%eax
cmp    0x3e6a(%rip),%eax
jle    1407 <strftime+0x207>
mov    0x3e55(%rip),%rdi
mov    -0xac(%rbp),%esi
call   1100 <realloc@plt>
mov    %rax,0x3e43(%rip)
cmpq   $0x0,0x3e3b(%rip)
je     1402 <strftime+0x202>
mov    -0xac(%rbp),%eax
mov    %eax,0x3e31(%rip)
mov    0x3e22(%rip),%rdi
mov    -0xc0(%rbp),%rsi
call   1040 <strcpy@plt>
jmp    141a <strftime+0x21a>
mov    0x3e0a(%rip),%rdi
mov    -0xc0(%rbp),%rsi
call   1040 <strcpy@plt>
mov    $0x0,%al
call   10d0 <tzset@plt>
jmp    1426 <strftime+0x226>
mov    -0x20(%rbp),%rax
movsbl (%rax),%ecx
xor    %eax,%eax
cmp    $0x0,%ecx
mov    %al,-0xc5(%rbp)
je     1456 <strftime+0x256>
mov    -0x10(%rbp),%rax
mov    -0x30(%rbp),%rcx
add    $0xffffffffffffffff,%rcx
cmp    %rcx,%rax
setb   %al
mov    %al,-0xc5(%rbp)
mov    -0xc5(%rbp),%al
test   $0x1,%al
jne    1469 <strftime+0x269>
jmp    1ffd <strftime+0xdfd>
movb   $0x0,-0xa0(%rbp)
mov    -0x20(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x25,%eax
je     149c <strftime+0x29c>
mov    -0x20(%rbp),%rax
mov    (%rax),%cl
mov    -0x10(%rbp),%rax
mov    %rax,%rdx
add    $0x1,%rdx
mov    %rdx,-0x10(%rbp)
mov    %cl,(%rax)
jmp    1fec <strftime+0xdec>
jmp    14a1 <strftime+0x2a1>
mov    -0x20(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x20(%rbp)
movsbl 0x1(%rax),%eax
mov    %eax,%ecx
mov    %rcx,-0xd0(%rbp)
sub    $0x7a,%eax
ja     1f54 <strftime+0xd54>
mov    -0xd0(%rbp),%rax
lea    0x1b2c(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
mov    -0x10(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x10(%rbp)
movb   $0x25,(%rax)
jmp    2002 <strftime+0xe02>
mov    -0x10(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x10(%rbp)
movb   $0x25,(%rax)
jmp    1fec <strftime+0xdec>
mov    -0x28(%rbp),%rax
cmpl   $0x0,(%rax)
jl     1525 <strftime+0x325>
mov    -0x28(%rbp),%rax
cmpl   $0x6,(%rax)
jle    153d <strftime+0x33d>
lea    -0xa0(%rbp),%rdi
lea    0x1d99(%rip),%rsi
call   1040 <strcpy@plt>
jmp    155b <strftime+0x35b>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rax
movslq (%rax),%rcx
lea    0x3b6e(%rip),%rax
mov    (%rax,%rcx,8),%rsi
call   1040 <strcpy@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
cmpl   $0x0,(%rax)
jl     157a <strftime+0x37a>
mov    -0x28(%rbp),%rax
cmpl   $0x6,(%rax)
jle    1592 <strftime+0x392>
lea    -0xa0(%rbp),%rdi
lea    0x1d44(%rip),%rsi
call   1040 <strcpy@plt>
jmp    15b0 <strftime+0x3b0>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rax
movslq (%rax),%rcx
lea    0x3b59(%rip),%rax
mov    (%rax,%rcx,8),%rsi
call   1040 <strcpy@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
cmpl   $0x0,0x4(%rax)
jl     15d1 <strftime+0x3d1>
mov    -0x28(%rbp),%rax
cmpl   $0xb,0x4(%rax)
jle    15e9 <strftime+0x3e9>
lea    -0xa0(%rbp),%rdi
lea    0x1ced(%rip),%rsi
call   1040 <strcpy@plt>
jmp    1608 <strftime+0x408>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rax
movslq 0x4(%rax),%rcx
lea    0x3b41(%rip),%rax
mov    (%rax,%rcx,8),%rsi
call   1040 <strcpy@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
cmpl   $0x0,0x4(%rax)
jl     1629 <strftime+0x429>
mov    -0x28(%rbp),%rax
cmpl   $0xb,0x4(%rax)
jle    1641 <strftime+0x441>
lea    -0xa0(%rbp),%rdi
lea    0x1c95(%rip),%rsi
call   1040 <strcpy@plt>
jmp    1660 <strftime+0x460>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rax
movslq 0x4(%rax),%rcx
lea    0x3b49(%rip),%rax
mov    (%rax,%rcx,8),%rsi
call   1040 <strcpy@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rcx
mov    $0x64,%esi
lea    0x1c52(%rip),%rdx
call   10f0 <strftime@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
mov    0x8(%rax),%rdi
mov    $0x1f,%esi
call   10a0 <min@plt>
mov    %eax,%esi
mov    $0x1,%edi
call   10b0 <max@plt>
mov    %eax,-0xac(%rbp)
lea    -0xa0(%rbp),%rdi
movslq -0xac(%rbp),%rdx
lea    0x1c46(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
mov    0x10(%rax),%rdi
mov    $0x17,%esi
call   10a0 <min@plt>
mov    %eax,%esi
xor    %edi,%edi
call   10b0 <max@plt>
mov    %eax,-0xac(%rbp)
lea    -0xa0(%rbp),%rdi
movslq -0xac(%rbp),%rdx
lea    0x1c04(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
mov    0x10(%rax),%rdi
mov    $0x17,%esi
call   10a0 <min@plt>
mov    %eax,%esi
xor    %edi,%edi
call   10b0 <max@plt>
mov    %eax,-0xac(%rbp)
cmpl   $0x0,-0xac(%rbp)
jne    174a <strftime+0x54a>
movl   $0xc,-0xac(%rbp)
jmp    176b <strftime+0x56b>
cmpl   $0xc,-0xac(%rbp)
jle    1766 <strftime+0x566>
mov    -0xac(%rbp),%eax
sub    $0xc,%eax
mov    %eax,-0xac(%rbp)
jmp    176b <strftime+0x56b>
lea    -0xa0(%rbp),%rdi
movslq -0xac(%rbp),%rdx
lea    0x1b85(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rax
mov    0x38(%rax),%eax
add    $0x1,%eax
movslq %eax,%rdx
lea    0x1b3c(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
movslq 0x4(%rax),%rdi
mov    $0xb,%esi
call   10a0 <min@plt>
mov    %eax,%esi
xor    %edi,%edi
call   10b0 <max@plt>
mov    %eax,-0xac(%rbp)
lea    -0xa0(%rbp),%rdi
mov    -0xac(%rbp),%eax
add    $0x1,%eax
movslq %eax,%rdx
lea    0x1b17(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
mov    0x18(%rax),%rdi
mov    $0x3b,%esi
call   10a0 <min@plt>
mov    %eax,%esi
xor    %edi,%edi
call   10b0 <max@plt>
mov    %eax,-0xac(%rbp)
lea    -0xa0(%rbp),%rdi
movslq -0xac(%rbp),%rdx
lea    0x1ad5(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
mov    0x10(%rax),%rdi
mov    $0x17,%esi
call   10a0 <min@plt>
mov    %eax,%esi
xor    %edi,%edi
call   10b0 <max@plt>
mov    %eax,-0xac(%rbp)
cmpl   $0xc,-0xac(%rbp)
jge    1882 <strftime+0x682>
lea    -0xa0(%rbp),%rdi
mov    0x3988(%rip),%rsi
call   1040 <strcpy@plt>
jmp    1895 <strftime+0x695>
lea    -0xa0(%rbp),%rdi
mov    0x3978(%rip),%rsi
call   1040 <strcpy@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
mov    0x20(%rax),%rdi
mov    $0x3c,%esi
call   10a0 <min@plt>
mov    %eax,%esi
xor    %edi,%edi
call   10b0 <max@plt>
mov    %eax,-0xac(%rbp)
lea    -0xa0(%rbp),%rdi
movslq -0xac(%rbp),%rdx
lea    0x1a35(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rax
mov    %rax,-0xd8(%rbp)
mov    -0x28(%rbp),%rdi
xor    %esi,%esi
call   1090 <weeknumber@plt>
mov    -0xd8(%rbp),%rdi
movslq %eax,%rdx
lea    0x19ff(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
movslq (%rax),%rdi
mov    $0x6,%esi
call   10a0 <min@plt>
mov    %eax,%esi
xor    %edi,%edi
call   10b0 <max@plt>
mov    %eax,-0xac(%rbp)
lea    -0xa0(%rbp),%rdi
movslq -0xac(%rbp),%rdx
lea    0x19a1(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rax
mov    %rax,-0xe0(%rbp)
mov    -0x28(%rbp),%rdi
mov    $0x1,%esi
call   1090 <weeknumber@plt>
mov    -0xe0(%rbp),%rdi
movslq %eax,%rdx
lea    0x1985(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rcx
mov    $0x64,%esi
lea    0x1948(%rip),%rdx
call   10f0 <strftime@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rcx
mov    $0x64,%esi
lea    0x1930(%rip),%rdx
call   10f0 <strftime@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
mov    0x28(%rax),%eax
mov    $0x64,%ecx
cltd
idiv   %ecx
mov    %edx,-0xac(%rbp)
lea    -0xa0(%rbp),%rdi
movslq -0xac(%rbp),%rdx
lea    0x190d(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rax
movslq 0x28(%rax),%rdx
add    $0x76c,%rdx
lea    0x18dc(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
mov    0x2c(%rax),%eax
mov    $0x3c,%ecx
cltd
idiv   %ecx
cltq
mov    %rax,-0xa8(%rbp)
cmpq   $0x0,-0xa8(%rbp)
jge    1a6f <strftime+0x86f>
movb   $0x2d,-0xa0(%rbp)
xor    %eax,%eax
sub    -0xa8(%rbp),%rax
mov    %rax,-0xa8(%rbp)
jmp    1a76 <strftime+0x876>
movb   $0x2b,-0xa0(%rbp)
lea    -0xa0(%rbp),%rdi
add    $0x1,%rdi
mov    -0xa8(%rbp),%rax
mov    $0x3c,%ecx
cqto
idiv   %rcx
mov    %rax,-0xe8(%rbp)
mov    -0xa8(%rbp),%rax
mov    $0x3c,%ecx
cqto
idiv   %rcx
mov    %rdx,%rcx
mov    -0xe8(%rbp),%rdx
lea    0x1846(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rax
mov    0x30(%rax),%rsi
call   1040 <strcpy@plt>
jmp    1f6e <strftime+0xd6e>
movb   $0xa,-0xa0(%rbp)
movb   $0x0,-0x9f(%rbp)
jmp    1f6e <strftime+0xd6e>
movb   $0x9,-0xa0(%rbp)
movb   $0x0,-0x9f(%rbp)
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rcx
mov    $0x64,%esi
lea    0x17ce(%rip),%rdx
call   10f0 <strftime@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rax
mov    %rax,-0xf0(%rbp)
mov    -0x28(%rbp),%rax
mov    0x8(%rax),%rdi
mov    $0x1f,%esi
call   10a0 <min@plt>
mov    %eax,%esi
mov    $0x1,%edi
call   10b0 <max@plt>
mov    -0xf0(%rbp),%rdi
mov    %rax,%rdx
lea    0x17a6(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rcx
mov    $0x64,%esi
lea    0x1787(%rip),%rdx
call   10f0 <strftime@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rcx
mov    $0x64,%esi
lea    0x1772(%rip),%rdx
call   10f0 <strftime@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rcx
mov    $0x64,%esi
lea    0x172b(%rip),%rdx
call   10f0 <strftime@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rax
mov    %rax,-0xf8(%rbp)
mov    -0x28(%rbp),%rax
mov    0x10(%rax),%rdi
mov    $0x17,%esi
call   10a0 <min@plt>
mov    %eax,%esi
xor    %edi,%edi
call   10b0 <max@plt>
mov    -0xf8(%rbp),%rdi
mov    %rax,%rdx
lea    0x16fd(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rax
mov    0x10(%rax),%rdi
mov    $0x17,%esi
call   10a0 <min@plt>
mov    %eax,%esi
xor    %edi,%edi
call   10b0 <max@plt>
mov    %eax,-0xac(%rbp)
cmpl   $0x0,-0xac(%rbp)
jne    1c56 <strftime+0xa56>
movl   $0xc,-0xac(%rbp)
jmp    1c77 <strftime+0xa77>
cmpl   $0xc,-0xac(%rbp)
jle    1c72 <strftime+0xa72>
mov    -0xac(%rbp),%eax
sub    $0xc,%eax
mov    %eax,-0xac(%rbp)
jmp    1c77 <strftime+0xa77>
lea    -0xa0(%rbp),%rdi
movslq -0xac(%rbp),%rdx
lea    0x167e(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rax
mov    %rax,-0x108(%rbp)
mov    -0x28(%rbp),%rax
mov    0x8(%rax),%rdi
mov    $0x1f,%esi
call   10a0 <min@plt>
mov    %eax,%esi
mov    $0x1,%edi
call   10b0 <max@plt>
mov    %rax,-0x100(%rbp)
mov    -0x28(%rbp),%rax
movslq 0x4(%rax),%rdi
mov    $0xb,%esi
call   10a0 <min@plt>
mov    %eax,%esi
xor    %edi,%edi
call   10b0 <max@plt>
mov    -0x108(%rbp),%rdi
mov    -0x100(%rbp),%rdx
mov    %rax,%rcx
lea    0x3442(%rip),%rax
mov    (%rax,%rcx,8),%rcx
mov    -0x28(%rbp),%rax
movslq 0x28(%rax),%r8
add    $0x76c,%r8
lea    0x1608(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
movl   $0x3,-0xac(%rbp)
cmpl   $0x6,-0xac(%rbp)
jge    1d90 <strftime+0xb90>
movslq -0xac(%rbp),%rax
movsbl -0xa0(%rbp,%rax,1),%edi
ff
call   1050 <islower@plt>
cmp    $0x0,%eax
je     1d77 <strftime+0xb77>
movslq -0xac(%rbp),%rax
movsbl -0xa0(%rbp,%rax,1),%edi
ff
call   1060 <toupper@plt>
mov    %al,%cl
movslq -0xac(%rbp),%rax
mov    %cl,-0xa0(%rbp,%rax,1)
jmp    1d7c <strftime+0xb7c>
mov    -0xac(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xac(%rbp)
jmp    1d29 <strftime+0xb29>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rdi
mov    -0x28(%rbp),%rax
movslq 0x28(%rax),%rax
add    $0x76c,%rax
mov    $0x64,%ecx
cqto
idiv   %rcx
mov    %rax,%rdx
lea    0x1571(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
jmp    14a1 <strftime+0x2a1>
lea    -0xa0(%rbp),%rax
mov    %rax,-0x110(%rbp)
mov    -0x28(%rbp),%rdi
call   1110 <iso8601wknum@plt>
mov    -0x110(%rbp),%rdi
movslq %eax,%rdx
lea    0x150e(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
lea    -0xa0(%rbp),%rax
mov    %rax,-0x118(%rbp)
mov    -0x28(%rbp),%rax
cmpl   $0x0,(%rax)
jne    1e2e <strftime+0xc2e>
mov    $0x7,%eax
mov    %eax,-0x11c(%rbp)
jmp    1e3a <strftime+0xc3a>
mov    -0x28(%rbp),%rax
mov    (%rax),%eax
mov    %eax,-0x11c(%rbp)
mov    -0x118(%rbp),%rdi
mov    -0x11c(%rbp),%eax
movslq %eax,%rdx
lea    0x1497(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
mov    -0x28(%rbp),%rdi
call   1110 <iso8601wknum@plt>
mov    %eax,-0xb0(%rbp)
mov    -0x28(%rbp),%rax
cmpl   $0xb,0x4(%rax)
jne    1ea5 <strftime+0xca5>
cmpl   $0x1,-0xb0(%rbp)
jne    1ea5 <strftime+0xca5>
mov    -0x28(%rbp),%rax
movslq 0x28(%rax),%rax
add    $0x76c,%rax
add    $0x1,%rax
mov    %rax,-0xb8(%rbp)
jmp    1ef8 <strftime+0xcf8>
mov    -0x28(%rbp),%rax
cmpl   $0x0,0x4(%rax)
jne    1ede <strftime+0xcde>
cmpl   $0x34,-0xb0(%rbp)
jl     1ede <strftime+0xcde>
mov    -0x28(%rbp),%rax
movslq 0x28(%rax),%rax
add    $0x76c,%rax
sub    $0x1,%rax
mov    %rax,-0xb8(%rbp)
jmp    1ef3 <strftime+0xcf3>
mov    -0x28(%rbp),%rax
movslq 0x28(%rax),%rax
add    $0x76c,%rax
mov    %rax,-0xb8(%rbp)
jmp    1ef8 <strftime+0xcf8>
mov    -0x20(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x47,%eax
jne    1f29 <strftime+0xd29>
lea    -0xa0(%rbp),%rdi
mov    -0xb8(%rbp),%rdx
lea    0x13e0(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f4f <strftime+0xd4f>
lea    -0xa0(%rbp),%rdi
mov    -0xb8(%rbp),%rax
mov    $0x64,%ecx
cqto
idiv   %rcx
lea    0x13e7(%rip),%rsi
mov    $0x0,%al
call   1120 <sprintf@plt>
jmp    1f6e <strftime+0xd6e>
movb   $0x25,-0xa0(%rbp)
mov    -0x20(%rbp),%rax
mov    (%rax),%al
mov    %al,-0x9f(%rbp)
movb   $0x0,-0x9e(%rbp)
lea    -0xa0(%rbp),%rdi
call   1070 <strlen@plt>
mov    %eax,-0xac(%rbp)
cmpl   $0x0,-0xac(%rbp)
je     1fe7 <strftime+0xde7>
mov    -0x10(%rbp),%rax
movslq -0xac(%rbp),%rcx
add    %rcx,%rax
mov    -0x30(%rbp),%rcx
add    $0xffffffffffffffff,%rcx
cmp    %rcx,%rax
jae    1fd5 <strftime+0xdd5>
mov    -0x10(%rbp),%rdi
lea    -0xa0(%rbp),%rsi
call   1040 <strcpy@plt>
mov    -0xac(%rbp),%ecx
mov    -0x10(%rbp),%rax
movslq %ecx,%rcx
add    %rcx,%rax
mov    %rax,-0x10(%rbp)
jmp    1fe2 <strftime+0xde2>
movq   $0x0,-0x8(%rbp)
jmp    2043 <strftime+0xe43>
jmp    1fe7 <strftime+0xde7>
jmp    1fec <strftime+0xdec>
mov    -0x20(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x20(%rbp)
jmp    1426 <strftime+0x226>
jmp    2002 <strftime+0xe02>
mov    -0x10(%rbp),%rax
cmp    -0x30(%rbp),%rax
jae    203b <strftime+0xe3b>
mov    -0x20(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x0,%eax
jne    203b <strftime+0xe3b>
mov    -0x10(%rbp),%rax
movb   $0x0,(%rax)
mov    -0x10(%rbp),%rax
mov    -0x38(%rbp),%rcx
sub    %rcx,%rax
mov    %rax,-0x8(%rbp)
jmp    2043 <strftime+0xe43>
movq   $0x0,-0x8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x120,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<strftime>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x88,%rsp
mov    %rcx,0x8(%rsp)
xor    %eax,%eax
test   %rsi,%rsi
je     19fc <strftime+0x7fc>
mov    %rdi,%r12
test   %rdi,%rdi
je     19fc <strftime+0x7fc>
mov    %rdx,%rbx
test   %rdx,%rdx
je     19fc <strftime+0x7fc>
cmpq   $0x0,0x8(%rsp)
je     19fc <strftime+0x7fc>
mov    %rsi,%r15
mov    %rbx,%rdi
mov    $0x25,%esi
call   1080 <strchr@plt>
test   %rax,%rax
jne    1270 <strftime+0x70>
mov    %rbx,%rdi
call   1070 <strlen@plt>
add    $0x1,%eax
cltq
cmp    %r15,%rax
jae    19fa <strftime+0x7fa>
lea    0x10ba(%rip),%rdi
call   1030 <getenv@plt>
mov    %rax,%r14
cmpb   $0x0,0x2e22(%rip)
jne    12d0 <strftime+0xd0>
test   %r14,%r14
je     12c2 <strftime+0xc2>
mov    %r14,%rdi
call   1070 <strlen@plt>
mov    %eax,%r13d
add    $0x1,%r13d
mov    %r13d,%edi
call   10e0 <malloc@plt>
mov    %rax,0x2e05(%rip)
test   %rax,%rax
je     12c2 <strftime+0xc2>
mov    %r13d,0x2e01(%rip)
mov    %rax,%rdi
mov    %r14,%rsi
call   1040 <strcpy@plt>
xor    %eax,%eax
call   10d0 <tzset@plt>
movb   $0x1,0x2dd8(%rip)
test   %r14,%r14
je     1340 <strftime+0x140>
mov    0x2dd4(%rip),%rsi
test   %rsi,%rsi
je     1340 <strftime+0x140>
mov    (%r14),%al
cmp    (%rsi),%al
jne    12f5 <strftime+0xf5>
mov    %r14,%rdi
call   10c0 <strcmp@plt>
test   %rax,%rax
je     1340 <strftime+0x140>
mov    %r14,%rdi
call   1070 <strlen@plt>
mov    0x2dac(%rip),%rdi
cmp    0x2dae(%rip),%eax
jl     1331 <strftime+0x131>
mov    %eax,%r13d
add    $0x1,%r13d
mov    %r13d,%esi
call   1100 <realloc@plt>
mov    %rax,0x2d8e(%rip)
test   %rax,%rax
je     1339 <strftime+0x139>
mov    %r13d,0x2d8a(%rip)
mov    %rax,%rdi
mov    %r14,%rsi
call   1040 <strcpy@plt>
xor    %eax,%eax
call   10d0 <tzset@plt>
add    %r12,%r15
mov    (%rbx),%al
test   %al,%al
mov    %r12,0x80(%rsp)
je     19f0 <strftime+0x7f0>
lea    -0x1(%r15),%r14
cmp    %r12,%r14
jbe    19f0 <strftime+0x7f0>
lea    0xc97(%rip),%r13
nopl   0x0(%rax)
movb   $0x0,0x10(%rsp)
cmp    $0x25,%al
jne    13e0 <strftime+0x1e0>
add    $0x1,%rbx
movsbl (%rbx),%eax
cmp    $0x7a,%eax
ja     18a6 <strftime+0x6a6>
movslq 0x0(%r13,%rax,4),%rcx
add    %r13,%rcx
jmp    *%rcx
mov    0x8(%rsp),%rbp
mov    %rbp,%rdi
call   1110 <iso8601wknum@plt>
mov    0x4(%rbp),%edx
cmp    $0xb,%edx
jne    1877 <strftime+0x677>
cmp    $0x1,%eax
jne    1877 <strftime+0x677>
mov    0x8(%rsp),%rax
movslq 0x28(%rax),%rcx
add    $0x76d,%rcx
cmpb   $0x47,(%rbx)
jne    196a <strftime+0x76a>
lea    0xf90(%rip),%rsi
jmp    1999 <strftime+0x799>
nopw   0x0(%rax,%rax,1)
mov    %al,(%r12)
add    $0x1,%r12
jmp    193d <strftime+0x73d>
lea    0xf68(%rip),%rdx
jmp    1708 <strftime+0x508>
mov    0x8(%rsp),%rax
mov    0x4(%rax),%eax
cmp    $0xc,%rax
jae    15af <strftime+0x3af>
lea    0x29ae(%rip),%rcx
mov    (%rcx,%rax,8),%rsi
jmp    1903 <strftime+0x703>
lea    0xf31(%rip),%rdx
jmp    1708 <strftime+0x508>
movb   $0x25,(%r12)
add    $0x1,%r12
jmp    193d <strftime+0x73d>
mov    0x8(%rsp),%rax
mov    (%rax),%eax
cmp    $0x7,%rax
jae    15af <strftime+0x3af>
lea    0xdbb(%rip),%rcx
jmp    18f3 <strftime+0x6f3>
mov    0x8(%rsp),%rax
mov    0x4(%rax),%eax
cmp    $0xc,%rax
jae    15af <strftime+0x3af>
lea    0xdb9(%rip),%rcx
jmp    18f3 <strftime+0x6f3>
mov    0x8(%rsp),%rax
movslq 0x28(%rax),%rcx
lea    0x76c(%rcx),%rax
movabs $0xa3d70a3d70a3d70b,%rdx
0a d7 a3
imul   %rdx
add    %rcx,%rdx
add    $0x76c,%rdx
mov    %rdx,%rax
shr    $0x3f,%rax
sar    $0x6,%rdx
add    %rax,%rdx
lea    0xeeb(%rip),%rsi
jmp    1866 <strftime+0x666>
mov    0x8(%rsp),%rax
mov    0x10(%rax),%rdi
mov    $0x17,%esi
jmp    1536 <strftime+0x336>
mov    0x8(%rsp),%rax
mov    0x10(%rax),%rdi
mov    $0x17,%esi
call   10a0 <min@plt>
xor    %edi,%edi
mov    %eax,%esi
call   10b0 <max@plt>
mov    %rax,%rcx
shl    $0x20,%rcx
movabs $0xfffffff400000000,%rsi
ff ff ff
add    %rcx,%rsi
cmp    $0xd,%eax
cmovl  %rcx,%rsi
sar    $0x20,%rsi
test   %eax,%eax
mov    $0xc,%edx
cmovne %rsi,%rdx
jmp    185f <strftime+0x65f>
mov    0x8(%rsp),%rax
mov    0x18(%rax),%rdi
mov    $0x3b,%esi
jmp    1536 <strftime+0x336>
lea    0xe5f(%rip),%rdx
jmp    1708 <strftime+0x508>
mov    0x8(%rsp),%rax
mov    0x20(%rax),%rdi
mov    $0x3c,%esi
call   10a0 <min@plt>
xor    %edi,%edi
jmp    15df <strftime+0x3df>
mov    0x8(%rsp),%rdi
xor    %esi,%esi
jmp    1567 <strftime+0x367>
mov    0x8(%rsp),%rdi
call   1110 <iso8601wknum@plt>
movslq %eax,%rdx
jmp    185f <strftime+0x65f>
mov    0x8(%rsp),%rdi
mov    $0x1,%esi
call   1090 <weeknumber@plt>
movslq %eax,%rdx
jmp    185f <strftime+0x65f>
mov    0x8(%rsp),%rax
movslq 0x28(%rax),%rdx
add    $0x76c,%rdx
lea    0xdda(%rip),%rsi
jmp    1866 <strftime+0x666>
mov    0x8(%rsp),%rax
mov    0x30(%rax),%rsi
jmp    1903 <strftime+0x703>
mov    0x8(%rsp),%rax
mov    (%rax),%eax
cmp    $0x7,%rax
jb     18ec <strftime+0x6ec>
lea    0xd7e(%rip),%rsi
jmp    1903 <strftime+0x703>
lea    0xd74(%rip),%rdx
jmp    1708 <strftime+0x508>
mov    0x8(%rsp),%rax
mov    0x8(%rax),%rdi
mov    $0x1f,%esi
call   10a0 <min@plt>
mov    $0x1,%edi
mov    %eax,%esi
call   10b0 <max@plt>
jmp    185c <strftime+0x65c>
mov    0x8(%rsp),%rax
mov    0x8(%rax),%rdi
mov    $0x1f,%esi
call   10a0 <min@plt>
mov    $0x1,%edi
jmp    1633 <strftime+0x433>
mov    0x8(%rsp),%rax
movslq 0x38(%rax),%rdx
add    $0x1,%rdx
lea    0xd32(%rip),%rsi
jmp    1866 <strftime+0x666>
mov    0x8(%rsp),%rax
mov    0x10(%rax),%rdi
mov    $0x17,%esi
call   10a0 <min@plt>
xor    %edi,%edi
mov    %eax,%esi
call   10b0 <max@plt>
lea    0xd31(%rip),%rsi
lea    0x10(%rsp),%rdi
mov    %rax,%rdx
jmp    186b <strftime+0x66b>
mov    0x8(%rsp),%rax
mov    0x10(%rax),%rdi
mov    $0x17,%esi
call   10a0 <min@plt>
xor    %edi,%edi
mov    %eax,%esi
call   10b0 <max@plt>
mov    %rax,%rcx
shl    $0x20,%rcx
movabs $0xfffffff400000000,%rsi
ff ff ff
add    %rcx,%rsi
cmp    $0xd,%eax
cmovl  %rcx,%rsi
sar    $0x20,%rsi
test   %eax,%eax
mov    $0xc,%edx
cmovne %rsi,%rdx
lea    0xcd7(%rip),%rsi
jmp    1866 <strftime+0x666>
mov    0x8(%rsp),%rax
movslq 0x4(%rax),%rdi
mov    $0xb,%esi
call   10a0 <min@plt>
xor    %edi,%edi
mov    %eax,%esi
call   10b0 <max@plt>
add    $0x1,%eax
jmp    185c <strftime+0x65c>
movw   $0xa,0x10(%rsp)
jmp    1910 <strftime+0x710>
mov    0x8(%rsp),%rax
mov    0x10(%rax),%rdi
mov    $0x17,%esi
call   10a0 <min@plt>
xor    %edi,%edi
mov    %eax,%esi
call   10b0 <max@plt>
cmp    $0xb,%eax
jg     18fc <strftime+0x6fc>
lea    0xc2f(%rip),%rsi
jmp    1903 <strftime+0x703>
lea    0xc6e(%rip),%rdx
lea    0x10(%rsp),%rdi
mov    $0x64,%esi
mov    0x8(%rsp),%rcx
call   10f0 <strftime@plt>
jmp    1910 <strftime+0x710>
movw   $0x9,0x10(%rsp)
jmp    1910 <strftime+0x710>
mov    0x8(%rsp),%rax
mov    (%rax),%eax
test   %eax,%eax
mov    $0x7,%ecx
cmovne %eax,%ecx
movslq %ecx,%rdx
lea    0xc08(%rip),%rsi
jmp    1866 <strftime+0x666>
mov    0x8(%rsp),%rbp
mov    0x8(%rbp),%rdi
mov    $0x1f,%esi
call   10a0 <min@plt>
mov    $0x1,%edi
mov    %eax,%esi
call   10b0 <max@plt>
mov    %rax,0x78(%rsp)
movslq 0x4(%rbp),%rdi
mov    $0xb,%esi
call   10a0 <min@plt>
xor    %edi,%edi
mov    %eax,%esi
call   10b0 <max@plt>
lea    0x2631(%rip),%rcx
mov    (%rcx,%rax,8),%rcx
movslq 0x28(%rbp),%r8
add    $0x76c,%r8
lea    0xbe3(%rip),%rsi
lea    0x10(%rsp),%rdi
mov    0x78(%rsp),%rdx
xor    %eax,%eax
call   1120 <sprintf@plt>
movsbl 0x13(%rsp),%edi
call   1050 <islower@plt>
test   %eax,%eax
je     17d2 <strftime+0x5d2>
movsbl 0x13(%rsp),%edi
call   1060 <toupper@plt>
mov    %al,0x13(%rsp)
movsbl 0x14(%rsp),%edi
call   1050 <islower@plt>
test   %eax,%eax
je     17ee <strftime+0x5ee>
movsbl 0x14(%rsp),%edi
call   1060 <toupper@plt>
mov    %al,0x14(%rsp)
movsbl 0x15(%rsp),%edi
call   1050 <islower@plt>
test   %eax,%eax
je     1910 <strftime+0x710>
movsbl 0x15(%rsp),%edi
call   1060 <toupper@plt>
mov    %al,0x15(%rsp)
jmp    1910 <strftime+0x710>
mov    0x8(%rsp),%rax
movslq (%rax),%rdi
mov    $0x6,%esi
call   10a0 <min@plt>
xor    %edi,%edi
mov    %eax,%esi
call   10b0 <max@plt>
movslq %eax,%rdx
lea    0xb18(%rip),%rsi
jmp    1866 <strftime+0x666>
mov    0x8(%rsp),%rax
movslq 0x28(%rax),%rax
imul   $0x51eb851f,%rax,%rcx
mov    %rcx,%rdx
shr    $0x3f,%rdx
sar    $0x25,%rcx
add    %edx,%ecx
imul   $0x64,%ecx,%ecx
sub    %ecx,%eax
movslq %eax,%rdx
lea    0xb07(%rip),%rsi
lea    0x10(%rsp),%rdi
xor    %eax,%eax
call   1120 <sprintf@plt>
jmp    1910 <strftime+0x710>
mov    0x8(%rsp),%rcx
movslq 0x28(%rcx),%rcx
test   %edx,%edx
jne    195a <strftime+0x75a>
cmp    $0x34,%eax
jl     195a <strftime+0x75a>
add    $0x76b,%rcx
cmpb   $0x47,(%rbx)
je     13ce <strftime+0x1ce>
jmp    196a <strftime+0x76a>
movb   $0x25,0x10(%rsp)
mov    %al,0x11(%rsp)
movb   $0x0,0x12(%rsp)
jmp    1910 <strftime+0x710>
mov    0x8(%rsp),%rax
movslq 0x2c(%rax),%rcx
imul   $0xffffffff88888889,%rcx,%rax
shr    $0x20,%rax
add    %ecx,%eax
mov    %eax,%edx
shr    $0x1f,%edx
sar    $0x5,%eax
add    %edx,%eax
cmp    $0xffffffffffffffc4,%rcx
jg     19a6 <strftime+0x7a6>
movb   $0x2d,0x10(%rsp)
neg    %eax
jmp    19ab <strftime+0x7ab>
lea    0x8f9(%rip),%rcx
movslq (%rcx,%rax,4),%rsi
add    %rcx,%rsi
jmp    1903 <strftime+0x703>
lea    0xa2b(%rip),%rsi
lea    0x10(%rsp),%rdi
call   1040 <strcpy@plt>
nopl   (%rax)
lea    0x10(%rsp),%rdi
call   1070 <strlen@plt>
test   %eax,%eax
je     193d <strftime+0x73d>
movslq %eax,%rbp
add    %r12,%rbp
cmp    %r14,%rbp
jae    19fa <strftime+0x7fa>
mov    %r12,%rdi
lea    0x10(%rsp),%rsi
call   1040 <strcpy@plt>
mov    %rbp,%r12
mov    0x1(%rbx),%al
add    $0x1,%rbx
test   %al,%al
je     19f0 <strftime+0x7f0>
cmp    %r14,%r12
jb     1370 <strftime+0x170>
jmp    19f0 <strftime+0x7f0>
add    $0x76c,%rcx
cmpb   $0x47,(%rbx)
je     13ce <strftime+0x1ce>
movabs $0xa3d70a3d70a3d70b,%rdx
0a d7 a3
mov    %rcx,%rax
imul   %rdx
add    %rcx,%rdx
mov    %rdx,%rax
shr    $0x3f,%rax
sar    $0x6,%rdx
add    %rax,%rdx
imul   $0x64,%rdx,%rax
sub    %rax,%rcx
lea    0x9fe(%rip),%rsi
lea    0x10(%rsp),%rdi
mov    %rcx,%rdx
jmp    186b <strftime+0x66b>
movb   $0x2b,0x10(%rsp)
cltq
imul   $0xffffffff88888889,%rax,%rcx
shr    $0x20,%rcx
add    %eax,%ecx
mov    %ecx,%edx
shr    $0x1f,%edx
sar    $0x5,%ecx
add    %edx,%ecx
movslq %ecx,%rdx
imul   $0x3c,%edx,%ecx
sub    %ecx,%eax
movslq %eax,%rcx
lea    0x993(%rip),%rsi
lea    0x11(%rsp),%rdi
xor    %eax,%eax
call   1120 <sprintf@plt>
jmp    1910 <strftime+0x710>
movb   $0x25,(%r12)
add    $0x1,%r12
cmp    %r15,%r12
jae    19fa <strftime+0x7fa>
cmpb   $0x0,(%rbx)
je     1a0e <strftime+0x80e>
xor    %eax,%eax
add    $0x88,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
movb   $0x0,(%r12)
sub    0x80(%rsp),%r12
mov    %r12,%rax
jmp    19fc <strftime+0x7fc>

LLVM IR (-O0):
%struct.tm = type { i32, i32, i64, i64, i64, i64, i32, i32, i8*, i32 }
@strftime.first = internal global i16 1
@strftime.savetz = internal global i8* null
@strftime.savetzlen = internal global i32 0
@strftime.days_a = internal global [7 x i8*] [i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i32 0, i32 0)]
@.str = [4 x i8] c"Sun\00"
@.str.1 = [4 x i8] c"Mon\00"
@.str.2 = [4 x i8] c"Tue\00"
@.str.3 = [4 x i8] c"Wed\00"
@.str.4 = [4 x i8] c"Thu\00"
@.str.5 = [4 x i8] c"Fri\00"
@.str.6 = [4 x i8] c"Sat\00"
@strftime.days_l = internal global [7 x i8*] [i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.7, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.8, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.9, i32 0, i32 0), i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.10, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.11, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.12, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.13, i32 0, i32 0)]
@.str.7 = [7 x i8] c"Sunday\00"
@.str.8 = [7 x i8] c"Monday\00"
@.str.9 = [8 x i8] c"Tuesday\00"
@.str.10 = [10 x i8] c"Wednesday\00"
@.str.11 = [9 x i8] c"Thursday\00"
@.str.12 = [7 x i8] c"Friday\00"
@.str.13 = [9 x i8] c"Saturday\00"
@strftime.months_a = internal global [12 x i8*] [i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.14, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.15, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.16, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.17, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.18, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.19, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.20, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.21, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.22, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.23, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.24, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.25, i32 0, i32 0)]
@.str.14 = [4 x i8] c"Jan\00"
@.str.15 = [4 x i8] c"Feb\00"
@.str.16 = [4 x i8] c"Mar\00"
@.str.17 = [4 x i8] c"Apr\00"
@.str.18 = [4 x i8] c"May\00"
@.str.19 = [4 x i8] c"Jun\00"
@.str.20 = [4 x i8] c"Jul\00"
@.str.21 = [4 x i8] c"Aug\00"
@.str.22 = [4 x i8] c"Sep\00"
@.str.23 = [4 x i8] c"Oct\00"
@.str.24 = [4 x i8] c"Nov\00"
@.str.25 = [4 x i8] c"Dec\00"
@strftime.months_l = internal global [12 x i8*] [i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.26, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.27, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.28, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.29, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.18, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.30, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.31, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.32, i32 0, i32 0), i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.33, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.34, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.35, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.36, i32 0, i32 0)]
@.str.26 = [8 x i8] c"January\00"
@.str.27 = [9 x i8] c"February\00"
@.str.28 = [6 x i8] c"March\00"
@.str.29 = [6 x i8] c"April\00"
@.str.30 = [5 x i8] c"June\00"
@.str.31 = [5 x i8] c"July\00"
@.str.32 = [7 x i8] c"August\00"
@.str.33 = [10 x i8] c"September\00"
@.str.34 = [8 x i8] c"October\00"
@.str.35 = [9 x i8] c"November\00"
@.str.36 = [9 x i8] c"December\00"
@strftime.ampm = internal global [2 x i8*] [i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.37, i32 0, i32 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.38, i32 0, i32 0)]
@.str.37 = [3 x i8] c"AM\00"
@.str.38 = [3 x i8] c"PM\00"
@.str.39 = [3 x i8] c"TZ\00"
@.str.40 = [2 x i8] c"?\00"
@.str.41 = [21 x i8] c"%a %b %e %H:%M:%S %Y\00"
@.str.42 = [5 x i8] c"%02d\00"
@.str.43 = [5 x i8] c"%03d\00"
@.str.44 = [3 x i8] c"%d\00"
@.str.45 = [9 x i8] c"%m/%d/%y\00"
@.str.46 = [9 x i8] c"%H:%M:%S\00"
@.str.47 = [4 x i8] c"%ld\00"
@.str.48 = [9 x i8] c"%02d%02d\00"
@.str.49 = [4 x i8] c"%2d\00"
@.str.50 = [12 x i8] c"%I:%M:%S %p\00"
@.str.51 = [6 x i8] c"%H:%M\00"
@.str.52 = [15 x i8] c"%2d-%3.3s-%4ld\00"
@.str.53 = [6 x i8] c"%02ld\00"
define i64 @strftime(i8* %0, i64 %1, i8* %2, %struct.tm* %3) {
%5 = alloca i64
%6 = alloca i8*
%7 = alloca i64
%8 = alloca i8*
%9 = alloca %struct.tm*
%10 = alloca i8*
%11 = alloca i8*
%12 = alloca [100 x i8]
%13 = alloca i64
%14 = alloca i32
%15 = alloca i32
%16 = alloca i64
%17 = alloca i8*
%18 = alloca i32
store i8* %0, i8** %6
store i64 %1, i64* %7
store i8* %2, i8** %8
store %struct.tm* %3, %struct.tm** %9
%19 = load i8*, i8** %6
%20 = load i64, i64* %7
%21 = getelementptr inbounds i8, i8* %19, i64 %20
store i8* %21, i8** %10
%22 = load i8*, i8** %6
store i8* %22, i8** %11
%23 = load i8*, i8** %6
%24 = icmp eq i8* %23, null
br i1 %24, label %34, label %25
25: ; preds = %4
%26 = load i8*, i8** %8
%27 = icmp eq i8* %26, null
br i1 %27, label %34, label %28
28: ; preds = %25
%29 = load %struct.tm*, %struct.tm** %9
%30 = icmp eq %struct.tm* %29, null
br i1 %30, label %34, label %31
31: ; preds = %28
%32 = load i64, i64* %7
%33 = icmp eq i64 %32, 0
br i1 %33, label %34, label %35
34: ; preds = %31, %28, %25, %4
store i64 0, i64* %5
br label %674
35: ; preds = %31
%36 = load i8*, i8** %8
%37 = call i32* @strchr(i8* %36, i8 signext 37)
%38 = icmp eq i32* %37, null
br i1 %38, label %39, label %47
39: ; preds = %35
%40 = load i8*, i8** %8
%41 = call i32 @strlen(i8* %40)
%42 = add nsw i32 %41, 1
%43 = sext i32 %42 to i64
%44 = load i64, i64* %7
%45 = icmp uge i64 %43, %44
br i1 %45, label %46, label %47
46: ; preds = %39
store i64 0, i64* %5
br label %674
47: ; preds = %39, %35
%48 = call i8* @getenv(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.39, i64 0, i64 0))
store i8* %48, i8** %17
%49 = load i16, i16* @strftime.first
%50 = icmp ne i16 %49, 0
br i1 %50, label %51, label %72
51: ; preds = %47
%52 = load i8*, i8** %17
%53 = icmp ne i8* %52, null
br i1 %53, label %54, label %70
54: ; preds = %51
%55 = load i8*, i8** %17
%56 = call i32 @strlen(i8* %55)
store i32 %56, i32* %18
%57 = load i32, i32* %18
%58 = add nsw i32 %57, 1
%59 = call i64 @malloc(i32 %58)
%60 = inttoptr i64 %59 to i8*
store i8* %60, i8** @strftime.savetz
%61 = load i8*, i8** @strftime.savetz
%62 = icmp ne i8* %61, null
br i1 %62, label %63, label %69
63: ; preds = %54
%64 = load i32, i32* %18
%65 = add nsw i32 %64, 1
store i32 %65, i32* @strftime.savetzlen
%66 = load i8*, i8** @strftime.savetz
%67 = load i8*, i8** %17
%68 = call i32 @strcpy(i8* %66, i8* %67)
br label %69
69: ; preds = %63, %54
br label %70
70: ; preds = %69, %51
%71 = call i32 (...) @tzset()
store i16 0, i16* @strftime.first
br label %72
72: ; preds = %70, %47
%73 = load i8*, i8** %17
%74 = icmp ne i8* %73, null
br i1 %74, label %75, label %119
75: ; preds = %72
%76 = load i8*, i8** @strftime.savetz
%77 = icmp ne i8* %76, null
br i1 %77, label %78, label %119
78: ; preds = %75
%79 = load i8*, i8** %17
%80 = getelementptr inbounds i8, i8* %79, i64 0
%81 = load i8, i8* %80
%82 = sext i8 %81 to i32
%83 = load i8*, i8** @strftime.savetz
%84 = getelementptr inbounds i8, i8* %83, i64 0
%85 = load i8, i8* %84
%86 = sext i8 %85 to i32
%87 = icmp ne i32 %82, %86
br i1 %87, label %93, label %88
88: ; preds = %78
%89 = load i8*, i8** %17
%90 = load i8*, i8** @strftime.savetz
%91 = call i64 @strcmp(i8* %89, i8* %90)
%92 = icmp ne i64 %91, 0
br i1 %92, label %93, label %119
93: ; preds = %88, %78
%94 = load i8*, i8** %17
%95 = call i32 @strlen(i8* %94)
%96 = add nsw i32 %95, 1
store i32 %96, i32* %14
%97 = load i32, i32* %14
%98 = load i32, i32* @strftime.savetzlen
%99 = icmp sgt i32 %97, %98
br i1 %99, label %100, label %113
100: ; preds = %93
%101 = load i8*, i8** @strftime.savetz
%102 = load i32, i32* %14
%103 = call i64 @realloc(i8* %101, i32 %102)
%104 = inttoptr i64 %103 to i8*
store i8* %104, i8** @strftime.savetz
%105 = load i8*, i8** @strftime.savetz
%106 = icmp ne i8* %105, null
br i1 %106, label %107, label %112
107: ; preds = %100
%108 = load i32, i32* %14
store i32 %108, i32* @strftime.savetzlen
%109 = load i8*, i8** @strftime.savetz
%110 = load i8*, i8** %17
%111 = call i32 @strcpy(i8* %109, i8* %110)
br label %112
112: ; preds = %107, %100
br label %117
113: ; preds = %93
%114 = load i8*, i8** @strftime.savetz
%115 = load i8*, i8** %17
%116 = call i32 @strcpy(i8* %114, i8* %115)
br label %117
117: ; preds = %113, %112
%118 = call i32 (...) @tzset()
br label %119
119: ; preds = %117, %88, %75, %72
br label %120
120: ; preds = %653, %119
%121 = load i8*, i8** %8
%122 = load i8, i8* %121
%123 = sext i8 %122 to i32
%124 = icmp ne i32 %123, 0
br i1 %124, label %125, label %130
125: ; preds = %120
%126 = load i8*, i8** %6
%127 = load i8*, i8** %10
%128 = getelementptr inbounds i8, i8* %127, i64 -1
%129 = icmp ult i8* %126, %128
br label %130
130: ; preds = %125, %120
%131 = phi i1 [ false, %120 ], [ %129, %125 ]
br i1 %131, label %132, label %656
132: ; preds = %130
%133 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
store i8 0, i8* %133
%134 = load i8*, i8** %8
%135 = load i8, i8* %134
%136 = sext i8 %135 to i32
%137 = icmp ne i32 %136, 37
br i1 %137, label %138, label %143
138: ; preds = %132
%139 = load i8*, i8** %8
%140 = load i8, i8* %139
%141 = load i8*, i8** %6
%142 = getelementptr inbounds i8, i8* %141, i32 1
store i8* %142, i8** %6
store i8 %140, i8* %141
br label %653
143: ; preds = %132
br label %144
144: ; preds = %547, %143
%145 = load i8*, i8** %8
%146 = getelementptr inbounds i8, i8* %145, i32 1
store i8* %146, i8** %8
%147 = load i8, i8* %146
%148 = sext i8 %147 to i32
switch i32 %148, label %623 [
i32 0, label %149
i32 37, label %152
i32 97, label %155
i32 65, label %178
i32 104, label %201
i32 98, label %201
i32 66, label %224
i32 99, label %247
i32 100, label %251
i32 72, label %262
i32 73, label %273
i32 106, label %295
i32 109, label %303
i32 77, label %316
i32 112, label %327
i32 83, label %345
i32 85, label %356
i32 119, label %362
i32 87, label %374
i32 120, label %380
i32 88, label %384
i32 121, label %388
i32 89, label %397
i32 122, label %405
i32 90, label %427
i32 110, label %433
i32 116, label %436
i32 68, label %439
i32 101, label %443
i32 114, label %451
i32 82, label %455
i32 84, label %459
i32 107, label %463
i32 108, label %471
i32 118, label %493
i32 67, label %538
i32 69, label %547
i32 79, label %547
i32 86, label %548
i32 117, label %554
i32 71, label %569
i32 103, label %569
]
149: ; preds = %144
%150 = load i8*, i8** %6
%151 = getelementptr inbounds i8, i8* %150, i32 1
store i8* %151, i8** %6
store i8 37, i8* %150
br label %657
152: ; preds = %144
%153 = load i8*, i8** %6
%154 = getelementptr inbounds i8, i8* %153, i32 1
store i8* %154, i8** %6
store i8 37, i8* %153
br label %653
155: ; preds = %144
%156 = load %struct.tm*, %struct.tm** %9
%157 = getelementptr inbounds %struct.tm, %struct.tm* %156, i32 0, i32 0
%158 = load i32, i32* %157
%159 = icmp slt i32 %158, 0
br i1 %159, label %165, label %160
160: ; preds = %155
%161 = load %struct.tm*, %struct.tm** %9
%162 = getelementptr inbounds %struct.tm, %struct.tm* %161, i32 0, i32 0
%163 = load i32, i32* %162
%164 = icmp sgt i32 %163, 6
br i1 %164, label %165, label %168
165: ; preds = %160, %155
%166 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%167 = call i32 @strcpy(i8* %166, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.40, i64 0, i64 0))
br label %177
168: ; preds = %160
%169 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%170 = load %struct.tm*, %struct.tm** %9
%171 = getelementptr inbounds %struct.tm, %struct.tm* %170, i32 0, i32 0
%172 = load i32, i32* %171
%173 = sext i32 %172 to i64
%174 = getelementptr inbounds [7 x i8*], [7 x i8*]* @strftime.days_a, i64 0, i64 %173
%175 = load i8*, i8** %174
%176 = call i32 @strcpy(i8* %169, i8* %175)
br label %177
177: ; preds = %168, %165
br label %629
178: ; preds = %144
%179 = load %struct.tm*, %struct.tm** %9
%180 = getelementptr inbounds %struct.tm, %struct.tm* %179, i32 0, i32 0
%181 = load i32, i32* %180
%182 = icmp slt i32 %181, 0
br i1 %182, label %188, label %183
183: ; preds = %178
%184 = load %struct.tm*, %struct.tm** %9
%185 = getelementptr inbounds %struct.tm, %struct.tm* %184, i32 0, i32 0
%186 = load i32, i32* %185
%187 = icmp sgt i32 %186, 6
br i1 %187, label %188, label %191
188: ; preds = %183, %178
%189 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%190 = call i32 @strcpy(i8* %189, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.40, i64 0, i64 0))
br label %200
191: ; preds = %183
%192 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%193 = load %struct.tm*, %struct.tm** %9
%194 = getelementptr inbounds %struct.tm, %struct.tm* %193, i32 0, i32 0
%195 = load i32, i32* %194
%196 = sext i32 %195 to i64
%197 = getelementptr inbounds [7 x i8*], [7 x i8*]* @strftime.days_l, i64 0, i64 %196
%198 = load i8*, i8** %197
%199 = call i32 @strcpy(i8* %192, i8* %198)
br label %200
200: ; preds = %191, %188
br label %629
201: ; preds = %144, %144
%202 = load %struct.tm*, %struct.tm** %9
%203 = getelementptr inbounds %struct.tm, %struct.tm* %202, i32 0, i32 1
%204 = load i32, i32* %203
%205 = icmp slt i32 %204, 0
br i1 %205, label %211, label %206
206: ; preds = %201
%207 = load %struct.tm*, %struct.tm** %9
%208 = getelementptr inbounds %struct.tm, %struct.tm* %207, i32 0, i32 1
%209 = load i32, i32* %208
%210 = icmp sgt i32 %209, 11
br i1 %210, label %211, label %214
211: ; preds = %206, %201
%212 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%213 = call i32 @strcpy(i8* %212, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.40, i64 0, i64 0))
br label %223
214: ; preds = %206
%215 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%216 = load %struct.tm*, %struct.tm** %9
%217 = getelementptr inbounds %struct.tm, %struct.tm* %216, i32 0, i32 1
%218 = load i32, i32* %217
%219 = sext i32 %218 to i64
%220 = getelementptr inbounds [12 x i8*], [12 x i8*]* @strftime.months_a, i64 0, i64 %219
%221 = load i8*, i8** %220
%222 = call i32 @strcpy(i8* %215, i8* %221)
br label %223
223: ; preds = %214, %211
br label %629
224: ; preds = %144
%225 = load %struct.tm*, %struct.tm** %9
%226 = getelementptr inbounds %struct.tm, %struct.tm* %225, i32 0, i32 1
%227 = load i32, i32* %226
%228 = icmp slt i32 %227, 0
br i1 %228, label %234, label %229
229: ; preds = %224
%230 = load %struct.tm*, %struct.tm** %9
%231 = getelementptr inbounds %struct.tm, %struct.tm* %230, i32 0, i32 1
%232 = load i32, i32* %231
%233 = icmp sgt i32 %232, 11
br i1 %233, label %234, label %237
234: ; preds = %229, %224
%235 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%236 = call i32 @strcpy(i8* %235, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.40, i64 0, i64 0))
br label %246
237: ; preds = %229
%238 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%239 = load %struct.tm*, %struct.tm** %9
%240 = getelementptr inbounds %struct.tm, %struct.tm* %239, i32 0, i32 1
%241 = load i32, i32* %240
%242 = sext i32 %241 to i64
%243 = getelementptr inbounds [12 x i8*], [12 x i8*]* @strftime.months_l, i64 0, i64 %242
%244 = load i8*, i8** %243
%245 = call i32 @strcpy(i8* %238, i8* %244)
br label %246
246: ; preds = %237, %234
br label %629
247: ; preds = %144
%248 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%249 = load %struct.tm*, %struct.tm** %9
%250 = call i64 @strftime(i8* %248, i64 100, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.41, i64 0, i64 0), %struct.tm* %249)
br label %629
251: ; preds = %144
%252 = load %struct.tm*, %struct.tm** %9
%253 = getelementptr inbounds %struct.tm, %struct.tm* %252, i32 0, i32 2
%254 = load i64, i64* %253
%255 = call i32 @min(i64 %254, i32 31)
%256 = call i64 @max(i32 1, i32 %255)
%257 = trunc i64 %256 to i32
store i32 %257, i32* %14
%258 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%259 = load i32, i32* %14
%260 = sext i32 %259 to i64
%261 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %258, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %260)
br label %629
262: ; preds = %144
%263 = load %struct.tm*, %struct.tm** %9
%264 = getelementptr inbounds %struct.tm, %struct.tm* %263, i32 0, i32 3
%265 = load i64, i64* %264
%266 = call i32 @min(i64 %265, i32 23)
%267 = call i64 @max(i32 0, i32 %266)
%268 = trunc i64 %267 to i32
store i32 %268, i32* %14
%269 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%270 = load i32, i32* %14
%271 = sext i32 %270 to i64
%272 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %269, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %271)
br label %629
273: ; preds = %144
%274 = load %struct.tm*, %struct.tm** %9
%275 = getelementptr inbounds %struct.tm, %struct.tm* %274, i32 0, i32 3
%276 = load i64, i64* %275
%277 = call i32 @min(i64 %276, i32 23)
%278 = call i64 @max(i32 0, i32 %277)
%279 = trunc i64 %278 to i32
store i32 %279, i32* %14
%280 = load i32, i32* %14
%281 = icmp eq i32 %280, 0
br i1 %281, label %282, label %283
282: ; preds = %273
store i32 12, i32* %14
br label %290
283: ; preds = %273
%284 = load i32, i32* %14
%285 = icmp sgt i32 %284, 12
br i1 %285, label %286, label %289
286: ; preds = %283
%287 = load i32, i32* %14
%288 = sub nsw i32 %287, 12
store i32 %288, i32* %14
br label %289
289: ; preds = %286, %283
br label %290
290: ; preds = %289, %282
%291 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%292 = load i32, i32* %14
%293 = sext i32 %292 to i64
%294 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %291, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %293)
br label %629
295: ; preds = %144
%296 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%297 = load %struct.tm*, %struct.tm** %9
%298 = getelementptr inbounds %struct.tm, %struct.tm* %297, i32 0, i32 9
%299 = load i32, i32* %298
%300 = add nsw i32 %299, 1
%301 = sext i32 %300 to i64
%302 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %296, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.43, i64 0, i64 0), i64 %301)
br label %629
303: ; preds = %144
%304 = load %struct.tm*, %struct.tm** %9
%305 = getelementptr inbounds %struct.tm, %struct.tm* %304, i32 0, i32 1
%306 = load i32, i32* %305
%307 = sext i32 %306 to i64
%308 = call i32 @min(i64 %307, i32 11)
%309 = call i64 @max(i32 0, i32 %308)
%310 = trunc i64 %309 to i32
store i32 %310, i32* %14
%311 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%312 = load i32, i32* %14
%313 = add nsw i32 %312, 1
%314 = sext i32 %313 to i64
%315 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %311, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %314)
br label %629
316: ; preds = %144
%317 = load %struct.tm*, %struct.tm** %9
%318 = getelementptr inbounds %struct.tm, %struct.tm* %317, i32 0, i32 4
%319 = load i64, i64* %318
%320 = call i32 @min(i64 %319, i32 59)
%321 = call i64 @max(i32 0, i32 %320)
%322 = trunc i64 %321 to i32
store i32 %322, i32* %14
%323 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%324 = load i32, i32* %14
%325 = sext i32 %324 to i64
%326 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %323, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %325)
br label %629
327: ; preds = %144
%328 = load %struct.tm*, %struct.tm** %9
%329 = getelementptr inbounds %struct.tm, %struct.tm* %328, i32 0, i32 3
%330 = load i64, i64* %329
%331 = call i32 @min(i64 %330, i32 23)
%332 = call i64 @max(i32 0, i32 %331)
%333 = trunc i64 %332 to i32
store i32 %333, i32* %14
%334 = load i32, i32* %14
%335 = icmp slt i32 %334, 12
br i1 %335, label %336, label %340
336: ; preds = %327
%337 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%338 = load i8*, i8** getelementptr inbounds ([2 x i8*], [2 x i8*]* @strftime.ampm, i64 0, i64 0)
%339 = call i32 @strcpy(i8* %337, i8* %338)
br label %344
340: ; preds = %327
%341 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%342 = load i8*, i8** getelementptr inbounds ([2 x i8*], [2 x i8*]* @strftime.ampm, i64 0, i64 1)
%343 = call i32 @strcpy(i8* %341, i8* %342)
br label %344
344: ; preds = %340, %336
br label %629
345: ; preds = %144
%346 = load %struct.tm*, %struct.tm** %9
%347 = getelementptr inbounds %struct.tm, %struct.tm* %346, i32 0, i32 5
%348 = load i64, i64* %347
%349 = call i32 @min(i64 %348, i32 60)
%350 = call i64 @max(i32 0, i32 %349)
%351 = trunc i64 %350 to i32
store i32 %351, i32* %14
%352 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%353 = load i32, i32* %14
%354 = sext i32 %353 to i64
%355 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %352, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %354)
br label %629
356: ; preds = %144
%357 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%358 = load %struct.tm*, %struct.tm** %9
%359 = call i32 @weeknumber(%struct.tm* %358, i32 0)
%360 = sext i32 %359 to i64
%361 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %357, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %360)
br label %629
362: ; preds = %144
%363 = load %struct.tm*, %struct.tm** %9
%364 = getelementptr inbounds %struct.tm, %struct.tm* %363, i32 0, i32 0
%365 = load i32, i32* %364
%366 = sext i32 %365 to i64
%367 = call i32 @min(i64 %366, i32 6)
%368 = call i64 @max(i32 0, i32 %367)
%369 = trunc i64 %368 to i32
store i32 %369, i32* %14
%370 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%371 = load i32, i32* %14
%372 = sext i32 %371 to i64
%373 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %370, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.44, i64 0, i64 0), i64 %372)
br label %629
374: ; preds = %144
%375 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%376 = load %struct.tm*, %struct.tm** %9
%377 = call i32 @weeknumber(%struct.tm* %376, i32 1)
%378 = sext i32 %377 to i64
%379 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %375, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %378)
br label %629
380: ; preds = %144
%381 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%382 = load %struct.tm*, %struct.tm** %9
%383 = call i64 @strftime(i8* %381, i64 100, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.45, i64 0, i64 0), %struct.tm* %382)
br label %629
384: ; preds = %144
%385 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%386 = load %struct.tm*, %struct.tm** %9
%387 = call i64 @strftime(i8* %385, i64 100, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.46, i64 0, i64 0), %struct.tm* %386)
br label %629
388: ; preds = %144
%389 = load %struct.tm*, %struct.tm** %9
%390 = getelementptr inbounds %struct.tm, %struct.tm* %389, i32 0, i32 6
%391 = load i32, i32* %390
%392 = srem i32 %391, 100
store i32 %392, i32* %14
%393 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%394 = load i32, i32* %14
%395 = sext i32 %394 to i64
%396 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %393, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %395)
br label %629
397: ; preds = %144
%398 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%399 = load %struct.tm*, %struct.tm** %9
%400 = getelementptr inbounds %struct.tm, %struct.tm* %399, i32 0, i32 6
%401 = load i32, i32* %400
%402 = sext i32 %401 to i64
%403 = add nsw i64 1900, %402
%404 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %398, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.47, i64 0, i64 0), i64 %403)
br label %629
405: ; preds = %144
%406 = load %struct.tm*, %struct.tm** %9
%407 = getelementptr inbounds %struct.tm, %struct.tm* %406, i32 0, i32 7
%408 = load i32, i32* %407
%409 = sdiv i32 %408, 60
%410 = sext i32 %409 to i64
store i64 %410, i64* %13
%411 = load i64, i64* %13
%412 = icmp slt i64 %411, 0
br i1 %412, label %413, label %417
413: ; preds = %405
%414 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
store i8 45, i8* %414
%415 = load i64, i64* %13
%416 = sub nsw i64 0, %415
store i64 %416, i64* %13
br label %419
417: ; preds = %405
%418 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
store i8 43, i8* %418
br label %419
419: ; preds = %417, %413
%420 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%421 = getelementptr inbounds i8, i8* %420, i64 1
%422 = load i64, i64* %13
%423 = sdiv i64 %422, 60
%424 = load i64, i64* %13
%425 = srem i64 %424, 60
%426 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %421, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.48, i64 0, i64 0), i64 %423, i64 %425)
br label %629
427: ; preds = %144
%428 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%429 = load %struct.tm*, %struct.tm** %9
%430 = getelementptr inbounds %struct.tm, %struct.tm* %429, i32 0, i32 8
%431 = load i8*, i8** %430
%432 = call i32 @strcpy(i8* %428, i8* %431)
br label %629
433: ; preds = %144
%434 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
store i8 10, i8* %434
%435 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 1
store i8 0, i8* %435
br label %629
436: ; preds = %144
%437 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
store i8 9, i8* %437
%438 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 1
store i8 0, i8* %438
br label %629
439: ; preds = %144
%440 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%441 = load %struct.tm*, %struct.tm** %9
%442 = call i64 @strftime(i8* %440, i64 100, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.45, i64 0, i64 0), %struct.tm* %441)
br label %629
443: ; preds = %144
%444 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%445 = load %struct.tm*, %struct.tm** %9
%446 = getelementptr inbounds %struct.tm, %struct.tm* %445, i32 0, i32 2
%447 = load i64, i64* %446
%448 = call i32 @min(i64 %447, i32 31)
%449 = call i64 @max(i32 1, i32 %448)
%450 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %444, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.49, i64 0, i64 0), i64 %449)
br label %629
451: ; preds = %144
%452 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%453 = load %struct.tm*, %struct.tm** %9
%454 = call i64 @strftime(i8* %452, i64 100, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.50, i64 0, i64 0), %struct.tm* %453)
br label %629
455: ; preds = %144
%456 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%457 = load %struct.tm*, %struct.tm** %9
%458 = call i64 @strftime(i8* %456, i64 100, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.51, i64 0, i64 0), %struct.tm* %457)
br label %629
459: ; preds = %144
%460 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%461 = load %struct.tm*, %struct.tm** %9
%462 = call i64 @strftime(i8* %460, i64 100, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.46, i64 0, i64 0), %struct.tm* %461)
br label %629
463: ; preds = %144
%464 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%465 = load %struct.tm*, %struct.tm** %9
%466 = getelementptr inbounds %struct.tm, %struct.tm* %465, i32 0, i32 3
%467 = load i64, i64* %466
%468 = call i32 @min(i64 %467, i32 23)
%469 = call i64 @max(i32 0, i32 %468)
%470 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %464, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.49, i64 0, i64 0), i64 %469)
br label %629
471: ; preds = %144
%472 = load %struct.tm*, %struct.tm** %9
%473 = getelementptr inbounds %struct.tm, %struct.tm* %472, i32 0, i32 3
%474 = load i64, i64* %473
%475 = call i32 @min(i64 %474, i32 23)
%476 = call i64 @max(i32 0, i32 %475)
%477 = trunc i64 %476 to i32
store i32 %477, i32* %14
%478 = load i32, i32* %14
%479 = icmp eq i32 %478, 0
br i1 %479, label %480, label %481
480: ; preds = %471
store i32 12, i32* %14
br label %488
481: ; preds = %471
%482 = load i32, i32* %14
%483 = icmp sgt i32 %482, 12
br i1 %483, label %484, label %487
484: ; preds = %481
%485 = load i32, i32* %14
%486 = sub nsw i32 %485, 12
store i32 %486, i32* %14
br label %487
487: ; preds = %484, %481
br label %488
488: ; preds = %487, %480
%489 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%490 = load i32, i32* %14
%491 = sext i32 %490 to i64
%492 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %489, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.49, i64 0, i64 0), i64 %491)
br label %629
493: ; preds = %144
%494 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%495 = load %struct.tm*, %struct.tm** %9
%496 = getelementptr inbounds %struct.tm, %struct.tm* %495, i32 0, i32 2
%497 = load i64, i64* %496
%498 = call i32 @min(i64 %497, i32 31)
%499 = call i64 @max(i32 1, i32 %498)
%500 = load %struct.tm*, %struct.tm** %9
%501 = getelementptr inbounds %struct.tm, %struct.tm* %500, i32 0, i32 1
%502 = load i32, i32* %501
%503 = sext i32 %502 to i64
%504 = call i32 @min(i64 %503, i32 11)
%505 = call i64 @max(i32 0, i32 %504)
%506 = getelementptr inbounds [12 x i8*], [12 x i8*]* @strftime.months_a, i64 0, i64 %505
%507 = load i8*, i8** %506
%508 = load %struct.tm*, %struct.tm** %9
%509 = getelementptr inbounds %struct.tm, %struct.tm* %508, i32 0, i32 6
%510 = load i32, i32* %509
%511 = sext i32 %510 to i64
%512 = add nsw i64 %511, 1900
%513 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %494, i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.52, i64 0, i64 0), i64 %499, i8* %507, i64 %512)
store i32 3, i32* %14
br label %514
514: ; preds = %534, %493
%515 = load i32, i32* %14
%516 = icmp slt i32 %515, 6
br i1 %516, label %517, label %537
517: ; preds = %514
%518 = load i32, i32* %14
%519 = sext i32 %518 to i64
%520 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 %519
%521 = load i8, i8* %520
%522 = call i32 @islower(i8 signext %521)
%523 = icmp ne i32 %522, 0
br i1 %523, label %524, label %533
524: ; preds = %517
%525 = load i32, i32* %14
%526 = sext i32 %525 to i64
%527 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 %526
%528 = load i8, i8* %527
%529 = call signext i8 @toupper(i8 signext %528)
%530 = load i32, i32* %14
%531 = sext i32 %530 to i64
%532 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 %531
store i8 %529, i8* %532
br label %533
533: ; preds = %524, %517
br label %534
534: ; preds = %533
%535 = load i32, i32* %14
%536 = add nsw i32 %535, 1
store i32 %536, i32* %14
br label %514
537: ; preds = %514
br label %629
538: ; preds = %144
%539 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%540 = load %struct.tm*, %struct.tm** %9
%541 = getelementptr inbounds %struct.tm, %struct.tm* %540, i32 0, i32 6
%542 = load i32, i32* %541
%543 = sext i32 %542 to i64
%544 = add nsw i64 %543, 1900
%545 = sdiv i64 %544, 100
%546 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %539, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.53, i64 0, i64 0), i64 %545)
br label %629
547: ; preds = %144, %144
br label %144
548: ; preds = %144
%549 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%550 = load %struct.tm*, %struct.tm** %9
%551 = call i32 @iso8601wknum(%struct.tm* %550)
%552 = sext i32 %551 to i64
%553 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %549, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %552)
br label %629
554: ; preds = %144
%555 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%556 = load %struct.tm*, %struct.tm** %9
%557 = getelementptr inbounds %struct.tm, %struct.tm* %556, i32 0, i32 0
%558 = load i32, i32* %557
%559 = icmp eq i32 %558, 0
br i1 %559, label %560, label %561
560: ; preds = %554
br label %565
561: ; preds = %554
%562 = load %struct.tm*, %struct.tm** %9
%563 = getelementptr inbounds %struct.tm, %struct.tm* %562, i32 0, i32 0
%564 = load i32, i32* %563
br label %565
565: ; preds = %561, %560
%566 = phi i32 [ 7, %560 ], [ %564, %561 ]
%567 = sext i32 %566 to i64
%568 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %555, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.44, i64 0, i64 0), i64 %567)
br label %629
569: ; preds = %144, %144
%570 = load %struct.tm*, %struct.tm** %9
%571 = call i32 @iso8601wknum(%struct.tm* %570)
store i32 %571, i32* %15
%572 = load %struct.tm*, %struct.tm** %9
%573 = getelementptr inbounds %struct.tm, %struct.tm* %572, i32 0, i32 1
%574 = load i32, i32* %573
%575 = icmp eq i32 %574, 11
br i1 %575, label %576, label %586
576: ; preds = %569
%577 = load i32, i32* %15
%578 = icmp eq i32 %577, 1
br i1 %578, label %579, label %586
579: ; preds = %576
%580 = load %struct.tm*, %struct.tm** %9
%581 = getelementptr inbounds %struct.tm, %struct.tm* %580, i32 0, i32 6
%582 = load i32, i32* %581
%583 = sext i32 %582 to i64
%584 = add nsw i64 1900, %583
%585 = add nsw i64 %584, 1
store i64 %585, i64* %16
br label %608
586: ; preds = %576, %569
%587 = load %struct.tm*, %struct.tm** %9
%588 = getelementptr inbounds %struct.tm, %struct.tm* %587, i32 0, i32 1
%589 = load i32, i32* %588
%590 = icmp eq i32 %589, 0
br i1 %590, label %591, label %601
591: ; preds = %586
%592 = load i32, i32* %15
%593 = icmp sge i32 %592, 52
br i1 %593, label %594, label %601
594: ; preds = %591
%595 = load %struct.tm*, %struct.tm** %9
%596 = getelementptr inbounds %struct.tm, %struct.tm* %595, i32 0, i32 6
%597 = load i32, i32* %596
%598 = sext i32 %597 to i64
%599 = add nsw i64 1900, %598
%600 = sub nsw i64 %599, 1
store i64 %600, i64* %16
br label %607
601: ; preds = %591, %586
%602 = load %struct.tm*, %struct.tm** %9
%603 = getelementptr inbounds %struct.tm, %struct.tm* %602, i32 0, i32 6
%604 = load i32, i32* %603
%605 = sext i32 %604 to i64
%606 = add nsw i64 1900, %605
store i64 %606, i64* %16
br label %607
607: ; preds = %601, %594
br label %608
608: ; preds = %607, %579
%609 = load i8*, i8** %8
%610 = load i8, i8* %609
%611 = sext i8 %610 to i32
%612 = icmp eq i32 %611, 71
br i1 %612, label %613, label %617
613: ; preds = %608
%614 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%615 = load i64, i64* %16
%616 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %614, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.47, i64 0, i64 0), i64 %615)
br label %622
617: ; preds = %608
%618 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%619 = load i64, i64* %16
%620 = srem i64 %619, 100
%621 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %618, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.53, i64 0, i64 0), i64 %620)
br label %622
622: ; preds = %617, %613
br label %629
623: ; preds = %144
%624 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
store i8 37, i8* %624
%625 = load i8*, i8** %8
%626 = load i8, i8* %625
%627 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 1
store i8 %626, i8* %627
%628 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 2
store i8 0, i8* %628
br label %629
629: ; preds = %623, %622, %565, %548, %538, %537, %488, %463, %459, %455, %451, %443, %439, %436, %433, %427, %419, %397, %388, %384, %380, %374, %362, %356, %345, %344, %316, %303, %295, %290, %262, %251, %247, %246, %223, %200, %177
%630 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%631 = call i32 @strlen(i8* %630)
store i32 %631, i32* %14
%632 = load i32, i32* %14
%633 = icmp ne i32 %632, 0
br i1 %633, label %634, label %652
634: ; preds = %629
%635 = load i8*, i8** %6
%636 = load i32, i32* %14
%637 = sext i32 %636 to i64
%638 = getelementptr inbounds i8, i8* %635, i64 %637
%639 = load i8*, i8** %10
%640 = getelementptr inbounds i8, i8* %639, i64 -1
%641 = icmp ult i8* %638, %640
br i1 %641, label %642, label %650
642: ; preds = %634
%643 = load i8*, i8** %6
%644 = getelementptr inbounds [100 x i8], [100 x i8]* %12, i64 0, i64 0
%645 = call i32 @strcpy(i8* %643, i8* %644)
%646 = load i32, i32* %14
%647 = load i8*, i8** %6
%648 = sext i32 %646 to i64
%649 = getelementptr inbounds i8, i8* %647, i64 %648
store i8* %649, i8** %6
br label %651
650: ; preds = %634
store i64 0, i64* %5
br label %674
651: ; preds = %642
br label %652
652: ; preds = %651, %629
br label %653
653: ; preds = %652, %152, %138
%654 = load i8*, i8** %8
%655 = getelementptr inbounds i8, i8* %654, i32 1
store i8* %655, i8** %8
br label %120
656: ; preds = %130
br label %657
657: ; preds = %656, %149
%658 = load i8*, i8** %6
%659 = load i8*, i8** %10
%660 = icmp ult i8* %658, %659
br i1 %660, label %661, label %673
661: ; preds = %657
%662 = load i8*, i8** %8
%663 = load i8, i8* %662
%664 = sext i8 %663 to i32
%665 = icmp eq i32 %664, 0
br i1 %665, label %666, label %673
666: ; preds = %661
%667 = load i8*, i8** %6
store i8 0, i8* %667
%668 = load i8*, i8** %6
%669 = load i8*, i8** %11
%670 = ptrtoint i8* %668 to i64
%671 = ptrtoint i8* %669 to i64
%672 = sub i64 %670, %671
store i64 %672, i64* %5
br label %674
673: ; preds = %661, %657
store i64 0, i64* %5
br label %674
674: ; preds = %673, %666, %650, %46, %34
%675 = load i64, i64* %5
ret i64 %675
}

LLVM IR (-O2):
%struct.tm = type { i32, i32, i64, i64, i64, i64, i32, i32, i8*, i32 }
@strftime.first = internal unnamed_addr global i1 false
@strftime.savetz = internal unnamed_addr global i8* null
@strftime.savetzlen = internal unnamed_addr global i32 0
@reltable.strftime = internal unnamed_addr constant [7 x i32] [i32 trunc (i64 sub (i64 ptrtoint ([4 x i8]* @.str to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([4 x i8]* @.str.1 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([4 x i8]* @.str.2 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([4 x i8]* @.str.3 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([4 x i8]* @.str.4 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([4 x i8]* @.str.5 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([4 x i8]* @.str.6 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime to i64)) to i32)]
@.str = [4 x i8] c"Sun\00"
@.str.1 = [4 x i8] c"Mon\00"
@.str.2 = [4 x i8] c"Tue\00"
@.str.3 = [4 x i8] c"Wed\00"
@.str.4 = [4 x i8] c"Thu\00"
@.str.5 = [4 x i8] c"Fri\00"
@.str.6 = [4 x i8] c"Sat\00"
@reltable.strftime.54 = internal unnamed_addr constant [7 x i32] [i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.7 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime.54 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.8 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime.54 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([8 x i8]* @.str.9 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime.54 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([10 x i8]* @.str.10 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime.54 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([9 x i8]* @.str.11 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime.54 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.12 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime.54 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([9 x i8]* @.str.13 to i64), i64 ptrtoint ([7 x i32]* @reltable.strftime.54 to i64)) to i32)]
@.str.7 = [7 x i8] c"Sunday\00"
@.str.8 = [7 x i8] c"Monday\00"
@.str.9 = [8 x i8] c"Tuesday\00"
@.str.10 = [10 x i8] c"Wednesday\00"
@.str.11 = [9 x i8] c"Thursday\00"
@.str.12 = [7 x i8] c"Friday\00"
@.str.13 = [9 x i8] c"Saturday\00"
@strftime.months_a = internal unnamed_addr constant [12 x i8*] [i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.14, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.15, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.16, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.17, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.18, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.19, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.20, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.21, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.22, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.23, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.24, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.25, i32 0, i32 0)]
@.str.14 = [4 x i8] c"Jan\00"
@.str.15 = [4 x i8] c"Feb\00"
@.str.16 = [4 x i8] c"Mar\00"
@.str.17 = [4 x i8] c"Apr\00"
@.str.18 = [4 x i8] c"May\00"
@.str.19 = [4 x i8] c"Jun\00"
@.str.20 = [4 x i8] c"Jul\00"
@.str.21 = [4 x i8] c"Aug\00"
@.str.22 = [4 x i8] c"Sep\00"
@.str.23 = [4 x i8] c"Oct\00"
@.str.24 = [4 x i8] c"Nov\00"
@.str.25 = [4 x i8] c"Dec\00"
@reltable.strftime.55 = internal unnamed_addr constant [12 x i32] [i32 trunc (i64 sub (i64 ptrtoint ([8 x i8]* @.str.26 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([9 x i8]* @.str.27 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([6 x i8]* @.str.28 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([6 x i8]* @.str.29 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([4 x i8]* @.str.18 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.30 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.31 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.32 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([10 x i8]* @.str.33 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([8 x i8]* @.str.34 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([9 x i8]* @.str.35 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([9 x i8]* @.str.36 to i64), i64 ptrtoint ([12 x i32]* @reltable.strftime.55 to i64)) to i32)]
@.str.26 = [8 x i8] c"January\00"
@.str.27 = [9 x i8] c"February\00"
@.str.28 = [6 x i8] c"March\00"
@.str.29 = [6 x i8] c"April\00"
@.str.30 = [5 x i8] c"June\00"
@.str.31 = [5 x i8] c"July\00"
@.str.32 = [7 x i8] c"August\00"
@.str.33 = [10 x i8] c"September\00"
@.str.34 = [8 x i8] c"October\00"
@.str.35 = [9 x i8] c"November\00"
@.str.36 = [9 x i8] c"December\00"
@.str.37 = [3 x i8] c"AM\00"
@.str.38 = [3 x i8] c"PM\00"
@.str.39 = [3 x i8] c"TZ\00"
@.str.40 = [2 x i8] c"?\00"
@.str.41 = [21 x i8] c"%a %b %e %H:%M:%S %Y\00"
@.str.42 = [5 x i8] c"%02d\00"
@.str.43 = [5 x i8] c"%03d\00"
@.str.44 = [3 x i8] c"%d\00"
@.str.45 = [9 x i8] c"%m/%d/%y\00"
@.str.46 = [9 x i8] c"%H:%M:%S\00"
@.str.47 = [4 x i8] c"%ld\00"
@.str.48 = [9 x i8] c"%02d%02d\00"
@.str.49 = [4 x i8] c"%2d\00"
@.str.50 = [12 x i8] c"%I:%M:%S %p\00"
@.str.51 = [6 x i8] c"%H:%M\00"
@.str.52 = [15 x i8] c"%2d-%3.3s-%4ld\00"
@.str.53 = [6 x i8] c"%02ld\00"
define i64 @strftime(i8* %0, i64 %1, i8* %2, %struct.tm* %3) {
%5 = alloca [100 x i8]
%6 = getelementptr inbounds i8, i8* %0, i64 %1
%7 = getelementptr inbounds [100 x i8], [100 x i8]* %5, i64 0, i64 0
%8 = icmp eq i8* %0, null
%9 = icmp eq i8* %2, null
%10 = or i1 %8, %9
%11 = icmp eq %struct.tm* %3, null
%12 = or i1 %10, %11
%13 = icmp eq i64 %1, 0
%14 = or i1 %13, %12
br i1 %14, label %400, label %15
15: ; preds = %4
%16 = tail call i32* @strchr(i8* %2, i8 signext 37)
%17 = icmp eq i32* %16, null
br i1 %17, label %18, label %23
18: ; preds = %15
%19 = tail call i32 @strlen(i8* %2)
%20 = add nsw i32 %19, 1
%21 = sext i32 %20 to i64
%22 = icmp ult i64 %21, %1
br i1 %22, label %23, label %400
23: ; preds = %18, %15
%24 = tail call i8* @getenv(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.39, i64 0, i64 0))
%25 = load i1, i1* @strftime.first
br i1 %25, label %38, label %26
26: ; preds = %23
%27 = icmp eq i8* %24, null
br i1 %27, label %36, label %28
28: ; preds = %26
%29 = tail call i32 @strlen(i8* %24)
%30 = add nsw i32 %29, 1
%31 = tail call i64 @malloc(i32 %30)
%32 = inttoptr i64 %31 to i8*
store i8* %32, i8** @strftime.savetz
%33 = icmp eq i64 %31, 0
br i1 %33, label %36, label %34
34: ; preds = %28
store i32 %30, i32* @strftime.savetzlen
%35 = tail call i32 @strcpy(i8* %32, i8* %24)
br label %36
36: ; preds = %28, %34, %26
%37 = tail call i32 (...) @tzset()
store i1 true, i1* @strftime.first
br label %38
38: ; preds = %36, %23
%39 = icmp ne i8* %24, null
%40 = load i8*, i8** @strftime.savetz
%41 = icmp ne i8* %40, null
%42 = select i1 %39, i1 %41, i1 false
br i1 %42, label %43, label %66
43: ; preds = %38
%44 = load i8, i8* %24
%45 = load i8, i8* %40
%46 = icmp eq i8 %44, %45
br i1 %46, label %47, label %50
47: ; preds = %43
%48 = tail call i64 @strcmp(i8* %24, i8* %40)
%49 = icmp eq i64 %48, 0
br i1 %49, label %66, label %50
50: ; preds = %47, %43
%51 = tail call i32 @strlen(i8* %24)
%52 = add nsw i32 %51, 1
%53 = load i32, i32* @strftime.savetzlen
%54 = icmp slt i32 %51, %53
%55 = load i8*, i8** @strftime.savetz
br i1 %54, label %62, label %56
56: ; preds = %50
%57 = tail call i64 @realloc(i8* %55, i32 %52)
%58 = inttoptr i64 %57 to i8*
store i8* %58, i8** @strftime.savetz
%59 = icmp eq i64 %57, 0
br i1 %59, label %64, label %60
60: ; preds = %56
store i32 %52, i32* @strftime.savetzlen
%61 = tail call i32 @strcpy(i8* %58, i8* %24)
br label %64
62: ; preds = %50
%63 = tail call i32 @strcpy(i8* %55, i8* %24)
br label %64
64: ; preds = %56, %60, %62
%65 = tail call i32 (...) @tzset()
br label %66
66: ; preds = %64, %47, %38
%67 = getelementptr inbounds i8, i8* %6, i64 -1
%68 = load i8, i8* %2
%69 = icmp ne i8 %68, 0
%70 = icmp ugt i8* %67, %0
%71 = select i1 %69, i1 %70, i1 false
br i1 %71, label %72, label %389
72: ; preds = %66
%73 = getelementptr inbounds %struct.tm, %struct.tm* %3, i64 0, i32 1
%74 = getelementptr inbounds %struct.tm, %struct.tm* %3, i64 0, i32 6
%75 = getelementptr inbounds %struct.tm, %struct.tm* %3, i64 0, i32 0
%76 = getelementptr inbounds %struct.tm, %struct.tm* %3, i64 0, i32 2
%77 = getelementptr inbounds %struct.tm, %struct.tm* %3, i64 0, i32 3
%78 = getelementptr inbounds [100 x i8], [100 x i8]* %5, i64 0, i64 1
%79 = getelementptr inbounds %struct.tm, %struct.tm* %3, i64 0, i32 8
%80 = getelementptr inbounds %struct.tm, %struct.tm* %3, i64 0, i32 7
%81 = getelementptr inbounds %struct.tm, %struct.tm* %3, i64 0, i32 5
%82 = getelementptr inbounds %struct.tm, %struct.tm* %3, i64 0, i32 4
%83 = getelementptr inbounds %struct.tm, %struct.tm* %3, i64 0, i32 9
%84 = getelementptr inbounds [100 x i8], [100 x i8]* %5, i64 0, i64 2
%85 = getelementptr inbounds [100 x i8], [100 x i8]* %5, i64 0, i64 3
%86 = getelementptr inbounds [100 x i8], [100 x i8]* %5, i64 0, i64 4
%87 = getelementptr inbounds [100 x i8], [100 x i8]* %5, i64 0, i64 5
br label %88
88: ; preds = %72, %381
%89 = phi i8 [ %68, %72 ], [ %385, %381 ]
%90 = phi i8* [ %0, %72 ], [ %383, %381 ]
%91 = phi i8* [ %2, %72 ], [ %384, %381 ]
store i8 0, i8* %7
%92 = icmp eq i8 %89, 37
br i1 %92, label %95, label %93
93: ; preds = %88
%94 = getelementptr inbounds i8, i8* %90, i64 1
store i8 %89, i8* %90
br label %381
95: ; preds = %88, %100
%96 = phi i8* [ %97, %100 ], [ %91, %88 ]
%97 = getelementptr inbounds i8, i8* %96, i64 1
%98 = load i8, i8* %97
%99 = sext i8 %98 to i32
switch i32 %99, label %371 [
i32 0, label %101
i32 37, label %103
i32 97, label %105
i32 65, label %115
i32 104, label %125
i32 98, label %125
i32 66, label %135
i32 99, label %145
i32 100, label %147
i32 72, label %154
i32 73, label %161
i32 106, label %174
i32 109, label %179
i32 77, label %188
i32 112, label %195
i32 83, label %205
i32 85, label %212
i32 119, label %216
i32 87, label %224
i32 120, label %228
i32 88, label %230
i32 121, label %232
i32 89, label %237
i32 122, label %242
i32 90, label %256
i32 110, label %259
i32 116, label %260
i32 68, label %261
i32 101, label %263
i32 114, label %268
i32 82, label %270
i32 84, label %272
i32 107, label %274
i32 108, label %279
i32 118, label %292
i32 67, label %326
i32 69, label %100
i32 79, label %100
i32 86, label %332
i32 117, label %336
i32 71, label %342
i32 103, label %342
]
100: ; preds = %95, %95
br label %95
101: ; preds = %95
%102 = getelementptr inbounds i8, i8* %90, i64 1
store i8 37, i8* %90
br label %389
103: ; preds = %95
%104 = getelementptr inbounds i8, i8* %90, i64 1
store i8 37, i8* %90
br label %381
105: ; preds = %95
%106 = load i32, i32* %75
%107 = icmp ugt i32 %106, 6
br i1 %107, label %108, label %110
108: ; preds = %105
%109 = call i32 @strcpy(i8* %7, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.40, i64 0, i64 0))
br label %372
110: ; preds = %105
%111 = zext i32 %106 to i64
%112 = shl i64 %111, 2
%113 = call i8* @llvm.load.relative.i64(i8* bitcast ([7 x i32]* @reltable.strftime to i8*), i64 %112)
%114 = call i32 @strcpy(i8* %7, i8* %113)
br label %372
115: ; preds = %95
%116 = load i32, i32* %75
%117 = icmp ugt i32 %116, 6
br i1 %117, label %118, label %120
118: ; preds = %115
%119 = call i32 @strcpy(i8* %7, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.40, i64 0, i64 0))
br label %372
120: ; preds = %115
%121 = zext i32 %116 to i64
%122 = shl i64 %121, 2
%123 = call i8* @llvm.load.relative.i64(i8* bitcast ([7 x i32]* @reltable.strftime.54 to i8*), i64 %122)
%124 = call i32 @strcpy(i8* %7, i8* %123)
br label %372
125: ; preds = %95, %95
%126 = load i32, i32* %73
%127 = icmp ugt i32 %126, 11
br i1 %127, label %128, label %130
128: ; preds = %125
%129 = call i32 @strcpy(i8* %7, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.40, i64 0, i64 0))
br label %372
130: ; preds = %125
%131 = zext i32 %126 to i64
%132 = getelementptr inbounds [12 x i8*], [12 x i8*]* @strftime.months_a, i64 0, i64 %131
%133 = load i8*, i8** %132
%134 = call i32 @strcpy(i8* %7, i8* %133)
br label %372
135: ; preds = %95
%136 = load i32, i32* %73
%137 = icmp ugt i32 %136, 11
br i1 %137, label %138, label %140
138: ; preds = %135
%139 = call i32 @strcpy(i8* %7, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.40, i64 0, i64 0))
br label %372
140: ; preds = %135
%141 = zext i32 %136 to i64
%142 = shl i64 %141, 2
%143 = call i8* @llvm.load.relative.i64(i8* bitcast ([12 x i32]* @reltable.strftime.55 to i8*), i64 %142)
%144 = call i32 @strcpy(i8* %7, i8* %143)
br label %372
145: ; preds = %95
%146 = call i64 @strftime(i8* %7, i64 100, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.41, i64 0, i64 0), %struct.tm* %3)
br label %372
147: ; preds = %95
%148 = load i64, i64* %76
%149 = call i32 @min(i64 %148, i32 31)
%150 = call i64 @max(i32 1, i32 %149)
%151 = shl i64 %150, 32
%152 = ashr exact i64 %151, 32
%153 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %152)
br label %372
154: ; preds = %95
%155 = load i64, i64* %77
%156 = call i32 @min(i64 %155, i32 23)
%157 = call i64 @max(i32 0, i32 %156)
%158 = shl i64 %157, 32
%159 = ashr exact i64 %158, 32
%160 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %159)
br label %372
161: ; preds = %95
%162 = load i64, i64* %77
%163 = call i32 @min(i64 %162, i32 23)
%164 = call i64 @max(i32 0, i32 %163)
%165 = trunc i64 %164 to i32
%166 = icmp eq i32 %165, 0
%167 = icmp sgt i32 %165, 12
%168 = shl i64 %164, 32
%169 = add i64 %168, -51539607552
%170 = select i1 %167, i64 %169, i64 %168
%171 = ashr exact i64 %170, 32
%172 = select i1 %166, i64 12, i64 %171
%173 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %172)
br label %372
174: ; preds = %95
%175 = load i32, i32* %83
%176 = add nsw i32 %175, 1
%177 = sext i32 %176 to i64
%178 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.43, i64 0, i64 0), i64 %177)
br label %372
179: ; preds = %95
%180 = load i32, i32* %73
%181 = sext i32 %180 to i64
%182 = call i32 @min(i64 %181, i32 11)
%183 = call i64 @max(i32 0, i32 %182)
%184 = shl i64 %183, 32
%185 = add i64 %184, 4294967296
%186 = ashr exact i64 %185, 32
%187 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %186)
br label %372
188: ; preds = %95
%189 = load i64, i64* %82
%190 = call i32 @min(i64 %189, i32 59)
%191 = call i64 @max(i32 0, i32 %190)
%192 = shl i64 %191, 32
%193 = ashr exact i64 %192, 32
%194 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %193)
br label %372
195: ; preds = %95
%196 = load i64, i64* %77
%197 = call i32 @min(i64 %196, i32 23)
%198 = call i64 @max(i32 0, i32 %197)
%199 = trunc i64 %198 to i32
%200 = icmp slt i32 %199, 12
br i1 %200, label %201, label %203
201: ; preds = %195
%202 = call i32 @strcpy(i8* %7, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.37, i64 0, i64 0))
br label %372
203: ; preds = %195
%204 = call i32 @strcpy(i8* %7, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.38, i64 0, i64 0))
br label %372
205: ; preds = %95
%206 = load i64, i64* %81
%207 = call i32 @min(i64 %206, i32 60)
%208 = call i64 @max(i32 0, i32 %207)
%209 = shl i64 %208, 32
%210 = ashr exact i64 %209, 32
%211 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %210)
br label %372
212: ; preds = %95
%213 = call i32 @weeknumber(%struct.tm* %3, i32 0)
%214 = sext i32 %213 to i64
%215 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %214)
br label %372
216: ; preds = %95
%217 = load i32, i32* %75
%218 = sext i32 %217 to i64
%219 = call i32 @min(i64 %218, i32 6)
%220 = call i64 @max(i32 0, i32 %219)
%221 = shl i64 %220, 32
%222 = ashr exact i64 %221, 32
%223 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @.str.44, i64 0, i64 0), i64 %222)
br label %372
224: ; preds = %95
%225 = call i32 @weeknumber(%struct.tm* %3, i32 1)
%226 = sext i32 %225 to i64
%227 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %226)
br label %372
228: ; preds = %95
%229 = call i64 @strftime(i8* %7, i64 100, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.45, i64 0, i64 0), %struct.tm* %3)
br label %372
230: ; preds = %95
%231 = call i64 @strftime(i8* %7, i64 100, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.46, i64 0, i64 0), %struct.tm* %3)
br label %372
232: ; preds = %95
%233 = load i32, i32* %74
%234 = srem i32 %233, 100
%235 = sext i32 %234 to i64
%236 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %235)
br label %372
237: ; preds = %95
%238 = load i32, i32* %74
%239 = sext i32 %238 to i64
%240 = add nsw i64 %239, 1900
%241 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.47, i64 0, i64 0), i64 %240)
br label %372
242: ; preds = %95
%243 = load i32, i32* %80
%244 = sdiv i32 %243, 60
%245 = icmp slt i32 %243, -59
br i1 %245, label %246, label %248
246: ; preds = %242
store i8 45, i8* %7
%247 = sub nsw i32 0, %244
br label %249
248: ; preds = %242
store i8 43, i8* %7
br label %249
249: ; preds = %248, %246
%250 = phi i32 [ %247, %246 ], [ %244, %248 ]
%251 = sdiv i32 %250, 60
%252 = sext i32 %251 to i64
%253 = srem i32 %250, 60
%254 = sext i32 %253 to i64
%255 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %78, i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.48, i64 0, i64 0), i64 %252, i64 %254)
br label %372
256: ; preds = %95
%257 = load i8*, i8** %79
%258 = call i32 @strcpy(i8* %7, i8* %257)
br label %372
259: ; preds = %95
store i8 10, i8* %7
store i8 0, i8* %78
br label %372
260: ; preds = %95
store i8 9, i8* %7
store i8 0, i8* %78
br label %372
261: ; preds = %95
%262 = call i64 @strftime(i8* %7, i64 100, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.45, i64 0, i64 0), %struct.tm* %3)
br label %372
263: ; preds = %95
%264 = load i64, i64* %76
%265 = call i32 @min(i64 %264, i32 31)
%266 = call i64 @max(i32 1, i32 %265)
%267 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.49, i64 0, i64 0), i64 %266)
br label %372
268: ; preds = %95
%269 = call i64 @strftime(i8* %7, i64 100, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.50, i64 0, i64 0), %struct.tm* %3)
br label %372
270: ; preds = %95
%271 = call i64 @strftime(i8* %7, i64 100, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.51, i64 0, i64 0), %struct.tm* %3)
br label %372
272: ; preds = %95
%273 = call i64 @strftime(i8* %7, i64 100, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.46, i64 0, i64 0), %struct.tm* %3)
br label %372
274: ; preds = %95
%275 = load i64, i64* %77
%276 = call i32 @min(i64 %275, i32 23)
%277 = call i64 @max(i32 0, i32 %276)
%278 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.49, i64 0, i64 0), i64 %277)
br label %372
279: ; preds = %95
%280 = load i64, i64* %77
%281 = call i32 @min(i64 %280, i32 23)
%282 = call i64 @max(i32 0, i32 %281)
%283 = trunc i64 %282 to i32
%284 = icmp eq i32 %283, 0
%285 = icmp sgt i32 %283, 12
%286 = shl i64 %282, 32
%287 = add i64 %286, -51539607552
%288 = select i1 %285, i64 %287, i64 %286
%289 = ashr exact i64 %288, 32
%290 = select i1 %284, i64 12, i64 %289
%291 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.49, i64 0, i64 0), i64 %290)
br label %372
292: ; preds = %95
%293 = load i64, i64* %76
%294 = call i32 @min(i64 %293, i32 31)
%295 = call i64 @max(i32 1, i32 %294)
%296 = load i32, i32* %73
%297 = sext i32 %296 to i64
%298 = call i32 @min(i64 %297, i32 11)
%299 = call i64 @max(i32 0, i32 %298)
%300 = getelementptr inbounds [12 x i8*], [12 x i8*]* @strftime.months_a, i64 0, i64 %299
%301 = load i8*, i8** %300
%302 = load i32, i32* %74
%303 = sext i32 %302 to i64
%304 = add nsw i64 %303, 1900
%305 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str.52, i64 0, i64 0), i64 %295, i8* %301, i64 %304)
%306 = load i8, i8* %85
%307 = call i32 @islower(i8 signext %306)
%308 = icmp eq i32 %307, 0
br i1 %308, label %312, label %309
309: ; preds = %292
%310 = load i8, i8* %85
%311 = call signext i8 @toupper(i8 signext %310)
store i8 %311, i8* %85
br label %312
312: ; preds = %292, %309
%313 = load i8, i8* %86
%314 = call i32 @islower(i8 signext %313)
%315 = icmp eq i32 %314, 0
br i1 %315, label %319, label %316
316: ; preds = %312
%317 = load i8, i8* %86
%318 = call signext i8 @toupper(i8 signext %317)
store i8 %318, i8* %86
br label %319
319: ; preds = %316, %312
%320 = load i8, i8* %87
%321 = call i32 @islower(i8 signext %320)
%322 = icmp eq i32 %321, 0
br i1 %322, label %372, label %323
323: ; preds = %319
%324 = load i8, i8* %87
%325 = call signext i8 @toupper(i8 signext %324)
store i8 %325, i8* %87
br label %372
326: ; preds = %95
%327 = load i32, i32* %74
%328 = sext i32 %327 to i64
%329 = add nsw i64 %328, 1900
%330 = sdiv i64 %329, 100
%331 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.53, i64 0, i64 0), i64 %330)
br label %372
332: ; preds = %95
%333 = call i32 @iso8601wknum(%struct.tm* %3)
%334 = sext i32 %333 to i64
%335 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.42, i64 0, i64 0), i64 %334)
br label %372
336: ; preds = %95
%337 = load i32, i32* %75
%338 = icmp eq i32 %337, 0
%339 = select i1 %338, i32 7, i32 %337
%340 = sext i32 %339 to i64
%341 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @.str.44, i64 0, i64 0), i64 %340)
br label %372
342: ; preds = %95, %95
%343 = call i32 @iso8601wknum(%struct.tm* %3)
%344 = load i32, i32* %73
%345 = icmp eq i32 %344, 11
%346 = icmp eq i32 %343, 1
%347 = select i1 %345, i1 %346, i1 false
br i1 %347, label %348, label %352
348: ; preds = %342
%349 = load i32, i32* %74
%350 = sext i32 %349 to i64
%351 = add nsw i64 %350, 1901
br label %362
352: ; preds = %342
%353 = icmp eq i32 %344, 0
%354 = icmp sgt i32 %343, 51
%355 = select i1 %353, i1 %354, i1 false
%356 = load i32, i32* %74
%357 = sext i32 %356 to i64
br i1 %355, label %358, label %360
358: ; preds = %352
%359 = add nsw i64 %357, 1899
br label %362
360: ; preds = %352
%361 = add nsw i64 %357, 1900
br label %362
362: ; preds = %358, %360, %348
%363 = phi i64 [ %351, %348 ], [ %359, %358 ], [ %361, %360 ]
%364 = load i8, i8* %97
%365 = icmp eq i8 %364, 71
br i1 %365, label %366, label %368
366: ; preds = %362
%367 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.47, i64 0, i64 0), i64 %363)
br label %372
368: ; preds = %362
%369 = srem i64 %363, 100
%370 = call i32 (i8*, i8*, i64, ...) @sprintf(i8* %7, i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.53, i64 0, i64 0), i64 %369)
br label %372
371: ; preds = %95
store i8 37, i8* %7
store i8 %98, i8* %78
store i8 0, i8* %84
br label %372
372: ; preds = %319, %323, %366, %368, %201, %203, %138, %140, %128, %130, %118, %120, %108, %110, %371, %336, %332, %326, %279, %274, %272, %270, %268, %263, %261, %260, %259, %256, %249, %237, %232, %230, %228, %224, %216, %212, %205, %188, %179, %174, %161, %154, %147, %145
%373 = call i32 @strlen(i8* %7)
%374 = icmp eq i32 %373, 0
br i1 %374, label %381, label %375
375: ; preds = %372
%376 = sext i32 %373 to i64
%377 = getelementptr inbounds i8, i8* %90, i64 %376
%378 = icmp ult i8* %377, %67
br i1 %378, label %379, label %400
379: ; preds = %375
%380 = call i32 @strcpy(i8* %90, i8* %7)
br label %381
381: ; preds = %372, %379, %103, %93
%382 = phi i8* [ %91, %93 ], [ %97, %379 ], [ %97, %372 ], [ %97, %103 ]
%383 = phi i8* [ %94, %93 ], [ %377, %379 ], [ %90, %372 ], [ %104, %103 ]
%384 = getelementptr inbounds i8, i8* %382, i64 1
%385 = load i8, i8* %384
%386 = icmp ne i8 %385, 0
%387 = icmp ult i8* %383, %67
%388 = select i1 %386, i1 %387, i1 false
br i1 %388, label %88, label %389
389: ; preds = %381, %66, %101
%390 = phi i8* [ %97, %101 ], [ %2, %66 ], [ %384, %381 ]
%391 = phi i8* [ %102, %101 ], [ %0, %66 ], [ %383, %381 ]
%392 = icmp ult i8* %391, %6
br i1 %392, label %393, label %400
393: ; preds = %389
%394 = load i8, i8* %390
%395 = icmp eq i8 %394, 0
br i1 %395, label %396, label %400
396: ; preds = %393
store i8 0, i8* %391
%397 = ptrtoint i8* %391 to i64
%398 = ptrtoint i8* %0 to i64
%399 = sub i64 %397, %398
br label %400
400: ; preds = %375, %389, %393, %18, %4, %396
%401 = phi i64 [ %399, %396 ], [ 0, %4 ], [ 0, %18 ], [ 0, %393 ], [ 0, %389 ], [ 0, %375 ]
ret i64 %401
}