// File: /workspace/github_c_makefile_star2_O3/jsummers[P]deark/modules/wad.c
// Function: de_run_wad
static void de_run_wad(deark *c, de_module_params *mparams)
{
	lctx *d = NULL;

	d = de_malloc(c, sizeof(lctx));

	if(!do_header(c, d, 0)) goto done;

	do_directory(c, d, d->dir_pos);

done:
	de_free(c, d);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movl $0x10, %esi
callq 0xe8b2b
movq %rax, %r14
leaq 0x67461(%rip), %rsi     # 0x1396ee
movq %rbx, %rdi
xorl %edx, %edx
xorl %eax, %eax
callq 0xe8617
movq %rbx, %rdi
movl $0x1, %esi
callq 0xe8a15
movq 0x18(%rbx), %rdi
movl $0x4, %esi
callq 0xeed61
movq %rax, (%r14)
leaq 0x6e4f2(%rip), %rsi     # 0x1407b0
movq %rbx, %rdi
movl %eax, %edx
xorl %eax, %eax
callq 0xe8617
movq 0x18(%rbx), %rdi
movl $0x8, %esi
callq 0xeed61
movq %rax, 0x8(%r14)
leaq 0x6e4d8(%rip), %rsi     # 0x1407bb
movq %rbx, %rdi
movl %eax, %edx
xorl %eax, %eax
callq 0xe8617
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0xe8a15
movq %r14, 0x8(%rsp)
movq 0x8(%r14), %r15
leaq 0x6e4bb(%rip), %rsi     # 0x1407c7
movq %rbx, %rdi
movl %r15d, %edx
xorl %eax, %eax
callq 0xe8617
movq %rbx, %rdi
movl $0x1, %esi
callq 0xe8a15
testq %r15, %r15
js 0xd24c0
movq 0x18(%rbx), %rax
cmpq %r15, 0x18(%rax)
jle 0xd24c0
movq $-0x2711, %rax          # imm = 0xD8EF
movq 0x8(%rsp), %rcx
addq (%rcx), %rax
cmpq $-0x2710, %rax          # imm = 0xD8F0
jb 0xd24c0
xorl %r13d, %r13d
movq 0x18(%rbx), %rax
movq 0x18(%rax), %rax
addq $-0x10, %rax
cmpq %rax, %r15
jg 0xd24c0
movq %rbx, %rdi
leaq 0x6e45d(%rip), %rsi     # 0x1407d7
movl %r13d, %edx
movl %r15d, %ecx
xorl %eax, %eax
callq 0xe8617
movq %rbx, %rdi
movl $0x1, %esi
callq 0xe8a15
movq 0x18(%rbx), %rdi
movq %r15, %rsi
callq 0xeed61
movq %rax, %rbp
movq %rbx, %rdi
leaq 0x417ce(%rip), %rsi     # 0x113b7b
movl %ebp, %edx
xorl %eax, %eax
callq 0xe8617
movq 0x18(%rbx), %rdi
leaq 0x4(%r15), %rsi
callq 0xeed61
movq %rax, %r12
movq %rbx, %rdi
leaq 0x405e9(%rip), %rsi     # 0x1129b9
movl %r12d, %edx
xorl %eax, %eax
callq 0xe8617
movq 0x18(%rbx), %rdi
leaq 0x8(%r15), %rsi
movl $0x8, %edx
movl $0x8, %ecx
movl $0x1, %r8d
movl $0x1, %r9d
callq 0xef87c
movq %rax, %r14
movq 0x18(%rax), %rdi
callq 0xf70f6
movq %rbx, %rdi
leaq 0x50368(%rip), %rsi     # 0x12277b
movq %rax, %rdx
xorl %eax, %eax
callq 0xe8617
testq %r12, %r12
setle %al
testq %rbp, %rbp
sets %cl
orb %al, %cl
jne 0xd2493
movq 0x18(%rbx), %rax
movq 0x18(%rax), %rax
cmpq %rbp, %rax
setle %cl
leaq (%r12,%rbp), %rdx
cmpq %rax, %rdx
setg %al
orb %cl, %al
jne 0xd2493
movq %rbx, %rdi
callq 0xea504
movq %rax, 0x10(%rsp)
movq 0x18(%r14), %rdx
movq %rbx, %rdi
movq %rax, %rsi
xorl %ecx, %ecx
callq 0xea53f
movq 0x10(%rsp), %r8
movb $0x1, 0x8(%r8)
movq 0x18(%rbx), %rdi
movq %rbp, %rsi
movq %r12, %rdx
xorl %ecx, %ecx
movq %r8, %r12
xorl %r9d, %r9d
callq 0xefd48
movq %rbx, %rdi
movq %r12, %rsi
callq 0xea50e
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0xe8a15
movq %rbx, %rdi
movq %r14, %rsi
callq 0xefaca
incq %r13
addq $0x10, %r15
movq 0x8(%rsp), %rax
cmpq (%rax), %r13
jl 0xd235b
movq %rbx, %rdi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
callq 0xe8a15
movq %rbx, %rdi
movq 0x8(%rsp), %rsi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xe8be2