{"name": "kprobe_convert_to_perf_probe", "code": "__int64 __fastcall kprobe_convert_to_perf_probe ( const char * * @@a1@@ , __int64 @@a2@@ ) { int @@v3@@ ; __int64 @@v4@@ ; __int64 @@v5@@ ; __int64 @@v6@@ ; __int64 @@v7@@ ; unsigned __int64 @@v8@@ ; @@v8@@ = __readfsqword ( Number ) ; @@v3@@ = Number ; @@v5@@ = _find_kernel_function_by_name ( ( __int64 ) * @@a1@@ , ( __int64 ) & @@v4@@ ) ; if ( @@v5@@ ) { @@v6@@ = ( * ( __int64 ( __fastcall * * ) ( __int64 , const char * ) ) ( @@v4@@ + Number ) ) ( @@v4@@ , & @@a1@@ [ Number ] [ * ( _QWORD * ) ( @@v5@@ + Number ) ] ) ; eprintf ( Number L , String , * @@a1@@ , @@a1@@ [ Number ] , @@v6@@ ) ; @@v7@@ = debuginfo__new_online_kernel ( @@v6@@ ) ; if ( @@v7@@ ) { @@v3@@ = debuginfo__find_probe_point ( @@v7@@ , @@v6@@ , @@a2@@ ) ; debuginfo__delete ( @@v7@@ ) ; } else { eprintf ( Number L , String , @@v6@@ ) ; @@v3@@ = Number ; } } if ( @@v3@@ <= Number ) { eprintf ( Number L , String ) ; * ( _QWORD * ) ( @@a2@@ + Number ) = strdup ( * @@a1@@ ) ; if ( ! * ( _QWORD * ) ( @@a2@@ + Number ) ) return Number L ; * ( _QWORD * ) ( @@a2@@ + Number ) = @@a1@@ [ Number ] ; } * ( _BYTE * ) ( @@a2@@ + Number ) = * ( ( _BYTE * ) @@a1@@ + Number ) ; return Number L ; }", "source": [{"n": "a1", "t": {"T": 3, "t": "const char *"}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r64"}, {"n": "v7", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s16"}, {"n": "v6", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s24"}, {"n": "v5", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s32"}, {"n": "v4", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s40"}, {"n": "v3", "t": {"T": 1, "n": "int", "s": 4}, "location": "s44"}, {"n": "v8", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s8"}]}
{"name": "convert_to_perf_probe_event", "code": "__int64 __fastcall convert_to_perf_probe_event ( __int64 @@a1@@ , __int64 @@a2@@ ) { __int64 @@v3@@ ; __int64 @@v4@@ ; char * * v5 ; char * * v6 ; int @@i@@ ; int @@v8@@ ; char @@s@@ [ Number ] ; __int64 @@v10@@ ; __int64 @@v11@@ ; __int64 @@v12@@ ; __int64 @@v13@@ ; __int64 @@v14@@ ; __int64 @@v15@@ ; __int64 @@v16@@ ; unsigned __int64 @@v17@@ ; @@v17@@ = __readfsqword ( Number ) ; * ( _QWORD * ) @@s@@ = Number L ; @@v10@@ = Number L ; @@v11@@ = Number L ; @@v12@@ = Number L ; @@v13@@ = Number L ; @@v14@@ = Number L ; @@v15@@ = Number L ; @@v16@@ = Number L ; * ( _QWORD * ) @@a2@@ = strdup ( * ( const char * * ) @@a1@@ ) ; * ( _QWORD * ) ( @@a2@@ + Number ) = strdup ( * ( const char * * ) ( @@a1@@ + Number ) ) ; if ( ! * ( _QWORD * ) @@a2@@ || ! * ( _QWORD * ) ( @@a2@@ + Number ) ) return Number L ; @@v8@@ = kprobe_convert_to_perf_probe ( ( const char * * ) ( @@a1@@ + Number ) , @@a2@@ + Number ) ; if ( @@v8@@ < Number ) return ( unsigned int ) @@v8@@ ; * ( _DWORD * ) ( @@a2@@ + Number ) = * ( _DWORD * ) ( @@a1@@ + Number ) ; * ( _QWORD * ) ( @@a2@@ + Number ) = zalloc ( Number L * * ( int * ) ( @@a2@@ + Number ) ) ; if ( ! * ( _QWORD * ) ( @@a2@@ + Number ) ) return Number L ; for ( @@i@@ = Number ; @@i@@ < * ( _DWORD * ) ( @@a1@@ + Number ) && @@v8@@ >= Number ; ++ @@i@@ ) { if ( * ( _QWORD * ) ( Number L * @@i@@ + * ( _QWORD * ) ( @@a1@@ + Number ) ) ) { v5 = ( char * * ) ( * ( _QWORD * ) ( @@a2@@ + Number ) + Number L * @@i@@ ) ; * v5 = strdup ( * ( const char * * ) ( Number L * @@i@@ + * ( _QWORD * ) ( @@a1@@ + Number ) ) ) ; } else { @@v8@@ = ( unsigned int ) synthesize_probe_trace_arg ( ( __int64 * ) ( * ( _QWORD * ) ( @@a1@@ + Number ) + Number L * @@i@@ ) , @@s@@ , Number , * ( _QWORD * ) ( @@a1@@ + Number ) + Number L * @@i@@ , @@v3@@ , @@v4@@ ) ; v6 = ( char * * ) ( * ( _QWORD * ) ( @@a2@@ + Number ) + Number L * @@i@@ ) ; * v6 = strdup ( @@s@@ ) ; } if ( ! * ( _QWORD * ) ( Number L * @@i@@ + * ( _QWORD * ) ( @@a2@@ + Number ) ) && @@v8@@ >= Number ) @@v8@@ = Number ; } if ( @@v8@@ < Number ) clear_perf_probe_event ( @@a2@@ ) ; return ( unsigned int ) @@v8@@ ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r64"}, {"n": "v3", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r72"}, {"n": "v4", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r80"}, {"n": "v8", "t": {"T": 1, "n": "int", "s": 4}, "location": "s100"}, {"n": "i", "t": {"T": 1, "n": "int", "s": 4}, "location": "s104"}, {"n": "v17", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s24"}, {"n": "v16", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s40"}, {"n": "v15", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s48"}, {"n": "v14", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s56"}, {"n": "v13", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s64"}, {"n": "v12", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s72"}, {"n": "v11", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s80"}, {"n": "v10", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s88"}, {"n": "s", "t": {"T": 2, "n": 8, "s": 1, "t": "char"}, "location": "s96"}]}