// File: /workspace/github_c_makefile_star2_O3/Tarsnap[P]kivaloo/bench/bulk_extract/main.c
// Function: main
int
main(int argc, char * argv[])
{
	struct sock_addr ** sas;
	int s;
	struct wire_requestqueue * Q;

	WARNP_INIT;

	/* Check number of arguments. */
	if (argc != 2) {
		fprintf(stderr, "usage: bulk_insert %s\n", "<socketname>");
		exit(1);
	}

	/* Resolve the socket address and connect. */
	if ((sas = sock_resolve(argv[1])) == NULL) {
		warnp("Error resolving socket address: %s", argv[1]);
		exit(1);
	}
	if (sas[0] == NULL) {
		warn0("No addresses found for %s", argv[1]);
		exit(1);
	}
	if ((s = sock_connect(sas)) == -1)
		exit(1);

	/* Create a request queue. */
	if ((Q = wire_requestqueue_init(s)) == NULL) {
		warnp("Cannot create packet write queue");
		exit(1);
	}

	/* Start RANGE request(s). */
	if (bulkextract(Q))
		exit(1);

	/* Free the request queue. */
	wire_requestqueue_destroy(Q);
	wire_requestqueue_free(Q);

	/* Free socket addresses. */
	sock_addr_freelist(sas);

	/* Success! */
	exit(0);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rsi, %r14
movl %edi, %ebx
movq (%rsi), %rdi
testq %rdi, %rdi
je 0x2567
callq 0x4eac
cmpl $0x2, %ebx
jne 0x2598
movq 0x8(%r14), %rdi
callq 0x3ea8
testq %rax, %rax
jne 0x25b9
callq 0x2090
cmpl $0x0, (%rax)
movq 0x8(%r14), %rsi
jne 0x25e1
leaq 0x7a99(%rip), %rdi      # 0xa028
xorl %eax, %eax
callq 0x504b
jmp 0x2607
movq 0xda59(%rip), %rax      # 0xfff8
movq (%rax), %rdi
leaq 0x7a5b(%rip), %rsi      # 0xa004
leaq 0x7a6b(%rip), %rdx      # 0xa01b
xorl %eax, %eax
callq 0x21d0
jmp 0x2607
movq %rax, %rbx
cmpq $0x0, (%rax)
jne 0x25fa
movq 0x8(%r14), %rsi
leaq 0x7a7e(%rip), %rdi      # 0xa04b
xorl %eax, %eax
callq 0x504b
callq 0x2090
movl $0x0, (%rax)
jmp 0x2607
movq %rax, %rbx
leaq 0x7a3d(%rip), %rdi      # 0xa028
xorl %eax, %eax
callq 0x4f2c
movl $0x0, (%rbx)
jmp 0x2607
movq %rbx, %rdi
callq 0x47c0
cmpl $-0x1, %eax
jne 0x2611
movl $0x1, %edi
callq 0x22b0
movl %eax, %edi
callq 0x6ac4
testq %rax, %rax
jne 0x2637
callq 0x2090
cmpl $0x0, (%rax)
jne 0x2694
leaq 0x7a37(%rip), %rdi      # 0xa065
xorl %eax, %eax
callq 0x504b
jmp 0x2607
movq %rax, %r14
movq %rax, (%rsp)
movq $0x0, 0x10(%rsp)
xorl %edi, %edi
xorl %esi, %esi
callq 0x54c8
movq %rax, 0x8(%rsp)
testq %rax, %rax
je 0x2607
movq %rax, %r15
movl $0x32, %edi
movl $0xa, %esi
callq 0x5170
movq %rax, 0x18(%rsp)
testq %rax, %rax
jne 0x26aa
leaq 0x7a09(%rip), %rdi      # 0xa086
xorl %eax, %eax
callq 0x504b
callq 0x2090
movl $0x0, (%rax)
jmp 0x2772
movq %rax, %rbx
leaq 0x79c7(%rip), %rdi      # 0xa065
xorl %eax, %eax
callq 0x4f2c
jmp 0x25f2
leaq 0xce(%rip), %rcx        # 0x277f
leaq 0x118(%rip), %r8        # 0x27d0
movq %rsp, %r9
movq %r14, %rdi
movq %r15, %rsi
movq %r15, %rdx
callq 0x66d2
testl %eax, %eax
jne 0x2763
leaq 0x14(%rsp), %r15
movq %r15, %rdi
callq 0x2ac1
orl -0x4(%r15), %eax
je 0x26fe
callq 0x2090
cmpl $0x0, (%rax)
jne 0x274c
leaq 0x799c(%rip), %rdi      # 0xa091
xorl %eax, %eax
callq 0x504b
jmp 0x2763
movq 0x18(%rsp), %rdi
callq 0x5435
leaq 0x7997(%rip), %rdi      # 0xa0a6
movq %rax, %rsi
xorl %eax, %eax
callq 0x2130
movq 0x18(%rsp), %rdi
callq 0x54a0
movq 0x8(%rsp), %rdi
callq 0x2040
movq %r14, %rdi
callq 0x71b5
movq %r14, %rdi
callq 0x71c9
movq %rbx, %rdi
callq 0x45ba
xorl %edi, %edi
callq 0x22b0
movq %rax, %rbx
leaq 0x793b(%rip), %rdi      # 0xa091
xorl %eax, %eax
callq 0x4f2c
movl $0x0, (%rbx)
movq 0x18(%rsp), %rdi
callq 0x54a0
movq 0x8(%rsp), %r15
movq %r15, %rdi
callq 0x2040
jmp 0x2607