// File: /workspace/github_c_makefile_star2_O2/kisom[P]rmtmp/rmtmp.c
// Function: main
int
main(int argc, char *argv[])
{
	char	*tmpdir = NULL;
	int	 opt;

	if (argc == 1) {
		fprintf(stderr, "no prefix given\n");
		return EXIT_FAILURE;
	}

	while ((opt = getopt(argc, (char *const *) argv, "d:hvV")) != -1) {
		switch (opt) {
		case 'd':
			tmpdir = optarg;
			break;
		case 'h':
			usage();
			/* NOT REACHED */
			break;
		case 'v':
			verbose = 1;
			break;
		case 'V':
			version();
			exit(EX_USAGE);
		default:
			/* NOT REACHED */
			fprintf(stderr, "invalid argument!\n");
			return EXIT_FAILURE;
		}
	}

	argc -= optind;
	argv += optind;

	if (argc > 1)
		fprintf(stderr, "warning: multiple prefixes selected, "
		    "but only the first will be used.\n");

	if (NULL == tmpdir) {
		if ((NULL == (tmpdir = getenv("TMPDIR"))) || (*tmpdir == '\0'))
			tmpdir = (char *)TMP_DIR;
	}

	if (remove_tmp(tmpdir, argv[0]) != 0) {
		fprintf(stderr, "failed to remove some files.\n");
		return EXIT_FAILURE;
	}
	return EXIT_SUCCESS;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x418, %rsp            # imm = 0x418
cmpl $0x1, %edi
je 0x401891
movq %rsi, %r14
movl %edi, %ebp
xorl %ebx, %ebx
leaq 0x97935(%rip), %r15     # 0x499015
movq $0x4d0240, %r12         # imm = 0x4D0240
movl %ebp, %edi
movq %r14, %rsi
movq %r15, %rdx
callq 0x4509c0
cmpl $0x76, %eax
jne 0x401702
movb $0x1, 0xc9bf0(%rip)     # 0x4cb2f0
jmp 0x4016e7
cmpl $-0x1, %eax
je 0x401716
cmpl $0x64, %eax
jne 0x4018a6
movq (%r12), %rbx
jmp 0x4016e7
movq $0x4ca080, %rax         # imm = 0x4CA080
movslq (%rax), %r15
subl %r15d, %ebp
cmpl $0x2, %ebp
jge 0x4018c9
testq %rbx, %rbx
jne 0x401751
leaq 0x9793d(%rip), %rdi     # 0x499075
callq 0x40a980
testq %rax, %rax
je 0x40174a
movq %rax, %rbx
cmpb $0x0, (%rax)
jne 0x401751
leaq 0x9792b(%rip), %rbx     # 0x49907c
movq (%r14,%r15,8), %r15
movl $0x400, %esi            # imm = 0x400
movq %r15, %rdi
callq 0x401050
movq %rax, %r12
movq %rbx, %rdi
callq 0x44ef40
testq %rax, %rax
je 0x40196a
movq %rax, %r13
xorl %r14d, %r14d
xorl %ebp, %ebp
movq %rbp, 0x8(%rsp)
movq %r13, %rdi
callq 0x44f1a0
testq %rax, %rax
je 0x401842
movq %rax, %rbp
cmpb $0x8, 0x12(%rax)
jne 0x401783
addq $0x13, %rbp
movq %rbp, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x401080
testl %eax, %eax
jne 0x401783
movl $0x400, %esi            # imm = 0x400
leaq 0x10(%rsp), %rdi
leaq 0x97926(%rip), %rdx     # 0x4990ea
movq %rbx, %rcx
movq %rbp, %r8
movq %rdi, %rbp
xorl %eax, %eax
callq 0x40b8d0
incq %r14
movq %rbp, %rdi
callq 0x451590
testl %eax, %eax
je 0x4017f6
leaq 0x97906(%rip), %rdi     # 0x4990f0
movq %rbp, %rsi
xorl %eax, %eax
callq 0x452e80
jmp 0x401783
movq 0x8(%rsp), %rbp
incq %rbp
movb 0xc9aec(%rip), %cl      # 0x4cb2f0
movq %rbp, %rax
xorl %edx, %edx
movl $0x3e8, %esi            # imm = 0x3E8
divq %rsi
cmpb $0x1, %cl
jne 0x40177e
testq %rbp, %rbp
je 0x40177e
testq %rdx, %rdx
jne 0x40177e
leaq 0x978c7(%rip), %rdi     # 0x4990fa
movq %rbp, %rsi
xorl %eax, %eax
callq 0x40b800
jmp 0x40177e
movq %r13, %rdi
callq 0x44f170
cmpl $-0x1, %eax
jne 0x401860
leaq 0x978b7(%rip), %rdi     # 0x49910d
movq %rbx, %rsi
xorl %eax, %eax
callq 0x452e80
leaq 0x97893(%rip), %rdi     # 0x4990fa
xorl %ebx, %ebx
movq 0x8(%rsp), %r15
movq %r15, %rsi
xorl %eax, %eax
callq 0x40b800
cmpq %r15, %r14
jne 0x4018ea
movl %ebx, %eax
addq $0x418, %rsp            # imm = 0x418
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq $0x4c96e8, %rax         # imm = 0x4C96E8
movq (%rax), %rcx
leaq 0x97762(%rip), %rdi     # 0x499004
pushq $0x10
jmp 0x4018fd
cmpl $0x56, %eax
je 0x40195d
cmpl $0x68, %eax
je 0x40190e
movq $0x4c96e8, %rax         # imm = 0x4C96E8
movq (%rax), %rcx
leaq 0x97756(%rip), %rdi     # 0x49901b
pushq $0x12
jmp 0x4018fd
movq $0x4c96e8, %rax         # imm = 0x4C96E8
movq (%rax), %rcx
leaq 0x97754(%rip), %rdi     # 0x49902e
pushq $0x46
popq %rsi
pushq $0x1
popq %rdx
callq 0x412350
jmp 0x40172c
movq $0x4c96e8, %rax         # imm = 0x4C96E8
movq (%rax), %rcx
leaq 0x97786(%rip), %rdi     # 0x499081
pushq $0x1d
popq %rsi
pushq $0x1
popq %rdx
callq 0x412350
pushq $0x1
popq %rbx
jmp 0x40187d
callq 0x40197e
movq $0x4ca088, %rax         # imm = 0x4CA088
movq (%rax), %rsi
leaq 0x9777b(%rip), %rdi     # 0x49909f
xorl %eax, %eax
callq 0x40b800
leaq 0x977ed(%rip), %rdi     # 0x49911f
callq 0x412620
leaq 0x97811(%rip), %rdi     # 0x49914f
callq 0x412620
leaq 0x9782c(%rip), %rdi     # 0x499176
callq 0x412620
leaq 0x97832(%rip), %rdi     # 0x499188
callq 0x412620
jmp 0x401962
callq 0x40197e
pushq $0x40
popq %rdi
callq 0x40acd0
leaq 0x97768(%rip), %rsi     # 0x4990d9
pushq $0x47
popq %rdi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x453110