// File: halfflat[P]tinyopt/test/googletest/googletest/src/gtest.cc
// Function: testing::internal::FormatEpochTimeInMillisAsIso8601[abi:cxx11](long)
std::string FormatEpochTimeInMillisAsIso8601(TimeInMillis ms) {
  struct tm time_struct;
  if (!PortableLocaltime(static_cast<time_t>(ms / 1000), &time_struct))
    return "";
  // YYYY-MM-DDThh:mm:ss.sss
  return StreamableToString(time_struct.tm_year + 1900) + "-" +
         String::FormatIntWidth2(time_struct.tm_mon + 1) + "-" +
         String::FormatIntWidth2(time_struct.tm_mday) + "T" +
         String::FormatIntWidth2(time_struct.tm_hour) + ":" +
         String::FormatIntWidth2(time_struct.tm_min) + ":" +
         String::FormatIntWidth2(time_struct.tm_sec) + "." +
         String::FormatIntWidthN(static_cast<int>(ms % 1000), 3);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x2d0, %rsp            # imm = 0x2D0
movq %rdi, -0x2b8(%rbp)
movq %rdi, %rax
movq %rax, -0x2b0(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movl $0x3e8, %ecx            # imm = 0x3E8
cqto
idivq %rcx
movq %rax, %rdi
leaq -0x48(%rbp), %rsi
callq 0x8fcb0
testb $0x1, %al
jne 0x8f7b6
leaq -0x49(%rbp), %rdi
movq %rdi, -0x2c0(%rbp)
callq 0x10e10
movq -0x2b8(%rbp), %rdi
movq -0x2c0(%rbp), %rdx
leaq 0x3bb80(%rip), %rsi     # 0xcb307
callq 0x1d070
jmp 0x8f78e
leaq -0x49(%rbp), %rdi
callq 0x10810
jmp 0x8fc8f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0x49(%rbp), %rdi
callq 0x10810
jmp 0x8fc9f
movl -0x34(%rbp), %eax
addl $0x76c, %eax            # imm = 0x76C
movl %eax, -0x1e4(%rbp)
leaq -0x1e0(%rbp), %rdi
movq %rdi, -0x2c8(%rbp)
leaq -0x1e4(%rbp), %rsi
callq 0xa2c60
movq -0x2c8(%rbp), %rsi
leaq 0x3fcad(%rip), %rdx     # 0xcf499
leaq -0x1c0(%rbp), %rdi
callq 0xa2b40
jmp 0x8f7fa
movl -0x38(%rbp), %esi
incl %esi
leaq -0x208(%rbp), %rdi
callq 0x881a0
jmp 0x8f80d
leaq -0x1a0(%rbp), %rdi
leaq -0x1c0(%rbp), %rsi
leaq -0x208(%rbp), %rdx
callq 0xa2b90
jmp 0x8f829
leaq 0x3fc69(%rip), %rdx     # 0xcf499
leaq -0x180(%rbp), %rdi
leaq -0x1a0(%rbp), %rsi
callq 0xa2b40
jmp 0x8f845
movl -0x3c(%rbp), %esi
leaq -0x228(%rbp), %rdi
callq 0x881a0
jmp 0x8f856
leaq -0x160(%rbp), %rdi
leaq -0x180(%rbp), %rsi
leaq -0x228(%rbp), %rdx
callq 0xa2b90
jmp 0x8f872
leaq 0x4009c(%rip), %rdx     # 0xcf915
leaq -0x140(%rbp), %rdi
leaq -0x160(%rbp), %rsi
callq 0xa2b40
jmp 0x8f88e
movl -0x40(%rbp), %esi
leaq -0x248(%rbp), %rdi
callq 0x881a0
jmp 0x8f89f
leaq -0x120(%rbp), %rdi
leaq -0x140(%rbp), %rsi
leaq -0x248(%rbp), %rdx
callq 0xa2b90
jmp 0x8f8bb
leaq 0x3a6c5(%rip), %rdx     # 0xc9f87
leaq -0x100(%rbp), %rdi
leaq -0x120(%rbp), %rsi
callq 0xa2b40
jmp 0x8f8d7
movl -0x44(%rbp), %esi
leaq -0x268(%rbp), %rdi
callq 0x881a0
jmp 0x8f8e8
leaq -0xe0(%rbp), %rdi
leaq -0x100(%rbp), %rsi
leaq -0x268(%rbp), %rdx
callq 0xa2b90
jmp 0x8f904
leaq 0x3a67c(%rip), %rdx     # 0xc9f87
leaq -0xc0(%rbp), %rdi
leaq -0xe0(%rbp), %rsi
callq 0xa2b40
jmp 0x8f920
movl -0x48(%rbp), %esi
leaq -0x288(%rbp), %rdi
callq 0x881a0
jmp 0x8f931
leaq -0xa0(%rbp), %rdi
leaq -0xc0(%rbp), %rsi
leaq -0x288(%rbp), %rdx
callq 0xa2b90
jmp 0x8f94d
leaq 0x3a12f(%rip), %rdx     # 0xc9a83
leaq -0x80(%rbp), %rdi
leaq -0xa0(%rbp), %rsi
callq 0xa2b40
jmp 0x8f966
movq -0x10(%rbp), %rcx
movabsq $0x20c49ba5e353f7cf, %rdx # imm = 0x20C49BA5E353F7CF
movq %rcx, %rax
imulq %rdx
movq %rdx, %rax
movq %rax, %rdx
shrq $0x3f, %rdx
shrq $0x7, %rax
addl %edx, %eax
imull $0x3e8, %eax, %eax      # imm = 0x3E8
movl %ecx, %esi
subl %eax, %esi
leaq -0x2a8(%rbp), %rdi
movl $0x3, %edx
callq 0x881d0
jmp 0x8f9a7
movq -0x2b8(%rbp), %rdi
leaq -0x80(%rbp), %rsi
leaq -0x2a8(%rbp), %rdx
callq 0xa2b90
jmp 0x8f9c0
leaq -0x2a8(%rbp), %rdi
callq 0x10fc8
leaq -0x80(%rbp), %rdi
callq 0x10fc8
leaq -0xa0(%rbp), %rdi
callq 0x10fc8
leaq -0x288(%rbp), %rdi
callq 0x10fc8
leaq -0xc0(%rbp), %rdi
callq 0x10fc8
leaq -0xe0(%rbp), %rdi
callq 0x10fc8
leaq -0x268(%rbp), %rdi
callq 0x10fc8
leaq -0x100(%rbp), %rdi
callq 0x10fc8
leaq -0x120(%rbp), %rdi
callq 0x10fc8
leaq -0x248(%rbp), %rdi
callq 0x10fc8
leaq -0x140(%rbp), %rdi
callq 0x10fc8
leaq -0x160(%rbp), %rdi
callq 0x10fc8
leaq -0x228(%rbp), %rdi
callq 0x10fc8
leaq -0x180(%rbp), %rdi
callq 0x10fc8
leaq -0x1a0(%rbp), %rdi
callq 0x10fc8
leaq -0x208(%rbp), %rdi
callq 0x10fc8
leaq -0x1c0(%rbp), %rdi
callq 0x10fc8
leaq -0x1e0(%rbp), %rdi
callq 0x10fc8
jmp 0x8fc8f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fc81
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fc75
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fc69
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fc5d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fc51
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fc45
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fc39
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fc2d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fc21
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fc15
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fc09
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fbfd
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fbf1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fbe5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fbd9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fbcd
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
jmp 0x8fbc4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x58(%rbp)
movl %eax, -0x5c(%rbp)
leaq -0x2a8(%rbp), %rdi
callq 0x10fc8
leaq -0x80(%rbp), %rdi
callq 0x10fc8
leaq -0xa0(%rbp), %rdi
callq 0x10fc8
leaq -0x288(%rbp), %rdi
callq 0x10fc8
leaq -0xc0(%rbp), %rdi
callq 0x10fc8
leaq -0xe0(%rbp), %rdi
callq 0x10fc8
leaq -0x268(%rbp), %rdi
callq 0x10fc8
leaq -0x100(%rbp), %rdi
callq 0x10fc8
leaq -0x120(%rbp), %rdi
callq 0x10fc8
leaq -0x248(%rbp), %rdi
callq 0x10fc8
leaq -0x140(%rbp), %rdi
callq 0x10fc8
leaq -0x160(%rbp), %rdi
callq 0x10fc8
leaq -0x228(%rbp), %rdi
callq 0x10fc8
leaq -0x180(%rbp), %rdi
callq 0x10fc8
leaq -0x1a0(%rbp), %rdi
callq 0x10fc8
leaq -0x208(%rbp), %rdi
callq 0x10fc8
leaq -0x1c0(%rbp), %rdi
callq 0x10fc8
leaq -0x1e0(%rbp), %rdi
callq 0x10fc8
jmp 0x8fc9f
movq -0x2b0(%rbp), %rax
addq $0x2d0, %rsp            # imm = 0x2D0
popq %rbp
retq
movq -0x58(%rbp), %rdi
callq 0x10e00
nopl (%rax,%rax)