{"name": "dso__load_sym", "code": "__int64 __fastcall dso__load_sym ( char * @@a1@@ , __int64 @@a2@@ , const char * @@a3@@ , unsigned int @@a4@@ , unsigned int ( __fastcall * @@a5@@ ) ( __int64 , char * ) , int @@a6@@ , int @@a7@@ ) { __int64 v7 ; bool v8 ; unsigned int @@v14@@ ; unsigned int @@v15@@ ; int @@v16@@ ; unsigned int @@v17@@ ; _BOOL4 @@v18@@ ; __int64 @@v19@@ ; __int64 @@v20@@ ; char * @@v21@@ ; _QWORD * @@v22@@ ; __int64 @@v23@@ ; __int64 @@v24@@ ; char * @@s1@@ ; void * @@ptr@@ ; __int64 @@v27@@ ; __int64 @@v28@@ ; __int64 @@v29@@ ; __int64 @@v30@@ ; _QWORD * @@v31@@ ; __int64 @@v32@@ ; _QWORD * @@v33@@ ; __int64 * @@v34@@ ; char * @@v35@@ ; char * @@v36@@ ; __int64 @@s@@ [ Number ] ; unsigned int @@v38@@ [ Number ] ; __int64 @@v39@@ ; __int64 @@v40@@ ; unsigned __int64 @@v41@@ ; unsigned int @@v42@@ ; unsigned __int64 @@v43@@ ; unsigned int @@v44@@ [ Number ] ; char @@v45@@ [ Number ] ; __int16 @@v46@@ ; __int16 @@v47@@ ; unsigned __int16 @@v48@@ ; char @@v49@@ [ Number ] ; unsigned __int64 @@v50@@ ; @@v50@@ = __readfsqword ( Number ) ; if ( * ( ( _DWORD * ) @@a1@@ + Number ) ) v7 = map__kmap ( @@a2@@ ) ; else v7 = Number L ; @@v28@@ = v7 ; @@v20@@ = @@a2@@ ; @@v21@@ = @@a1@@ ; @@v14@@ = Number ; @@v22@@ = Number L ; @@v16@@ = Number ; @@v19@@ = Number L ; @@v29@@ = elf_begin ( @@a4@@ , Number L , Number L ) ; if ( @@v29@@ ) { if ( gelf_getehdr ( @@v29@@ , @@v45@@ ) ) { if ( ( @@a1@@ [ Number ] & Number ) == Number || ( unsigned int ) elf_read_build_id ( @@v29@@ , @@v49@@ , Number L ) == Number && ( unsigned __int8 ) dso__build_id_equal ( @@a1@@ , @@v49@@ ) == Number ) { @@v23@@ = elf_section_by_name ( @@v29@@ , ( __int64 ) @@v45@@ , @@v38@@ , String , Number L ) ; if ( @@v23@@ || ! @@a7@@ && ( @@v23@@ = elf_section_by_name ( @@v29@@ , ( __int64 ) @@v45@@ , @@v38@@ , String , Number L ) ) != Number ) { @@v24@@ = elf_section_by_name ( @@v29@@ , ( __int64 ) @@v45@@ , @@v44@@ , String , & @@v19@@ ) ; if ( @@v44@@ [ Number ] != Number ) @@v24@@ = Number L ; if ( @@v24@@ ) @@v22@@ = ( _QWORD * ) elf_rawdata ( @@v24@@ , Number L ) ; @@v30@@ = elf_getdata ( @@v23@@ , Number L ) ; if ( @@v30@@ ) { @@v23@@ = elf_getscn ( @@v29@@ , @@v42@@ ) ; if ( @@v23@@ ) { @@v31@@ = ( _QWORD * ) elf_getdata ( @@v23@@ , Number L ) ; if ( @@v31@@ ) { @@v32@@ = elf_getscn ( @@v29@@ , @@v48@@ ) ; if ( @@v32@@ ) { @@v33@@ = ( _QWORD * ) elf_getdata ( @@v32@@ , Number L ) ; if ( @@v33@@ ) { @@v17@@ = @@v41@@ / @@v43@@ ; memset ( @@s@@ , Number , Number ) ; if ( * ( ( _DWORD * ) @@a1@@ + Number ) ) { @@a1@@ [ Number ] &= Number ; } else { v8 = @@v46@@ == Number || elf_section_by_name ( @@v29@@ , ( __int64 ) @@v45@@ , @@v38@@ , String , Number L ) ; @@a1@@ [ Number ] = v8 | @@a1@@ [ Number ] & Number ; } @@v15@@ = Number ; gelf_getsym ( @@v30@@ , Number L , @@s@@ ) ; while ( @@v15@@ < @@v17@@ ) { @@s1@@ = ( char * ) elf_sym__name ( ( unsigned int * ) @@s@@ , @@v31@@ ) ; @@ptr@@ = Number L ; @@v18@@ = elf_sym__is_label ( ( __int64 ) @@s@@ ) ; if ( @@v28@@ && * ( _QWORD * ) @@v28@@ && * * ( _QWORD * * ) @@v28@@ && ! strcmp ( @@s1@@ , * * ( const char * * * ) @@v28@@ ) ) * ( _QWORD * ) ( * ( _QWORD * ) @@v28@@ + Number L ) = @@s@@ [ Number ] ; if ( ( @@v18@@ || elf_sym__is_a ( ( __int64 ) @@s@@ , * ( unsigned __int8 * ) ( @@a2@@ + Number ) ) ) && ( @@v47@@ != Number || strcmp ( @@s1@@ , String ) && strcmp ( @@s1@@ , String ) && strcmp ( @@s1@@ , String ) ) ) { if ( @@v24@@ && HIWORD ( @@s@@ [ Number ] ) == @@v19@@ ) { @@v34@@ = ( __int64 * ) ( * @@v22@@ + LODWORD ( @@s@@ [ Number ] ) - @@v44@@ [ Number ] ) ; @@s@@ [ Number ] = * @@v34@@ ; HIWORD ( @@s@@ [ Number ] ) = elf_addr_to_index ( @@v29@@ , @@s@@ [ Number ] ) ; } @@v23@@ = elf_getscn ( @@v29@@ , HIWORD ( @@s@@ [ Number ] ) ) ; if ( ! @@v23@@ ) goto LABEL_80 ; gelf_getshdr ( @@v23@@ , @@v38@@ ) ; if ( ! @@v18@@ || elf_sec__is_a ( @@v38@@ , @@v33@@ , * ( unsigned __int8 * ) ( @@a2@@ + Number ) ) ) { @@v35@@ = ( char * ) elf_sec__name ( @@v38@@ , @@v33@@ ) ; if ( @@v47@@ == Number && ! * ( _BYTE * ) ( @@a2@@ + Number ) && ( @@s@@ [ Number ] & Number ) != Number ) -- @@s@@ [ Number ] ; if ( * ( ( _DWORD * ) @@a1@@ + Number ) || @@a6@@ ) { if ( strcmp ( @@v35@@ , ( const char * ) ( * ( ( unsigned __int16 * ) @@a1@@ + Number ) + * ( ( _QWORD * ) @@v21@@ + Number ) ) ) ) { if ( ! strcmp ( @@v35@@ , String ) ) { @@v20@@ = @@a2@@ ; @@v21@@ = @@a1@@ ; } else { snprintf ( @@v49@@ , Number , String , * ( ( const char * * ) @@a1@@ + Number ) , @@v35@@ ) ; @@v20@@ = map_groups__find_by_name ( * ( _QWORD * ) ( @@v28@@ + Number ) , * ( unsigned __int8 * ) ( @@a2@@ + Number ) , @@v49@@ ) ; if ( @@v20@@ ) { @@v21@@ = * ( char * * ) ( @@v20@@ + Number ) ; } else { @@v27@@ = @@s@@ [ Number ] ; if ( @@a6@@ ) @@v27@@ += * ( _QWORD * ) ( @@a2@@ + Number ) + @@v40@@ ; @@v21@@ = dso__new ( @@v49@@ ) ; if ( ! @@v21@@ ) goto LABEL_80 ; * ( ( _DWORD * ) @@v21@@ + Number ) = * ( ( _DWORD * ) @@a1@@ + Number ) ; * ( ( _QWORD * ) @@v21@@ + Number ) = * ( ( _QWORD * ) @@a1@@ + Number ) ; * ( ( _WORD * ) @@v21@@ + Number ) = * ( ( _WORD * ) @@a1@@ + Number ) ; @@v20@@ = map__new2 ( @@v27@@ , @@v21@@ , * ( unsigned __int8 * ) ( @@a2@@ + Number ) ) ; if ( ! @@v20@@ ) { dso__delete ( ( __int64 ) @@v21@@ ) ; goto LABEL_80 ; } * ( _QWORD * ) ( @@v20@@ + Number ) = identity__map_ip ; * ( _QWORD * ) ( @@v20@@ + Number ) = identity__map_ip ; @@v21@@ [ Number ] = @@a1@@ [ Number ] ; map_groups__insert ( * ( _QWORD * ) ( @@v28@@ + Number ) , @@v20@@ ) ; dsos__add ( @@a1@@ , @@v21@@ ) ; dso__set_loaded ( ( __int64 ) @@v21@@ , * ( _BYTE * ) ( @@a2@@ + Number ) ) ; } } } } else { if ( ( @@v21@@ [ Number ] & Number ) != Number ) { eprintf ( Number L , String , String , @@s@@ [ Number ] , @@v39@@ , @@v40@@ ) ; @@s@@ [ Number ] += @@v40@@ - @@v39@@ ; } @@ptr@@ = ( void * ) bfd_demangle ( Number L , @@s1@@ , Number L ) ; if ( @@ptr@@ ) @@s1@@ = ( char * ) @@ptr@@ ; } @@v36@@ = symbol__new ( @@s@@ [ Number ] , @@s@@ [ Number ] , BYTE4 ( @@s@@ [ Number ] ) >> Number , @@s1@@ ) ; free ( @@ptr@@ ) ; if ( ! @@v36@@ ) goto LABEL_80 ; if ( @@a5@@ && @@a5@@ ( @@v20@@ , @@v36@@ ) ) { symbol__delete ( ( __int64 ) @@v36@@ ) ; } else { symbols__insert ( ( __int64 * ) & @@v21@@ [ Number * * ( unsigned __int8 * ) ( @@v20@@ + Number ) + Number ] , @@v36@@ ) ; ++ @@v16@@ ; } } } gelf_getsym ( @@v30@@ , ++ @@v15@@ , @@s@@ ) ; } if ( @@v16@@ > Number ) { symbols__fixup_end ( ( __int64 ) & @@a1@@ [ Number * * ( unsigned __int8 * ) ( @@a2@@ + Number ) + Number ] ) ; if ( @@v28@@ ) _map_groups__fixup_end ( * ( _QWORD * ) ( @@v28@@ + Number ) , * ( unsigned __int8 * ) ( @@a2@@ + Number ) ) ; } @@v14@@ = @@v16@@ ; } } } } } } } } else { eprintf ( Number L , String , String ) ; } LABEL_80 : elf_end ( @@v29@@ ) ; } else { eprintf ( Number L , String , String , @@a3@@ ) ; } return @@v14@@ ; }", "source": [{"n": "a3", "t": {"T": 3, "t": "const char"}, "location": "r16"}, {"n": "a4", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "r24"}, {"n": "a1", "t": {"T": 3, "t": "char"}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r64"}, {"n": "a5", "t": {"T": 9, "n": "unsigned int (__fastcall *)(__int64, char *)"}, "location": "r72"}, {"n": "a6", "t": {"T": 1, "n": "int", "s": 4}, "location": "r80"}, {"n": "a7", "t": {"T": 1, "n": "int", "s": 4}, "location": "s-16"}, {"n": "v49", "t": {"T": 2, "n": 4104, "s": 1, "t": "char"}, "location": "s4112"}, {"n": "v48", "t": {"T": 1, "n": "unsigned __int16", "s": 2}, "location": "s4114"}, {"n": "v47", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "s4158"}, {"n": "v46", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "s4160"}, {"n": "v45", "t": {"T": 2, "n": 16, "s": 1, "t": "char"}, "location": "s4176"}, {"n": "v44", "t": {"T": 2, "n": 16, "s": 4, "t": "unsigned int"}, "location": "s4240"}, {"n": "v43", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s4248"}, {"n": "v42", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s4264"}, {"n": "v41", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s4272"}, {"n": "v40", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s4280"}, {"n": "v39", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s4288"}, {"n": "v38", "t": {"T": 2, "n": 4, "s": 4, "t": "unsigned int"}, "location": "s4304"}, {"n": "s", "t": {"T": 2, "n": 4, "s": 8, "t": "__int64"}, "location": "s4336"}, {"n": "v36", "t": {"T": 3, "t": "char"}, "location": "s4344"}, {"n": "v35", "t": {"T": 3, "t": "char"}, "location": "s4352"}, {"n": "v34", "t": {"T": 3, "t": "__int64"}, "location": "s4360"}, {"n": "v33", "t": {"T": 3, "t": "_QWORD"}, "location": "s4368"}, {"n": "v32", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s4376"}, {"n": "v31", "t": {"T": 3, "t": "_QWORD"}, "location": "s4384"}, {"n": "v30", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s4392"}, {"n": "v29", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s4400"}, {"n": "v28", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s4408"}, {"n": "v27", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s4416"}, {"n": "ptr", "t": {"T": 3, "t": "void"}, "location": "s4424"}, {"n": "s1", "t": {"T": 3, "t": "char"}, "location": "s4432"}, {"n": "v24", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s4440"}, {"n": "v23", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s4448"}, {"n": "v22", "t": {"T": 3, "t": "_QWORD"}, "location": "s4456"}, {"n": "v21", "t": {"T": 3, "t": "char"}, "location": "s4464"}, {"n": "v20", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s4472"}, {"n": "v19", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s4480"}, {"n": "v18", "t": {"T": 1, "n": "_BOOL4", "s": 4}, "location": "s4488"}, {"n": "v17", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s4492"}, {"n": "v16", "t": {"T": 1, "n": "int", "s": 4}, "location": "s4496"}, {"n": "v15", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s4500"}, {"n": "v14", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s4504"}, {"n": "v50", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s8"}]}