// File: /workspace/github_cpp_makefile_star2_O2/WeihuaZhu[P]hpc_prog2/./gtest/gtest-all.cc
// Function: testing::internal::ColoredPrintf(testing::internal::GTestColor, char const*, ...)
void ColoredPrintf(GTestColor color, const char* fmt, ...) {
  va_list args;
  va_start(args, fmt);

#if GTEST_OS_WINDOWS_MOBILE || GTEST_OS_SYMBIAN || GTEST_OS_ZOS || GTEST_OS_IOS
  const bool use_color = false;
#else
  static const bool in_color_mode =
      ShouldUseColor(posix::IsATTY(posix::FileNo(stdout)) != 0);
  const bool use_color = in_color_mode && (color != COLOR_DEFAULT);
#endif  // GTEST_OS_WINDOWS_MOBILE || GTEST_OS_SYMBIAN || GTEST_OS_ZOS
  // The '!= 0' comparison is necessary to satisfy MSVC 7.1.

  if (!use_color) {
    vprintf(fmt, args);
    va_end(args);
    return;
  }

#if GTEST_OS_WINDOWS && !GTEST_OS_WINDOWS_MOBILE
  const HANDLE stdout_handle = GetStdHandle(STD_OUTPUT_HANDLE);

  // Gets the current text color.
  CONSOLE_SCREEN_BUFFER_INFO buffer_info;
  GetConsoleScreenBufferInfo(stdout_handle, &buffer_info);
  const WORD old_color_attrs = buffer_info.wAttributes;

  // We need to flush the stream buffers into the console before each
  // SetConsoleTextAttribute call lest it affect the text that is already
  // printed but has not yet reached the console.
  fflush(stdout);
  SetConsoleTextAttribute(stdout_handle,
                          GetColorAttribute(color) | FOREGROUND_INTENSITY);
  vprintf(fmt, args);

  fflush(stdout);
  // Restores the text color.
  SetConsoleTextAttribute(stdout_handle, old_color_attrs);
#else
  printf("\033[0;3%sm", GetAnsiColorCode(color));
  vprintf(fmt, args);
  printf("\033[m");  // Resets the terminal to default.
#endif  // GTEST_OS_WINDOWS && !GTEST_OS_WINDOWS_MOBILE
  va_end(args);
}

// Assembly:
pushq %rbp
pushq %rbx
subq $0xd8, %rsp
movq %rsi, %rbx
movl %edi, %ebp
leaq 0x20(%rsp), %rsi
movq %rdx, 0x10(%rsi)
movq %rcx, 0x18(%rsi)
movq %r8, 0x20(%rsi)
movq %r9, 0x28(%rsi)
testb %al, %al
je 0xc739
movaps %xmm0, 0x50(%rsp)
movaps %xmm1, 0x60(%rsp)
movaps %xmm2, 0x70(%rsp)
movaps %xmm3, 0x80(%rsp)
movaps %xmm4, 0x90(%rsp)
movaps %xmm5, 0xa0(%rsp)
movaps %xmm6, 0xb0(%rsp)
movaps %xmm7, 0xc0(%rsp)
movq %rsi, 0x10(%rsp)
leaq 0xf0(%rsp), %rax
movq %rax, 0x8(%rsp)
movabsq $0x3000000010, %rax     # imm = 0x3000000010
movq %rax, (%rsp)
movb 0x21f19(%rip), %al      # 0x2e678
testb %al, %al
je 0xc7c6
testl %ebp, %ebp
je 0xc786
cmpb $0x0, 0x21f02(%rip)     # 0x2e670
je 0xc786
cmpl $0x3, %ebp
ja 0xc793
movslq %ebp, %rax
leaq 0x21371(%rip), %rcx     # 0x2daf0
movq -0x8(%rcx,%rax,8), %rsi
jmp 0xc795
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x6470
jmp 0xc7bc
xorl %esi, %esi
leaq 0x121af(%rip), %rdi     # 0x1e94b
xorl %eax, %eax
callq 0x6070
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x6470
leaq 0x1219f(%rip), %rdi     # 0x1e954
xorl %eax, %eax
callq 0x6070
addq $0xd8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x21eab(%rip), %rdi     # 0x2e678
callq 0x6950
testl %eax, %eax
je 0xc763
movq 0x217ab(%rip), %rax     # 0x2df88
movq (%rax), %rdi
callq 0x64a0
movl %eax, %edi
callq 0x68f0
xorl %edi, %edi
testl %eax, %eax
setne %dil
callq 0xc5c9
movb %al, 0x21e71(%rip)      # 0x2e670
leaq 0x21e72(%rip), %rdi     # 0x2e678
callq 0x6290
jmp 0xc763