// File: /workspace/github_c_makefile_star2_O1/skeeto[P]goblin-com/src/display.c
// Function: panel_border
void
panel_border(panel_t *p, font_t font)
{
    for (int x = 1; x < p->w - 1; x++) {
        panel_putc(p, x, 0,        font, 0x2500);
        panel_putc(p, x, p->h - 1, font, 0x2500);
    }
    for (int y = 1; y < p->h - 1; y++) {
        panel_putc(p, 0,        y, font, 0x2502);
        panel_putc(p, p->w - 1, y, font, 0x2502);
    }
    panel_putc(p, 0,        0,        font, 0x250C);
    panel_putc(p, p->w - 1, 0,        font, 0x2510);
    panel_putc(p, 0,        p->h - 1, font, 0x2514);
    panel_putc(p, p->w - 1, p->h - 1, font, 0x2518);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movslq 0x8(%rdi), %rcx
leal -0x1(%rcx), %eax
cmpq $0x3, %rcx
jl 0x3bdd
movslq (%rdi), %rdx
movl 0x4(%rdi), %r8d
movl 0xc(%rdi), %r9d
addl %r8d, %r9d
decl %r9d
movl %eax, %r10d
leaq (%rdx,%rdx,2), %r11
shlq $0x6, %r11
addq %rdi, %r11
addq $0xd3, %r11
movl $0x1, %ebx
testl %r8d, %r8d
setns %bpl
movq %rdx, %r14
addq %rbx, %r14
setns %r15b
cmpq %rcx, %rbx
setb %r12b
andb %bpl, %r15b
andb %r12b, %r15b
cmpb $0x1, %r15b
jne 0x3bad
cmpl $0x0, 0xc(%rdi)
jle 0x3bad
movb $0x0, -0x1(%r11,%r8,8)
movw $0x2500, -0x3(%r11,%r8,8) # imm = 0x2500
movl %esi, (%r11,%r8,8)
testq %r14, %r14
js 0x3bce
cmpq %rcx, %rbx
jae 0x3bce
testl %r9d, %r9d
js 0x3bce
movb $0x0, -0x1(%r11,%r9,8)
movw $0x2500, -0x3(%r11,%r9,8) # imm = 0x2500
movl %esi, (%r11,%r9,8)
incq %rbx
addq $0xc0, %r11
cmpq %rbx, %r10
jne 0x3b71
movslq 0xc(%rdi), %r8
leal -0x1(%r8), %edx
cmpq $0x3, %r8
jl 0x3c7c
movl (%rdi), %r9d
movslq 0x4(%rdi), %r10
leal (%r9,%rax), %r11d
movl %edx, %ebx
leaq (%r11,%r11,2), %r14
shlq $0x6, %r14
leaq (%r14,%r10,8), %r14
addq %rdi, %r14
addq $0x18, %r14
leaq (%r9,%r9,2), %r15
shlq $0x6, %r15
leaq (%r15,%r10,8), %r15
addq %rdi, %r15
addq $0x18, %r15
movl $0x1, %r12d
leaq (%r10,%r12), %r13
testl %r9d, %r9d
js 0x3c52
cmpq %r8, %r12
jae 0x3c52
testl %ecx, %ecx
jle 0x3c52
testq %r13, %r13
js 0x3c52
movb $0x0, -0x6(%r15,%r12,8)
movw $0x2502, -0x8(%r15,%r12,8) # imm = 0x2502
movl %esi, -0x5(%r15,%r12,8)
cmpq %r8, %r12
jae 0x3c74
testl %r11d, %r11d
js 0x3c74
testq %r13, %r13
js 0x3c74
movb $0x0, -0x6(%r14,%r12,8)
movw $0x2502, -0x8(%r14,%r12,8) # imm = 0x2502
movl %esi, -0x5(%r14,%r12,8)
incq %r12
cmpq %r12, %rbx
jne 0x3c28
movslq (%rdi), %r10
movl 0x4(%rdi), %r9d
testq %r10, %r10
js 0x3cb4
testl %r8d, %r8d
jle 0x3cb4
testl %ecx, %ecx
jle 0x3cb4
testl %r9d, %r9d
js 0x3cb4
leaq (%r10,%r10,2), %r11
shlq $0x6, %r11
addq %rdi, %r11
movb $0x0, 0x12(%r11,%r9,8)
movw $0x250c, 0x10(%r11,%r9,8) # imm = 0x250C
movl %esi, 0x13(%r11,%r9,8)
addl %r10d, %eax
movl %eax, %r11d
testl %r8d, %r8d
jle 0x3ce6
testl %eax, %eax
js 0x3ce6
testl %r9d, %r9d
js 0x3ce6
leaq (%r11,%r11,2), %r8
shlq $0x6, %r8
addq %rdi, %r8
movb $0x0, 0x12(%r8,%r9,8)
movw $0x2510, 0x10(%r8,%r9,8) # imm = 0x2510
movl %esi, 0x13(%r8,%r9,8)
addl %edx, %r9d
testl %r10d, %r10d
js 0x3d15
testl %ecx, %ecx
jle 0x3d15
testl %r9d, %r9d
js 0x3d15
leaq (%r10,%r10,2), %rcx
shlq $0x6, %rcx
addq %rdi, %rcx
movl %r9d, %edx
movb $0x0, 0x12(%rcx,%rdx,8)
movw $0x2514, 0x10(%rcx,%rdx,8) # imm = 0x2514
movl %esi, 0x13(%rcx,%rdx,8)
testl %eax, %eax
js 0x3d3c
testl %r9d, %r9d
js 0x3d3c
leaq (%r11,%r11,2), %rax
shlq $0x6, %rax
addq %rax, %rdi
movl %r9d, %eax
movb $0x0, 0x12(%rdi,%rax,8)
movw $0x2518, 0x10(%rdi,%rax,8) # imm = 0x2518
movl %esi, 0x13(%rdi,%rax,8)
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq