// File: /workspace/github_cpp_makefile_star2_O3/travisdowns[P]avx-turbo/cpuid.cpp
// Function: get_brand_string[abi:cxx11]()
std::string get_brand_string() {
    auto check = cpuid(0x80000000);
    if (check.eax < 0x80000004) {
        return std::string("unkown (eax =") + std::to_string(check.eax) +")";
    }
    std::string ret;
    for (uint32_t eax : {0x80000002, 0x80000003, 0x80000004}) {
        char buf[17];
        auto fourchars = cpuid(eax);
        memcpy(buf +  0, &fourchars.eax, 4);
        memcpy(buf +  4, &fourchars.ebx, 4);
        memcpy(buf +  8, &fourchars.ecx, 4);
        memcpy(buf + 12, &fourchars.edx, 4);
        buf[16] = '\0';
        ret += buf;
    }
    return ret;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rdi, %r14
movl $0x80000000, %eax       # imm = 0x80000000
xorl %ecx, %ecx
cpuid
cmpl $0x80000003, %eax       # imm = 0x80000003
ja 0x15d92
movl %eax, %ebx
leaq 0x30(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0xa160(%rip), %rsi      # 0x1fe8a
leaq 0xa166(%rip), %rdx      # 0x1fe97
leaq 0x20(%rsp), %rdi
callq 0xdf70
movl $0x1, %eax
cmpl $0xa, %ebx
jb 0x15e01
movl $0x4, %eax
movl $0xd1b71759, %ecx       # imm = 0xD1B71759
movl %ebx, %edx
cmpl $0x63, %edx
jbe 0x15dfa
cmpl $0x3e7, %edx            # imm = 0x3E7
jbe 0x15dff
cmpl $0x2710, %edx           # imm = 0x2710
jb 0x15e01
movl %edx, %esi
imulq %rcx, %rsi
shrq $0x2d, %rsi
addl $0x4, %eax
cmpl $0x1869f, %edx          # imm = 0x1869F
movl %esi, %edx
ja 0x15d55
addl $-0x3, %eax
jmp 0x15e01
leaq 0x10(%r14), %r12
movq %r12, (%r14)
movq $0x0, 0x8(%r14)
movb $0x0, 0x10(%r14)
movabsq $-0x7ffffffc7ffffffe, %rax # imm = 0x8000000380000002
movq %rax, 0x20(%rsp)
movl $0x80000004, 0x28(%rsp) # imm = 0x80000004
xorl %r13d, %r13d
movq %rsp, %r15
movl 0x20(%rsp,%r13), %eax
xorl %ecx, %ecx
cpuid
movl %eax, (%rsp)
movl %ebx, 0x4(%rsp)
movl %ecx, 0x8(%rsp)
movl %edx, 0xc(%rsp)
movb $0x0, 0x10(%rsp)
movq %r14, %rdi
movq %r15, %rsi
callq 0x6630
addq $0x4, %r13
cmpq $0xc, %r13
jne 0x15dc3
jmp 0x15f48
addl $-0x2, %eax
jmp 0x15e01
decl %eax
movl %eax, %esi
leaq 0x50(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x40(%rsp), %rdi
xorl %edx, %edx
callq 0x63b0
movq 0x40(%rsp), %rdi
movl 0x48(%rsp), %esi
movl %ebx, %edx
callq 0x1413c
movq 0x20(%rsp), %rcx
movq 0x28(%rsp), %r8
movq 0x48(%rsp), %rdx
leaq (%rdx,%r8), %rax
movl $0xf, %edi
cmpq %r15, %rcx
je 0x15e4b
movq 0x30(%rsp), %rdi
movq 0x40(%rsp), %rsi
cmpq %rdi, %rax
jbe 0x15e69
movl $0xf, %edi
cmpq %r12, %rsi
je 0x15e64
movq 0x50(%rsp), %rdi
cmpq %rdi, %rax
jbe 0x15e75
leaq 0x20(%rsp), %rdi
callq 0x60c0
jmp 0x15e83
leaq 0x40(%rsp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x6380
leaq 0x10(%rsp), %rdx
movq %rdx, -0x10(%rdx)
movq (%rax), %rsi
leaq 0x10(%rax), %rcx
cmpq %rcx, %rsi
je 0x15ea6
movq %rsi, (%rsp)
movq (%rcx), %rdx
movq %rdx, 0x10(%rsp)
jmp 0x15eac
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq %rax, %rdx
addq $0x8, %rdx
movq 0x8(%rax), %rsi
movq %rsi, 0x8(%rsp)
movq %rcx, (%rax)
movq $0x0, (%rdx)
movb $0x0, (%rcx)
leaq 0x9549(%rip), %rsi      # 0x1f419
movq %rsp, %rdi
callq 0x6630
leaq 0x10(%r14), %rdx
movq %rdx, (%r14)
movq (%rax), %rsi
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rsi
je 0x15efa
movq %rsi, (%r14)
movq (%rcx), %rdx
movq %rdx, 0x10(%r14)
jmp 0x15f00
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq 0x8(%rax), %rdx
movq %rdx, 0x8(%r14)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x15f2a
callq 0x6320
movq 0x40(%rsp), %rdi
cmpq %r12, %rdi
je 0x15f39
callq 0x6320
movq 0x20(%rsp), %rdi
cmpq %r15, %rdi
je 0x15f48
callq 0x6320
movq %r14, %rax
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x15f74
callq 0x6320
jmp 0x15f74
movq %rax, %rbx
movq 0x40(%rsp), %rdi
cmpq %r12, %rdi
je 0x15f88
callq 0x6320
jmp 0x15f88
movq %rax, %rbx
movq 0x20(%rsp), %rdi
cmpq %r15, %rdi
jne 0x15fa4
jmp 0x15fa9
movq %rax, %rbx
jmp 0x15fa9
movq %rax, %rbx
movq (%r14), %rdi
cmpq %r12, %rdi
je 0x15fa9
callq 0x6320
movq %rbx, %rdi
callq 0x65f0