// File: /workspace/github_c_makefile_star2_O0/Tarsnap[P]spiped/tests/pushbits/main.c
// Function: main
int
main(int argc, char ** argv)
{
	const char * ch;
	const char * filename_in = NULL;
	const char * filename_out = NULL;
	int desired_test;

	WARNP_INIT;

	/* Parse the command line. */
	while ((ch = GETOPT(argc, argv)) != NULL) {
		GETOPT_SWITCH(ch) {
		GETOPT_OPTARG("-i"):
			filename_in = optarg;
			break;
		GETOPT_OPTARG("-o"):
			filename_out = optarg;
			break;
		GETOPT_MISSING_ARG:
			warn0("Missing argument to %s", ch);
			usage();
		GETOPT_DEFAULT:
			warn0("illegal option -- %s", ch);
			usage();
		}
	}
	argc -= optind;
	argv += optind;

	/* We should have processed all the arguments except for one. */
	if (argc != 1)
		usage();
	if (PARSENUM(&desired_test, argv[0], 1, 5)) {
		warnp("parsenum");
		goto err0;
	}

	/* Run the desired test. */
	switch (desired_test) {
	case 1:
		if ((filename_in == NULL) || (filename_out == NULL))
			usage();
		if (basic_copy(filename_in, filename_out))
			goto err0;
		break;
	case 2:
		if (echo_stdin_stdout())
			goto err0;
		break;
	case 3:
		if (chain_one())
			goto err0;
		break;
	case 4:
		if (chain_two())
			goto err0;
		break;
	case 5:
		if (start_stop())
			goto err0;
		break;
	default:
		warn0("invalid test number");
		goto err0;
	}

	/* Success! */
	exit(0);

err0:
	/* Failure! */
	exit(1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq $0x0, -0x20(%rbp)
movq $0x0, -0x28(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x0, (%rax)
je 0x244f
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x4d80
jmp 0x2451
jmp 0x2453
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
callq 0x3f50
movq %rax, -0x18(%rbp)
cmpq $0x0, %rax
je 0x26aa
movq $0x1ab, -0x38(%rbp)     # imm = 0x1AB
movq -0x38(%rbp), %rax
decq %rax
movq %rax, -0x40(%rbp)
movl $0x0, -0x44(%rbp)
leaq 0x4(%rip), %rax         # 0x2492
movq %rax, -0x50(%rbp)
leaq 0x5d2f(%rip), %rax      # 0x81c8
cmpl $0x0, (%rax)
je 0x24b4
movq -0x18(%rbp), %rdi
callq 0x4610
movq -0x38(%rbp), %rcx
addq %rcx, %rax
movq %rax, -0x58(%rbp)
jmp 0x24c7
movq -0x40(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x40(%rbp)
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rax
addq $-0x1ac, %rax           # imm = 0xFE54
movq %rax, -0x60(%rbp)
subq $0x9, %rax
ja 0x2646
movq -0x60(%rbp), %rax
leaq 0x3b42(%rip), %rcx      # 0x602c
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq 0x5cce(%rip), %rax      # 0x81c8
cmpl $0x0, (%rax)
je 0x252f
leaq 0x5cba(%rip), %rax      # 0x81c0
cmpq $0x0, (%rax)
je 0x250e
jmp 0x252d
leaq 0x3b3f(%rip), %rdi      # 0x6054
leaq 0x3b47(%rip), %rsi      # 0x6063
movl $0x1ac, %edx            # imm = 0x1AC
leaq 0x3b42(%rip), %rcx      # 0x606a
callq 0x2130
jmp 0x2559
movq -0x38(%rbp), %rax
movl $0x1ac, %esi            # imm = 0x1AC
subq %rax, %rsi
leaq 0x3b3f(%rip), %rdi      # 0x6081
movl $0x1, %edx
callq 0x4760
movq -0x50(%rbp), %rax
movq %rax, -0x68(%rbp)
jmp 0x28a0
leaq 0x5c60(%rip), %rax      # 0x81c0
movq (%rax), %rax
movq %rax, -0x20(%rbp)
jmp 0x26a5
leaq 0x5c55(%rip), %rax      # 0x81c8
cmpl $0x0, (%rax)
je 0x25a8
leaq 0x5c41(%rip), %rax      # 0x81c0
cmpq $0x0, (%rax)
je 0x2587
jmp 0x25a6
leaq 0x3ac6(%rip), %rdi      # 0x6054
leaq 0x3ace(%rip), %rsi      # 0x6063
movl $0x1af, %edx            # imm = 0x1AF
leaq 0x3ac9(%rip), %rcx      # 0x606a
callq 0x2130
jmp 0x25d2
movq -0x38(%rbp), %rax
movl $0x1af, %esi            # imm = 0x1AF
subq %rax, %rsi
leaq 0x3ac9(%rip), %rdi      # 0x6084
movl $0x1, %edx
callq 0x4760
movq -0x50(%rbp), %rax
movq %rax, -0x68(%rbp)
jmp 0x28a0
leaq 0x5be7(%rip), %rax      # 0x81c0
movq (%rax), %rax
movq %rax, -0x28(%rbp)
jmp 0x26a5
leaq 0x5bdc(%rip), %rax      # 0x81c8
cmpl $0x0, (%rax)
je 0x25f3
jmp 0x2611
movq -0x38(%rbp), %rax
movl $0x1b2, %edi            # imm = 0x1B2
subq %rax, %rdi
callq 0x49f0
movq -0x50(%rbp), %rax
movq %rax, -0x68(%rbp)
jmp 0x28a0
jmp 0x2613
movq -0x18(%rbp), %rsi
leaq 0x3a69(%rip), %rdi      # 0x6087
movb $0x0, %al
callq 0x5090
callq 0x2080
movl $0x0, (%rax)
callq 0x28b0
jmp 0x2681
leaq 0x5b8a(%rip), %rax      # 0x81c8
movl $0x1, (%rax)
jmp 0x26a5
leaq 0x5b7b(%rip), %rax      # 0x81c8
cmpl $0x0, (%rax)
je 0x2654
jmp 0x2681
movl -0x44(%rbp), %eax
cmpl $0x0, %eax
jne 0x2674
movq -0x38(%rbp), %rax
movl $0x1b5, %edi            # imm = 0x1B5
subq %rax, %rdi
callq 0x4ab0
movl $0x1, -0x44(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x68(%rbp)
jmp 0x28a0
jmp 0x2683
movq -0x18(%rbp), %rsi
leaq 0x3a10(%rip), %rdi      # 0x609e
movb $0x0, %al
callq 0x5090
callq 0x2080
movl $0x0, (%rax)
callq 0x28b0
jmp 0x2453
leaq 0x5ae7(%rip), %rax      # 0x8198
movl (%rax), %ecx
movl -0x8(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x8(%rbp)
leaq 0x5ad6(%rip), %rax      # 0x8198
movl (%rax), %ecx
movq -0x10(%rbp), %rax
movslq %ecx, %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, -0x10(%rbp)
cmpl $0x1, -0x8(%rbp)
je 0x26e1
callq 0x28b0
callq 0x2080
movl $0x0, (%rax)
movl $0x1, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, -0x2c(%rbp)
cmpl $0x0, %eax
jle 0x272d
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movsd 0x38f3(%rip), %xmm0     # 0x6008
movsd 0x38f3(%rip), %xmm1     # 0x6010
xorl %esi, %esi
callq 0x28e0
cvttsd2si %xmm0, %eax
movl %eax, -0x2c(%rbp)
jmp 0x27a7
movl $0xffffffff, -0x2c(%rbp) # imm = 0xFFFFFFFF
movb $0x1, %al
testb $0x1, %al
jne 0x273c
jmp 0x277c
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movl -0x2c(%rbp), %edx
xorl %eax, %eax
movl $0x1, %ecx
cmpl $0x0, %edx
cmovlel %ecx, %eax
movslq %eax, %rsi
movl -0x2c(%rbp), %edx
xorl %eax, %eax
movl $0x5, %ecx
cmpl $0x0, %edx
cmovlel %ecx, %eax
movslq %eax, %rdx
xorl %r8d, %r8d
movl %r8d, %ecx
callq 0x2990
movl %eax, -0x2c(%rbp)
movl %eax, -0x6c(%rbp)
jmp 0x27a4
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movslq -0x2c(%rbp), %rcx
movl $0x1, %esi
movl $0x5, %edx
xorl %r9d, %r9d
movl %r9d, %r8d
callq 0x2a50
movl %eax, -0x2c(%rbp)
xorl %eax, %eax
movl %eax, -0x6c(%rbp)
movl -0x6c(%rbp), %eax
callq 0x2080
cmpl $0x0, (%rax)
je 0x27ed
jmp 0x27b3
callq 0x2080
cmpl $0x0, (%rax)
je 0x27d8
leaq 0x38ef(%rip), %rdi      # 0x60b3
movb $0x0, %al
callq 0x4e40
callq 0x2080
movl $0x0, (%rax)
jmp 0x27e6
leaq 0x38d4(%rip), %rdi      # 0x60b3
movb $0x0, %al
callq 0x5090
jmp 0x27e8
jmp 0x2896
movl -0x2c(%rbp), %eax
decl %eax
movl %eax, %ecx
movq %rcx, -0x78(%rbp)
subl $0x4, %eax
ja 0x2872
movq -0x78(%rbp), %rax
leaq 0x3810(%rip), %rcx      # 0x6018
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
cmpq $0x0, -0x20(%rbp)
je 0x281f
cmpq $0x0, -0x28(%rbp)
jne 0x2824
callq 0x28b0
movq -0x20(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0x2b10
cmpl $0x0, %eax
je 0x2838
jmp 0x2896
jmp 0x288f
callq 0x2db0
cmpl $0x0, %eax
je 0x2846
jmp 0x2896
jmp 0x288f
callq 0x2eb0
cmpl $0x0, %eax
je 0x2854
jmp 0x2896
jmp 0x288f
callq 0x3340
cmpl $0x0, %eax
je 0x2862
jmp 0x2896
jmp 0x288f
callq 0x39c0
cmpl $0x0, %eax
je 0x2870
jmp 0x2896
jmp 0x288f
jmp 0x2874
leaq 0x3841(%rip), %rdi      # 0x60bc
movb $0x0, %al
callq 0x5090
callq 0x2080
movl $0x0, (%rax)
jmp 0x2896
xorl %edi, %edi
callq 0x2270
movl $0x1, %edi
callq 0x2270
movq -0x68(%rbp), %rax
jmpq *%rax
nopw %cs:(%rax,%rax)