// File: /workspace/github_cpp_makefile_star2_O1/iZhangHui[P]CppPrimer/CH10_GenericAlgorithms/examples/sortSI.cc
// Function: main
int main() 
{
    Sales_item trans;
    vector<Sales_item> file;

    while (std::cin >> trans)  // read the transations
        file.push_back(trans);

	for (auto i : file)        // print what was read
		cout << i << endl;
	cout << "\n\n";

	sort(file.begin(), file.end(), compareIsbn); // sort into ISBN order
	for (auto i : file)        // print in ISBN order
		cout << i << endl;

	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
leaq -0x90(%rbp), %r12
movq %r12, -0x10(%r12)
xorl %eax, %eax
movq %rax, -0x8(%r12)
movb $0x0, (%r12)
movl $0x0, 0x10(%r12)
movq %rax, 0x18(%r12)
leaq -0x40(%rbp), %rbx
movq %rax, 0x10(%rbx)
xorps %xmm0, %xmm0
movaps %xmm0, (%rbx)
movq 0x39d9(%rip), %r14      # 0x5fe0
leaq -0xa0(%rbp), %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x23c3
movq (%r14), %rax
movq -0x18(%rax), %rax
testb $0x5, 0x20(%r14,%rax)
jne 0x2635
movq %rbx, %rdi
movq %r15, %rsi
callq 0x285c
jmp 0x260e
movq -0x40(%rbp), %r15
movq -0x38(%rbp), %r12
cmpq %r12, %r15
je 0x26c1
leaq -0x60(%rbp), %r13
leaq -0x70(%rbp), %rbx
movq 0x397f(%rip), %r14      # 0x5fd0
movq %r13, -0x70(%rbp)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x29f0
movups 0x20(%r15), %xmm0
movups %xmm0, 0x10(%r13)
movq %r14, %rdi
movq %rbx, %rsi
callq 0x2491
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x20f0
movsbl %al, %esi
movq %r14, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20a0
movq -0x70(%rbp), %rdi
cmpq %r13, %rdi
je 0x26b8
movq -0x60(%rbp), %rsi
incq %rsi
callq 0x2110
addq $0x30, %r15
cmpq %r12, %r15
jne 0x2651
movq 0x3908(%rip), %rbx      # 0x5fd0
leaq 0x1937(%rip), %rsi      # 0x4006
movl $0x2, %edx
movq %rbx, %rdi
callq 0x2130
movq -0x40(%rbp), %r14
movq -0x38(%rbp), %r15
cmpq %r15, %r14
je 0x2732
movq %r15, %rax
subq %r14, %rax
sarq $0x4, %rax
movabsq $-0x5555555555555555, %rcx # imm = 0xAAAAAAAAAAAAAAAB
imulq %rax, %rcx
bsrq %rcx, %rdx
xorl $0x3f, %edx
addl %edx, %edx
xorq $0x7e, %rdx
leaq 0x1ab(%rip), %rcx       # 0x28c0
movq %r14, %rdi
movq %r15, %rsi
callq 0x2d4a
leaq 0x199(%rip), %rdx       # 0x28c0
movq %r14, %rdi
movq %r15, %rsi
callq 0x2e49
movq -0x40(%rbp), %r15
movq -0x38(%rbp), %r13
cmpq %r13, %r15
je 0x27b8
leaq -0x60(%rbp), %r12
leaq -0x70(%rbp), %r14
movq %r12, -0x70(%rbp)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
movq %r14, %rdi
callq 0x29f0
movups 0x20(%r15), %xmm0
movups %xmm0, 0x10(%r12)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2491
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x20f0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20a0
movq -0x70(%rbp), %rdi
cmpq %r12, %rdi
je 0x27af
movq -0x60(%rbp), %rsi
incq %rsi
callq 0x2110
addq $0x30, %r15
cmpq %r13, %r15
jne 0x2747
leaq -0x40(%rbp), %rdi
callq 0x2986
movq -0xa0(%rbp), %rdi
leaq -0x90(%rbp), %rax
cmpq %rax, %rdi
je 0x27e3
movq -0x90(%rbp), %rsi
incq %rsi
callq 0x2110
xorl %eax, %eax
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x27f8
jmp 0x27f8
movq %rax, %rbx
jmp 0x2828
movq %rax, %rbx
jmp 0x282f
movq %rax, %rbx
movq -0x70(%rbp), %rdi
cmpq %r12, %rdi
jne 0x281c
jmp 0x2828
movq %rax, %rbx
movq -0x70(%rbp), %rdi
cmpq %r13, %rdi
je 0x2828
movq -0x60(%rbp), %rsi
incq %rsi
callq 0x2110
leaq -0x90(%rbp), %r12
leaq -0x40(%rbp), %rdi
callq 0x2986
movq -0xa0(%rbp), %rdi
cmpq %r12, %rdi
je 0x2853
movq -0x90(%rbp), %rsi
incq %rsi
callq 0x2110
movq %rbx, %rdi
callq 0x21b0
nop