// File: /workspace/github_c_makefile_star2_O0/jonof[P]jftekwar/jfbuild/src/engine.c
// Function: writev6sect
static int writev6sect(int fil, struct sectortypev6 *sect)
{
	uint32_t tl;
	uint16_t ts;

	ts = B_LITTLE16(sect->wallptr); if (Bwrite(fil, &ts, 2) != 2) return -1;
	ts = B_LITTLE16(sect->wallnum); if (Bwrite(fil, &ts, 2) != 2) return -1;
	ts = B_LITTLE16(sect->ceilingpicnum); if (Bwrite(fil, &ts, 2) != 2) return -1;
	ts = B_LITTLE16(sect->floorpicnum); if (Bwrite(fil, &ts, 2) != 2) return -1;
	ts = B_LITTLE16(sect->ceilingheinum); if (Bwrite(fil, &ts, 2) != 2) return -1;
	ts = B_LITTLE16(sect->floorheinum); if (Bwrite(fil, &ts, 2) != 2) return -1;
	tl = B_LITTLE32(sect->ceilingz); if (Bwrite(fil, &tl, 4) != 4) return -1;
	tl = B_LITTLE32(sect->floorz); if (Bwrite(fil, &tl, 4) != 4) return -1;
	if (Bwrite(fil, &sect->ceilingshade, 1) != 1) return -1;
	if (Bwrite(fil, &sect->floorshade, 1) != 1) return -1;
	if (Bwrite(fil, &sect->ceilingxpanning, 1) != 1) return -1;
	if (Bwrite(fil, &sect->floorxpanning, 1) != 1) return -1;
	if (Bwrite(fil, &sect->ceilingypanning, 1) != 1) return -1;
	if (Bwrite(fil, &sect->floorypanning, 1) != 1) return -1;
	if (Bwrite(fil, &sect->ceilingstat, 1) != 1) return -1;
	if (Bwrite(fil, &sect->floorstat, 1) != 1) return -1;
	if (Bwrite(fil, &sect->ceilingpal, 1) != 1) return -1;
	if (Bwrite(fil, &sect->floorpal, 1) != 1) return -1;
	if (Bwrite(fil, &sect->visibility, 1) != 1) return -1;
	ts = B_LITTLE16(sect->lotag); if (Bwrite(fil, &ts, 2) != 2) return -1;
	ts = B_LITTLE16(sect->hitag); if (Bwrite(fil, &ts, 2) != 2) return -1;
	ts = B_LITTLE16(sect->extra); if (Bwrite(fil, &ts, 2) != 2) return -1;

	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movw (%rax), %ax
movw %ax, -0x16(%rbp)
movl -0x8(%rbp), %edi
leaq -0x16(%rbp), %rsi
movl $0x2, %edx
callq 0x6a20
cmpq $0x2, %rax
je 0x4a95d
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movq -0x10(%rbp), %rax
movw 0x2(%rax), %ax
movw %ax, -0x16(%rbp)
movl -0x8(%rbp), %edi
leaq -0x16(%rbp), %rsi
movl $0x2, %edx
callq 0x6a20
cmpq $0x2, %rax
je 0x4a98c
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movq -0x10(%rbp), %rax
movw 0x4(%rax), %ax
movw %ax, -0x16(%rbp)
movl -0x8(%rbp), %edi
leaq -0x16(%rbp), %rsi
movl $0x2, %edx
callq 0x6a20
cmpq $0x2, %rax
je 0x4a9bb
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movq -0x10(%rbp), %rax
movw 0x6(%rax), %ax
movw %ax, -0x16(%rbp)
movl -0x8(%rbp), %edi
leaq -0x16(%rbp), %rsi
movl $0x2, %edx
callq 0x6a20
cmpq $0x2, %rax
je 0x4a9ea
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movq -0x10(%rbp), %rax
movw 0x8(%rax), %ax
movw %ax, -0x16(%rbp)
movl -0x8(%rbp), %edi
leaq -0x16(%rbp), %rsi
movl $0x2, %edx
callq 0x6a20
cmpq $0x2, %rax
je 0x4aa19
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movq -0x10(%rbp), %rax
movw 0xa(%rax), %ax
movw %ax, -0x16(%rbp)
movl -0x8(%rbp), %edi
leaq -0x16(%rbp), %rsi
movl $0x2, %edx
callq 0x6a20
cmpq $0x2, %rax
je 0x4aa48
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movq -0x10(%rbp), %rax
movl 0xc(%rax), %eax
movl %eax, -0x14(%rbp)
movl -0x8(%rbp), %edi
leaq -0x14(%rbp), %rsi
movl $0x4, %edx
callq 0x6a20
cmpq $0x4, %rax
je 0x4aa75
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movq -0x10(%rbp), %rax
movl 0x10(%rax), %eax
movl %eax, -0x14(%rbp)
movl -0x8(%rbp), %edi
leaq -0x14(%rbp), %rsi
movl $0x4, %edx
callq 0x6a20
cmpq $0x4, %rax
je 0x4aaa2
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x14, %rsi
movl $0x1, %edx
callq 0x6a20
cmpq $0x1, %rax
je 0x4aac9
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x15, %rsi
movl $0x1, %edx
callq 0x6a20
cmpq $0x1, %rax
je 0x4aaf0
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x16, %rsi
movl $0x1, %edx
callq 0x6a20
cmpq $0x1, %rax
je 0x4ab17
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x17, %rsi
movl $0x1, %edx
callq 0x6a20
cmpq $0x1, %rax
je 0x4ab3e
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x18, %rsi
movl $0x1, %edx
callq 0x6a20
cmpq $0x1, %rax
je 0x4ab65
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x19, %rsi
movl $0x1, %edx
callq 0x6a20
cmpq $0x1, %rax
je 0x4ab8c
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x1a, %rsi
movl $0x1, %edx
callq 0x6a20
cmpq $0x1, %rax
je 0x4abb3
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x1b, %rsi
movl $0x1, %edx
callq 0x6a20
cmpq $0x1, %rax
je 0x4abda
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x1c, %rsi
movl $0x1, %edx
callq 0x6a20
cmpq $0x1, %rax
je 0x4ac01
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x1d, %rsi
movl $0x1, %edx
callq 0x6a20
cmpq $0x1, %rax
je 0x4ac28
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
addq $0x1e, %rsi
movl $0x1, %edx
callq 0x6a20
cmpq $0x1, %rax
je 0x4ac4f
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movq -0x10(%rbp), %rax
movw 0x20(%rax), %ax
movw %ax, -0x16(%rbp)
movl -0x8(%rbp), %edi
leaq -0x16(%rbp), %rsi
movl $0x2, %edx
callq 0x6a20
cmpq $0x2, %rax
je 0x4ac7b
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movq -0x10(%rbp), %rax
movw 0x22(%rax), %ax
movw %ax, -0x16(%rbp)
movl -0x8(%rbp), %edi
leaq -0x16(%rbp), %rsi
movl $0x2, %edx
callq 0x6a20
cmpq $0x2, %rax
je 0x4aca7
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movq -0x10(%rbp), %rax
movw 0x24(%rax), %ax
movw %ax, -0x16(%rbp)
movl -0x8(%rbp), %edi
leaq -0x16(%rbp), %rsi
movl $0x2, %edx
callq 0x6a20
cmpq $0x2, %rax
je 0x4acd3
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x4acda
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)