// File: /workspace/github_c_makefile_star2_O0/jonof[P]jftekwar/jfbuild/src/engine.c
// Function: readv5wall
static int readv5wall(int fil, struct walltypev5 *wall)
{
	if (kread(fil, &wall->x, 4) != 4) return -1;
	if (kread(fil, &wall->y, 4) != 4) return -1;
	if (kread(fil, &wall->point2, 2) != 2) return -1;
	if (kread(fil, &wall->picnum, 2) != 2) return -1;
	if (kread(fil, &wall->overpicnum, 2) != 2) return -1;
	if (kread(fil, &wall->shade, 1) != 1) return -1;
	if (kread(fil, &wall->cstat, 2) != 2) return -1;
	if (kread(fil, &wall->xrepeat, 1) != 1) return -1;
	if (kread(fil, &wall->yrepeat, 1) != 1) return -1;
	if (kread(fil, &wall->xpanning, 1) != 1) return -1;
	if (kread(fil, &wall->ypanning, 1) != 1) return -1;
	if (kread(fil, &wall->nextsector1, 2) != 2) return -1;
	if (kread(fil, &wall->nextwall1, 2) != 2) return -1;
	if (kread(fil, &wall->nextsector2, 2) != 2) return -1;
	if (kread(fil, &wall->nextwall2, 2) != 2) return -1;
	if (kread(fil, &wall->lotag, 2) != 2) return -1;
	if (kread(fil, &wall->hitag, 2) != 2) return -1;
	if (kread(fil, &wall->extra, 2) != 2) return -1;

	wall->x = B_LITTLE32(wall->x);
	wall->y = B_LITTLE32(wall->y);
	wall->point2 = B_LITTLE16(wall->point2);
	wall->picnum = B_LITTLE16(wall->picnum);
	wall->overpicnum = B_LITTLE16(wall->overpicnum);
	wall->cstat = B_LITTLE16(wall->cstat);
	wall->nextsector1 = B_LITTLE16(wall->nextsector1);
	wall->nextwall1 = B_LITTLE16(wall->nextwall1);
	wall->nextsector2 = B_LITTLE16(wall->nextsector2);
	wall->nextwall2 = B_LITTLE16(wall->nextwall2);
	wall->lotag = B_LITTLE16(wall->lotag);
	wall->hitag = B_LITTLE16(wall->hitag);
	wall->extra = B_LITTLE16(wall->extra);

	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
movl $0x4, %edx
callq 0x302b0
cmpl $0x4, %eax
je 0x48231
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x4, %rsi
movl $0x4, %edx
callq 0x302b0
cmpl $0x4, %eax
je 0x48257
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x8, %rsi
movl $0x2, %edx
callq 0x302b0
cmpl $0x2, %eax
je 0x4827d
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0xa, %rsi
movl $0x2, %edx
callq 0x302b0
cmpl $0x2, %eax
je 0x482a3
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0xc, %rsi
movl $0x2, %edx
callq 0x302b0
cmpl $0x2, %eax
je 0x482c9
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0xe, %rsi
movl $0x1, %edx
callq 0x302b0
cmpl $0x1, %eax
je 0x482ef
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x10, %rsi
movl $0x2, %edx
callq 0x302b0
cmpl $0x2, %eax
je 0x48315
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x12, %rsi
movl $0x1, %edx
callq 0x302b0
cmpl $0x1, %eax
je 0x4833b
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x13, %rsi
movl $0x1, %edx
callq 0x302b0
cmpl $0x1, %eax
je 0x48361
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x14, %rsi
movl $0x1, %edx
callq 0x302b0
cmpl $0x1, %eax
je 0x48387
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x15, %rsi
movl $0x1, %edx
callq 0x302b0
cmpl $0x1, %eax
je 0x483ad
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x16, %rsi
movl $0x2, %edx
callq 0x302b0
cmpl $0x2, %eax
je 0x483d3
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x18, %rsi
movl $0x2, %edx
callq 0x302b0
cmpl $0x2, %eax
je 0x483f9
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x1a, %rsi
movl $0x2, %edx
callq 0x302b0
cmpl $0x2, %eax
je 0x4841f
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x1c, %rsi
movl $0x2, %edx
callq 0x302b0
cmpl $0x2, %eax
je 0x48445
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x1e, %rsi
movl $0x2, %edx
callq 0x302b0
cmpl $0x2, %eax
je 0x4846b
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x20, %rsi
movl $0x2, %edx
callq 0x302b0
cmpl $0x2, %eax
je 0x48491
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x22, %rsi
movl $0x2, %edx
callq 0x302b0
cmpl $0x2, %eax
je 0x484b7
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x48588
movq -0x10(%rbp), %rax
movl (%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, (%rax)
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x4(%rax)
movq -0x10(%rbp), %rax
movw 0x8(%rax), %cx
movq -0x10(%rbp), %rax
movw %cx, 0x8(%rax)
movq -0x10(%rbp), %rax
movw 0xa(%rax), %cx
movq -0x10(%rbp), %rax
movw %cx, 0xa(%rax)
movq -0x10(%rbp), %rax
movw 0xc(%rax), %cx
movq -0x10(%rbp), %rax
movw %cx, 0xc(%rax)
movq -0x10(%rbp), %rax
movw 0x10(%rax), %cx
movq -0x10(%rbp), %rax
movw %cx, 0x10(%rax)
movq -0x10(%rbp), %rax
movw 0x16(%rax), %cx
movq -0x10(%rbp), %rax
movw %cx, 0x16(%rax)
movq -0x10(%rbp), %rax
movw 0x18(%rax), %cx
movq -0x10(%rbp), %rax
movw %cx, 0x18(%rax)
movq -0x10(%rbp), %rax
movw 0x1a(%rax), %cx
movq -0x10(%rbp), %rax
movw %cx, 0x1a(%rax)
movq -0x10(%rbp), %rax
movw 0x1c(%rax), %cx
movq -0x10(%rbp), %rax
movw %cx, 0x1c(%rax)
movq -0x10(%rbp), %rax
movw 0x1e(%rax), %cx
movq -0x10(%rbp), %rax
movw %cx, 0x1e(%rax)
movq -0x10(%rbp), %rax
movw 0x20(%rax), %cx
movq -0x10(%rbp), %rax
movw %cx, 0x20(%rax)
movq -0x10(%rbp), %rax
movw 0x22(%rax), %cx
movq -0x10(%rbp), %rax
movw %cx, 0x22(%rax)
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)