// File: /workspace/github_c_makefile_star2_O0/buptlxb[P]xRay/disasm/instr_set/opcodes_A_M.c
// Function: callf_
void __bea_callspec__ callf_(PDISASM pMyDisasm)
{
    UInt32 MyNumber;
    UInt64 MyAddress;
    size_t i = 0;
    if (GV.Architecture == 64) {
        FailDecode(pMyDisasm);
    }
    else {
        (*pMyDisasm).Instruction.Category = GENERAL_PURPOSE_INSTRUCTION+CONTROL_TRANSFER;
        (*pMyDisasm).Instruction.BranchType = CallType;
        if (GV.SYNTAX_ == ATSyntax) {
            #ifndef BEA_LIGHT_DISASSEMBLY
               (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "lcall ");
            #endif
            #ifndef BEA_LIGHT_DISASSEMBLY
               (void) strcpy ((*pMyDisasm).Argument1.ArgMnemonic,"\x24");
            #endif
            i++;
        }
        else {
            #ifndef BEA_LIGHT_DISASSEMBLY
               (void) strcpy ((*pMyDisasm).Instruction.Mnemonic, "call far ");
            #endif
        }
        if (GV.OperandSize ==32) {
            if (!Security(7, pMyDisasm)) return;
            MyNumber = *((UInt16*)(UIntPtr) (GV.EIP_+5));
            #ifndef BEA_LIGHT_DISASSEMBLY
               i += CopyFormattedNumber(pMyDisasm, (char*) &(*pMyDisasm).Argument1.ArgMnemonic+i, "%.4X",(Int64) MyNumber);
            #endif
        }
        else {
            if (!Security(5, pMyDisasm)) return;
            MyNumber = *((UInt16*)(UIntPtr) (GV.EIP_+3));
            #ifndef BEA_LIGHT_DISASSEMBLY
               i += CopyFormattedNumber(pMyDisasm, (char*) &(*pMyDisasm).Argument1.ArgMnemonic+i, "%.4X",(Int64) MyNumber);
            #endif
        }
        if (GV.SYNTAX_ == ATSyntax) {
            #ifndef BEA_LIGHT_DISASSEMBLY
               (void) strcpy ((*pMyDisasm).Argument1.ArgMnemonic+i, " , \x24");
            #endif
            i+=4;
        }
        else {
            #ifndef BEA_LIGHT_DISASSEMBLY
               (void) strcpy ((*pMyDisasm).Argument1.ArgMnemonic+i, " : ");
            #endif
            i+=3;
        }
        MyAddress = MyNumber*16;
        MyNumber = *((UInt32*)(UIntPtr) (GV.EIP_+1));
        if (GV.OperandSize == 16) {
            MyNumber = MyNumber & 0xffff;
        }
        #ifndef BEA_LIGHT_DISASSEMBLY
           i += CopyFormattedNumber(pMyDisasm, (char*) &(*pMyDisasm).Argument1.ArgMnemonic+i, "%.8X",(Int64) MyNumber);
        #endif
        if (GV.OperandSize == 32) {
            GV.EIP_+=7;
        }
        else {
            GV.EIP_+=5;
        }
        (*pMyDisasm).Argument1.ArgType = CONSTANT_TYPE+ABSOLUTE_;
        (*pMyDisasm).Argument1.AccessMode = READ;
        (*pMyDisasm).Instruction.ImplicitModifiedRegs = GENERAL_REG+REG4;
        (*pMyDisasm).Instruction.AddrValue = MyAddress + MyNumber;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x40, 0x25c(%rax)
jne 0x20f1f
movq -0x8(%rbp), %rdi
callq 0x30050
jmp 0x21190
movq -0x8(%rbp), %rax
movl $0x10006, 0x60(%rax)    # imm = 0x10006
movq -0x8(%rbp), %rax
movl $0xc, 0x78(%rax)
movq -0x8(%rbp), %rax
cmpl $0x400, 0x24c(%rax)     # imm = 0x400
jne 0x20f82
movq -0x8(%rbp), %rdi
addq $0x60, %rdi
addq $0x8, %rdi
leaq 0x3055d(%rip), %rsi     # 0x514b5
callq 0x81c0
movq -0x8(%rbp), %rdi
addq $0x9c, %rdi
leaq 0x3055f(%rip), %rsi     # 0x514ce
callq 0x81c0
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
jmp 0x20f9a
movq -0x8(%rbp), %rdi
addq $0x60, %rdi
addq $0x8, %rdi
leaq 0x30527(%rip), %rsi     # 0x514bc
callq 0x81c0
movq -0x8(%rbp), %rax
cmpl $0x20, 0x20c(%rax)
jne 0x20fff
movq -0x8(%rbp), %rsi
movl $0x7, %edi
callq 0x4d340
cmpl $0x0, %eax
jne 0x20fbf
jmp 0x21190
movq -0x8(%rbp), %rax
movq 0x1f0(%rax), %rax
movzwl 0x5(%rax), %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rsi
addq $0x9c, %rsi
addq -0x20(%rbp), %rsi
movl -0xc(%rbp), %eax
movl %eax, %ecx
leaq 0x304d6(%rip), %rdx     # 0x514c6
callq 0x4d3a0
addq -0x20(%rbp), %rax
movq %rax, -0x20(%rbp)
jmp 0x21055
movq -0x8(%rbp), %rsi
movl $0x5, %edi
callq 0x4d340
cmpl $0x0, %eax
jne 0x21017
jmp 0x21190
movq -0x8(%rbp), %rax
movq 0x1f0(%rax), %rax
movzwl 0x3(%rax), %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rsi
addq $0x9c, %rsi
addq -0x20(%rbp), %rsi
movl -0xc(%rbp), %eax
movl %eax, %ecx
leaq 0x3047e(%rip), %rdx     # 0x514c6
callq 0x4d3a0
addq -0x20(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x400, 0x24c(%rax)     # imm = 0x400
jne 0x2108e
movq -0x8(%rbp), %rdi
addq $0x9c, %rdi
addq -0x20(%rbp), %rdi
leaq 0x30450(%rip), %rsi     # 0x514cb
callq 0x81c0
movq -0x20(%rbp), %rax
addq $0x4, %rax
movq %rax, -0x20(%rbp)
jmp 0x210b5
movq -0x8(%rbp), %rdi
addq $0x9c, %rdi
addq -0x20(%rbp), %rdi
leaq 0x3042c(%rip), %rsi     # 0x514d0
callq 0x81c0
movq -0x20(%rbp), %rax
addq $0x3, %rax
movq %rax, -0x20(%rbp)
movl -0xc(%rbp), %eax
shll $0x4, %eax
movl %eax, %eax
movq %rax, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq 0x1f0(%rax), %rax
movl 0x1(%rax), %eax
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x10, 0x20c(%rax)
jne 0x210ea
movl -0xc(%rbp), %eax
andl $0xffff, %eax           # imm = 0xFFFF
movl %eax, -0xc(%rbp)
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rsi
addq $0x9c, %rsi
addq -0x20(%rbp), %rsi
movl -0xc(%rbp), %eax
movl %eax, %ecx
leaq 0x303a7(%rip), %rdx     # 0x514b0
callq 0x4d3a0
addq -0x20(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x20, 0x20c(%rax)
jne 0x2113b
movq -0x8(%rbp), %rax
movq 0x1f0(%rax), %rcx
addq $0x7, %rcx
movq %rcx, 0x1f0(%rax)
jmp 0x21151
movq -0x8(%rbp), %rax
movq 0x1f0(%rax), %rcx
addq $0x5, %rcx
movq %rcx, 0x1f0(%rax)
movq -0x8(%rbp), %rax
movl $0x88000000, 0xdc(%rax) # imm = 0x88000000
movq -0x8(%rbp), %rax
movl $0x1, 0xe8(%rax)
movq -0x8(%rbp), %rax
movl $0x20010, 0x98(%rax)    # imm = 0x20010
movq -0x18(%rbp), %rcx
movl -0xc(%rbp), %eax
addq %rax, %rcx
movq -0x8(%rbp), %rax
movq %rcx, 0x88(%rax)
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)