// File: /workspace/github_c_makefile_star2_O0/ajpaulson[P]srogue11/options.c
// Function: parse_opts
void parse_opts(char *str)
{
	char *sp;
	OPTION *op;
	int len;

	while (*str) {
		for (sp = str; isalpha(*sp); sp++)	/* get option name */
			continue;
		len = sp - str;
		for (op = optlist; op < &optlist[NUM_OPTS]; op++) {
			if (EQSTR(str, op->o_name, len)) {
				char *start;
	
				for (str = sp + 1; *str == '='; str++)
					continue;
				if (*str == '~') {
					strcpy(op->o_opt, home);
					start = op->o_opt + strlen(home);
					while (*++str == '/')
						continue;
				}
				else
					start = (char *) op->o_opt;
				for (sp = str + 1; *sp && *sp != ','; sp++)
					continue;
				strucpy(start, str, sp - str);
			}
		}
		/*
		 * skip to start of next option name
		 */
		while (*sp && !isalpha(*sp))
			sp++;
		str = sp;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
cmpb $0x0, (%rax)
je 0x14272
movq -0x8(%rbp), %rax
movq %rax, -0x10(%rbp)
callq 0x65b0
movq (%rax), %rax
movq -0x10(%rbp), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x400, %eax            # imm = 0x400
cmpl $0x0, %eax
je 0x140c1
jmp 0x140b3
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x14091
movq -0x10(%rbp), %rax
movq -0x8(%rbp), %rcx
subq %rcx, %rax
movl %eax, -0x1c(%rbp)
leaq 0x222da(%rip), %rax     # 0x363b0
movq %rax, -0x18(%rbp)
leaq 0x222cf(%rip), %rax     # 0x363b0
addq $0x48, %rax
cmpq %rax, -0x18(%rbp)
jae 0x14215
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rax
movq (%rax), %rsi
movslq -0x1c(%rbp), %rdx
callq 0x60b0
cmpl $0x0, %eax
jne 0x14202
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x3d, %eax
jne 0x14134
jmp 0x14126
movq -0x8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x8(%rbp)
jmp 0x14118
movq -0x8(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x7e, %eax
jne 0x14196
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rdi
leaq 0x23391(%rip), %rsi     # 0x374e0
callq 0x60d0
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x30(%rbp)
leaq 0x23379(%rip), %rdi     # 0x374e0
callq 0x6160
movq %rax, %rcx
movq -0x30(%rbp), %rax
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x8(%rbp)
movsbl 0x1(%rax), %eax
cmpl $0x2f, %eax
jne 0x14194
jmp 0x1417a
jmp 0x141a2
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movsbl (%rax), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0x31(%rbp)
je 0x141cf
movq -0x10(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x2c, %eax
setne %al
movb %al, -0x31(%rbp)
movb -0x31(%rbp), %al
testb $0x1, %al
jne 0x141d8
jmp 0x141e8
jmp 0x141da
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x141ae
movq -0x28(%rbp), %rdi
movq -0x8(%rbp), %rsi
movq -0x10(%rbp), %rax
movq -0x8(%rbp), %rcx
subq %rcx, %rax
movl %eax, %edx
callq 0x13ff0
jmp 0x14204
movq -0x18(%rbp), %rax
addq $0x18, %rax
movq %rax, -0x18(%rbp)
jmp 0x140da
jmp 0x14217
movq -0x10(%rbp), %rax
movsbl (%rax), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0x32(%rbp)
je 0x1424e
callq 0x65b0
movq (%rax), %rax
movq -0x10(%rbp), %rcx
movsbl (%rcx), %ecx
movslq %ecx, %rcx
movzwl (%rax,%rcx,2), %eax
andl $0x400, %eax            # imm = 0x400
cmpl $0x0, %eax
setne %al
xorb $-0x1, %al
movb %al, -0x32(%rbp)
movb -0x32(%rbp), %al
testb $0x1, %al
jne 0x14257
jmp 0x14265
movq -0x10(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x10(%rbp)
jmp 0x14217
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x1407c
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)