============================== Sample 1 ============================== ASM: ;************************************************************************************************************************************************************ ;* FUNCTION * ;************************************************************************************************************************************************************ ;undefined gp_arrow_button_constructed() PUSH RBP MOV RBP,RDI MOV RDI,qword ptr [.bss:gp_arrow_button_parent_class] ;=?? MOV ESI,0x50 CALL .plt:::g_type_check_class_cast ;undefined g_type_check_class_cast() MOV RDI,RBP CALL qword ptr [RAX + 0x48] CALL .plt:::gtk_widget_get_type ;undefined gtk_widget_get_type() MOV RDI,RBP MOV RSI,RAX CALL .plt:::g_type_check_instance_cast ;undefined g_type_check_instance_cast() MOV RDI,RAX CALL .plt:::gtk_widget_get_accessible ;undefined gtk_widget_get_accessible() LEA RSI,[.rodata:s_Hide_Panel_00138771] ;= "Hide Panel" XOR EDI,EDI MOV EDX,0x5 MOV RBP,RAX CALL .plt:::dcgettext ;undefined dcgettext() MOV RDI,RBP POP RBP MOV RSI,RAX JMP .plt:::atk_object_set_name ;undefined atk_object_set_name() ?? 66h f Actual src: static void gp_arrow_button_constructed (GObject *object) { GtkWidget *widget; AtkObject *atk; G_OBJECT_CLASS (gp_arrow_button_parent_class)->constructed (object); widget = GTK_WIDGET (object); atk = gtk_widget_get_accessible (widget); atk_object_set_name (atk, _("Hide Panel")); } Predicted src: static void cc_button_button_dispose (GObject *object) { GtkButton *button = GTK_BUTTON (object); GTK_WIDGET_CLASS (cc_button_parent_class)->dispose (object); } ============================== Sample 2 ============================== ASM: ;************************************************************************************************************************************************************ ;* FUNCTION * ;************************************************************************************************************************************************************ ;undefined __glXDisp_VertexAttrib4Nubv() PUSH RBX MOV RBX,RDI LEA RDI,[.rodata:s_glVertexAttrib4Nubv_0030ab88] ;= "glVertexAttrib4Nubv" CALL __glGetProcAddress ;undefined __glGetProcAddress() MOV EDI,dword ptr [RBX] LEA RSI,[RBX + 0x4] POP RBX JMP RAX ?? 0Fh Actual src: void __glXDisp_VertexAttrib4Nubv(GLbyte * pc) { PFNGLVERTEXATTRIB4NUBVPROC VertexAttrib4Nubv = __glGetProcAddress("glVertexAttrib4Nubv"); VertexAttrib4Nubv(*(GLuint *) (pc + 0), (const GLubyte *) (pc + 4)); } Predicted src: void __glXDispSwap_String3fv(GLbyte * pc) { glString3fv((GLenum) bswap_ENUM(pc + 0), (GLenum) bswap_ENUM(pc + 0)); } ============================== Sample 3 ============================== ASM: ;************************************************************************************************************************************************************ ;* FUNCTION * ;************************************************************************************************************************************************************ ;undefined op_edc0_22_ff() PUSH RBX MOV EBX,EDI MOV EDI,0x2 MOV dword ptr [.bss:OpcodeFamily],0x5d AND EBX,0x7 MOV dword ptr [.bss:CurrentInstrCycles],0x8 CALL get_word_030_prefetch ;undefined get_word_030_prefetch() MOV ESI,EAX TEST AH,0x8 JZ LAB_009bbe18 SAR AX,0x6 LEA R9,[.bss:regs] AND EAX,0x7 MOV EDX,dword ptr [R9 + RAX*0x4]=>.bss:regs MOV ECX,EDX AND ECX,0x1f LAB_009bbd46: TEST SIL,0x20 JZ LAB_009bbe00 MOV EAX,ESI AND EAX,0x7 MOV R8D,dword ptr [R9 + RAX*0x4]=>.bss:regs SUB R8D,0x1 AND R8D,0x1f ADD R8D,0x1 LAB_009bbd65: MOV EAX,dword ptr [R9 + RBX*0x4]=>.bss:regs ROL EAX,CL MOV ECX,0x20 MOV EDI,EAX SHR EAX,0x1f SUB ECX,R8D SHL EAX,0xf SHR EDI,CL MOV ECX,EAX MOV EAX,dword ptr [.bss:regflags] AND AH,0x3f OR EAX,ECX XOR ECX,ECX TEST EDI,EDI SETZ CL SHL ECX,0xe OR EAX,ECX LEA ECX,[R8 + -0x1] AND EAX,0xfffffefe MOV dword ptr [.bss:regflags],EAX MOV EAX,0x1 SHL EAX,CL TEST EAX,EAX JNZ LAB_009bbdbf JMP LAB_009bbdc3 ?? 66h f ?? 0Fh ?? 1Fh ?? 44h D ?? 00h ?? 00h LAB_009bbdb8: ADD EDX,0x1 SHR EAX,1 JZ LAB_009bbdc3 LAB_009bbdbf: TEST EDI,EAX JZ LAB_009bbdb8 LAB_009bbdc3: SAR SI,0xc MOV EAX,dword ptr [.bss:regs[188]] MOV EDI,0x4 AND ESI,0x7 MOV dword ptr [R9 + RSI*0x4]=>.bss:regs,EDX MOV dword ptr [.bss:regs[184]],EAX CALL get_word_030_prefetch ;undefined get_word_030_prefetch() ADD dword ptr [.bss:regs[64]],0x4 POP RBX MOV word ptr [.bss:regs[104]],AX MOV EAX,0x1000 RET ?? 0Fh ?? 1Fh ?? 80h ?? 00h ?? 00h ?? 00h ?? 00h LAB_009bbe00: LEA R8D,[RSI + 0x1f] AND R8D,0x1f ADD R8D,0x1 JMP LAB_009bbd65 ?? 0Fh ?? 1Fh ?? 80h ?? 00h ?? 00h ?? 00h ?? 00h LAB_009bbe18: MOV ECX,EAX LEA R9,[.bss:regs] SAR CX,0x6 AND ECX,0x1f MOV EDX,ECX JMP LAB_009bbd46 ?? 90h Actual src: uae_u32 REGPARAM2 op_edc0_22_ff(uae_u32 opcode) { int count_cycles = 0; uae_u32 real_opcode = opcode; uae_u32 dstreg = real_opcode & 7; OpcodeFamily = 93; CurrentInstrCycles = 8; uae_s16 extra = get_word_030_prefetch(2); uae_u32 bdata[2]; uae_s32 offset = extra & 0x800? m68k_dreg(regs, (extra >> 6) & 7) : (extra >> 6) & 0x1f; int width = (((extra & 0x20? m68k_dreg(regs, extra & 7) : extra) - 1) & 0x1f) + 1; uae_u32 offset2 = offset; uae_u32 tmp = m68k_dreg(regs, dstreg); offset &= 0x1f; tmp = (tmp << offset) | (tmp >> (32 - offset)); bdata[0] = tmp & ((1 << (32 - width)) - 1); SET_ALWAYS_NFLG(((uae_s32)tmp) < 0? 1 : 0); tmp >>= (32 - width); SET_ZFLG(tmp == 0); SET_VFLG(0); SET_CFLG(0); { uae_u32 mask = 1 << (width - 1); while (mask) { if (tmp & mask) break; mask >>= 1; offset2++; }} m68k_dreg(regs, (extra >> 12) & 7) = offset2; ipl_fetch(); regs.irc = get_word_030_prefetch(4); m68k_incpci(4); return (1 * 4 * CYCLE_UNIT / 2 + count_cycles) * 4; } Predicted src: uae_u32 REGPARAM2 op_31f0_31_ff(uae_u32 opcode) { int count_cycles = 0; uae_u32 real_opcode = opcode; uae_u32 srcreg = (real_opcode & 7); uae_u32 dstreg = (real_opcode >> 9) & 7; OpcodeFamily = 30; CurrentInstrCycles = 12; uaecptr srca; m68k_incpci(2); srca = x_get_disp_ea_020(m68k_areg(regs, srcreg), 0); uae_s8 src = x_get_byte(srca); uae_s8 dst = m68k_dreg(regs, dstreg); uae_u32 newv = ((uae_u8)(dst)) - ((uae_u8)(src)); int flgs = ((uae_s8)(src)) < 0; int flgo = ((uae_s8)(dst)) < 0; int flgn = ((uae_s8)(newv)) < 0; SET_ZFLG(((uae_s8)(newv)) == 0); SET_VFLG((flgs ^ flgo) & (flgn ^ flgo)); SET_CFLG(((uae_u8)(src)) > ((uae_u8)(dst))); COPY_CARRY(); SET_NFLG(flgn!= 0); ipl_fetch(); regs.irc = get_word_030_prefetch(0); m68k_dreg(regs, dstreg) = (m68k_dreg(regs, dstreg) & ~0xff) | ((newv) & 0xff); return (1 * 4 * CYCLE_UNIT / 2 + count_cycles) * 4; } ============================== Sample 4 ============================== ASM: ;************************************************************************************************************************************************************ ;* ClpSolve::setSpecialOption(int, int, int) * ;************************************************************************************************************************************************************ ;undefined setSpecialOption(ClpSolve * this, int param_1, int param_2, int param_3) ;this ClpSolve * RDI ;param_1 int ESI ;param_2 int EDX ;param_3 int ECX MOVSXD param_1,param_1 MOV dword ptr [this + param_1*0x4 + 0xc],param_2 MOV dword ptr [this + param_1*0x4 + 0x28],param_3 RET ?? 0Fh Actual src: void ClpSolve::setSpecialOption(int which, int value, int extraInfo) { options_[which] = value; extraInfo_[which] = extraInfo; } Predicted src: void SOptionOption::setOption(int value, int value) { value = value; } ============================== Sample 5 ============================== ASM: ;************************************************************************************************************************************************************ ;* FUNCTION * ;************************************************************************************************************************************************************ ;undefined lex_get_error(undefined param_1, undefined param_2, undefined param_3, undefined param_4, undefined param_5, undefined param_6, undefined1 param_7) ;param_1 undefined DIL ;param_2 undefined SIL ;param_3 undefined DL ;param_4 undefined CL ;param_5 undefined R8B ;param_6 undefined R9B ;param_7 undefined1 8 ;local_18 undefined1[16] -18 ;local_28 undefined1[16] -28 ;local_38 undefined1[16] -38 ;local_48 undefined1[16] -48 ;local_58 undefined1[16] -58 ;local_68 undefined1[16] -68 ;local_78 undefined1[16] -78 ;local_88 undefined1[16] -88 ;local_90 undefined8 -90 ;local_98 undefined8 -98 ;local_a0 undefined8 -a0 ;local_a8 undefined8 -a8 ;local_b8 undefined1 -b8 ;local_c0 undefined8 -c0 ;local_c8 undefined8 -c8 ;local_d0 undefined8 -d0 ;local_d4 undefined4 -d4 ;local_d8 undefined4 -d8 PUSH RBP MOV R10,param_2 MOV RBP,param_1 SUB RSP,0xd0 MOV qword ptr [RSP + local_a8+0xd8],param_3 MOV qword ptr [RSP + local_a0+0xd8],param_4 MOV qword ptr [RSP + local_98+0xd8],param_5 MOV qword ptr [RSP + local_90+0xd8],param_6 TEST AL,AL JZ LAB_0014aefd MOVAPS xmmword ptr [RSP + local_88[0]+0xd8],XMM0 MOVAPS xmmword ptr [RSP + local_78[0]+0xd8],XMM1 MOVAPS xmmword ptr [RSP + local_68[0]+0xd8],XMM2 MOVAPS xmmword ptr [RSP + local_58[0]+0xd8],XMM3 MOVAPS xmmword ptr [RSP + local_48[0]+0xd8],XMM4 MOVAPS xmmword ptr [RSP + local_38[0]+0xd8],XMM5 MOVAPS xmmword ptr [RSP + local_28[0]+0xd8],XMM6 MOVAPS xmmword ptr [RSP + local_18[0]+0xd8],XMM7 LAB_0014aefd: MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RSP + local_c0+0xd8],RAX XOR EAX,EAX LEA RAX=>param_7,[RSP + 0xe0] MOV param_1,RBP MOV param_5,RSP MOV qword ptr [RSP + local_d0+0xd8],RAX LEA RAX=>local_b8,[RSP + 0x20] MOV param_4,R10 MOV qword ptr [RSP + local_c8+0xd8],RAX MOV RAX,qword ptr [RBP + 0x68] SUB RAX,qword ptr [RBP + 0x70] MOV dword ptr [RSP]=>local_d8,0x10 LEA param_2,[RAX + -0x1] MOV dword ptr [RSP + local_d4+0xd8],0x30 MOV param_3,param_2 CALL lex_source_error_valist ;undefined lex_source_error_valist() MOV param_1,RBP CALL lex_source_pop_front ;undefined lex_source_pop_front() MOV RAX,qword ptr [RSP + local_c0+0xd8] SUB RAX,qword ptr FS:[0x28] JNZ LAB_0014af6f ADD RSP,0xd0 POP RBP RET LAB_0014af6f: CALL .plt:::__stack_chk_fail ;undefined __stack_chk_fail() NOP dword ptr CS:[RAX + RAX*0x1] Actual src: static void PRINTF_FORMAT (2, 3) lex_get_error (struct lex_source *src, const char *format,...) { va_list args; int n; va_start (args, format); n = deque_count (&src->deque) - 1; lex_source_error_valist (src, n, n, format, args); lex_source_pop_front (src); va_end (args); } Predicted src: static void source_source_source_source_error (const char *format,...) { va_list ap; va_start (ap, format); va_start (ap, ap); source_source_error (format, ap); }