// File: /workspace/github_c_makefile_star2_O0/Nico01[P]obj2asm/odisasm.c
// Function: disp8
int disp8( byte, text, class )
    uchar   byte;
    char            *text;
    int             class;
{
    int             dcheck;
    char            line[60];
    char            *short_text;
    dword   offset;
    dword   dest;
    PUB_T           *pub_rec;

    if ( over_seg != -1 ) {             /* No segment overide allowed */
        return( 0 );
    }

    dcheck = data_check(1);

    if ( dcheck != NORMAL && dcheck != BAD ) {
        return( 0 );
    }

    if ( check_getc( &offset ) ) {
        return( 0 );
    }

    if ( offset == 0xFFFFFFFFL ) {      /* This would generate a label in  */
        return( 0 );                    /* the middle of the jmp statement */
    }                                   /* thereby preventing it anyway    */

    /*
    ** Special 'SHORT' for small jumps 
    */
    short_text = "";
    if ( compatibility != 2 ) {
        if ( byte == 0xEB || segment_mode == 386 ) {
            short_text = "short ";
        }
    }

    dest = inst_offset + (signed char)offset + 2;

    pub_rec = check_public( 1, segment, dest, 'L' );

    if ( pub_rec ) {
        pub_rec->type = NEAR;
        offset = dest - pub_rec->offset;
        if ( offset > 0 ) {
            sprintf( line, "%s%s + 0%04lXh", 
                                short_text, pub_rec->name, offset );
        } else {
            sprintf( line, "%s%s", short_text, pub_rec->name );
        }
    } else {
        if ( compatibility == 2 ) {
            sprintf( text, " %s.0%04lXh", short_text, offset );
        } else {
            sprintf( text, "%s[%s:0%04lXh]", short_text, cseg_name, offset );
        }
    }

    instr_opcode( text );
    instr_operand( line );

    byte = byte;               /* Prevent unused variable warnings */
    class = class;
    return( 2 );
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movb %dil, %al
movb %al, -0x5(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
cmpl $-0x1, 0x12109(%rip)    # 0x1ca78
je 0xa97d
movl $0x0, -0x4(%rbp)
jmp 0xab2e
movl $0x1, %edi
callq 0xe580
movl %eax, -0x18(%rbp)
cmpl $0x0, -0x18(%rbp)
je 0xa9a2
cmpl $0x3, -0x18(%rbp)
je 0xa9a2
movl $0x0, -0x4(%rbp)
jmp 0xab2e
leaq -0x70(%rbp), %rdi
callq 0x9460
cmpl $0x0, %eax
je 0xa9bc
movl $0x0, -0x4(%rbp)
jmp 0xab2e
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpq %rax, -0x70(%rbp)
jne 0xa9d3
movl $0x0, -0x4(%rbp)
jmp 0xab2e
leaq 0xd7e6(%rip), %rax      # 0x181c0
movq %rax, -0x68(%rbp)
leaq 0x156e3(%rip), %rax     # 0x200c8
cmpl $0x2, (%rax)
je 0xaa11
movzbl -0x5(%rbp), %eax
cmpl $0xeb, %eax
je 0xaa04
leaq 0x15974(%rip), %rax     # 0x20370
cmpl $0x182, (%rax)          # imm = 0x182
jne 0xaa0f
leaq 0xc93e(%rip), %rax      # 0x17349
movq %rax, -0x68(%rbp)
jmp 0xaa11
leaq 0x15950(%rip), %rax     # 0x20368
movq (%rax), %rax
movq -0x70(%rbp), %rcx
movsbq %cl, %rcx
addq %rcx, %rax
addq $0x2, %rax
movq %rax, -0x78(%rbp)
leaq 0x1592b(%rip), %rax     # 0x20360
movl (%rax), %esi
movq -0x78(%rbp), %rdx
movl $0x1, %edi
movl $0x4c, %ecx
callq 0x12720
movq %rax, -0x80(%rbp)
cmpq $0x0, -0x80(%rbp)
je 0xaabb
movq -0x80(%rbp), %rax
movl $0x1, 0x38(%rax)
movq -0x78(%rbp), %rax
movq -0x80(%rbp), %rcx
subq 0x8(%rcx), %rax
movq %rax, -0x70(%rbp)
cmpq $0x0, -0x70(%rbp)
jbe 0xaa9b
leaq -0x60(%rbp), %rdi
movq -0x68(%rbp), %rdx
movq -0x80(%rbp), %rcx
addq $0x10, %rcx
movq -0x70(%rbp), %r8
leaq 0xc8be(%rip), %rsi      # 0x17350
movb $0x0, %al
callq 0x9190
jmp 0xaab9
leaq -0x60(%rbp), %rdi
movq -0x68(%rbp), %rdx
movq -0x80(%rbp), %rcx
addq $0x10, %rcx
leaq 0xda69(%rip), %rsi      # 0x1851b
movb $0x0, %al
callq 0x9190
jmp 0xab09
leaq 0x15606(%rip), %rax     # 0x200c8
cmpl $0x2, (%rax)
jne 0xaae3
movq -0x10(%rbp), %rdi
movq -0x68(%rbp), %rdx
movq -0x70(%rbp), %rcx
leaq 0xc885(%rip), %rsi      # 0x1735f
movb $0x0, %al
callq 0x9190
jmp 0xab07
movq -0x10(%rbp), %rdi
movq -0x68(%rbp), %rdx
leaq 0x15886(%rip), %rax     # 0x20378
movq (%rax), %rcx
movq -0x70(%rbp), %r8
leaq 0xc86b(%rip), %rsi      # 0x1736b
movb $0x0, %al
callq 0x9190
jmp 0xab09
movq -0x10(%rbp), %rdi
callq 0x9670
leaq -0x60(%rbp), %rdi
callq 0x96b0
movb -0x5(%rbp), %al
movb %al, -0x5(%rbp)
movl -0x14(%rbp), %eax
movl %eax, -0x14(%rbp)
movl $0x2, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x80, %rsp
popq %rbp
retq
nopw (%rax,%rax)