raddbg -> raddbgi

This commit is contained in:
Ryan Fleury
2024-02-12 14:56:10 -08:00
parent 4b68967fbe
commit aa2a0948ba
55 changed files with 2620 additions and 2945 deletions
+8 -8
View File
@@ -22,16 +22,16 @@ int main(int argument_count, char **arguments)
uint8_t *data = (uint8_t *)MapViewOfFile(map, FILE_MAP_READ, 0, 0, data_size);
// parse raw data as raddbg
RADDBG_Parsed rdbg = {0};
RADDBG_ParseStatus parse_status = raddbg_parse(data, data_size, &rdbg);
RADDBGI_Parsed rdbg = {0};
RADDBGI_ParseStatus parse_status = raddbgi_parse(data, data_size, &rdbg);
// usage example: print out all procedure symbol names
#if 1
for(uint64_t procedure_idx = 0; procedure_idx < rdbg.procedure_count; procedure_idx += 1)
{
RADDBG_Procedure *procedure = &rdbg.procedures[procedure_idx];
RADDBGI_Procedure *procedure = &rdbg.procedures[procedure_idx];
uint64_t name_size = 0;
uint8_t *name = raddbg_string_from_idx(&rdbg, procedure->name_string_idx, &name_size);
uint8_t *name = raddbgi_string_from_idx(&rdbg, procedure->name_string_idx, &name_size);
printf("[%I64u] %.*s\n", procedure_idx, (int)name_size, name);
}
#endif
@@ -40,15 +40,15 @@ int main(int argument_count, char **arguments)
#if 0
for(uint64_t udt_idx = 0; udt_idx < rdbg.udt_count; udt_idx += 1)
{
RADDBG_UDT *udt = &rdbg.udts[udt_idx];
RADDBG_TypeNode *type = &rdbg.type_nodes[udt->self_type_idx];
RADDBGI_UDT *udt = &rdbg.udts[udt_idx];
RADDBGI_TypeNode *type = &rdbg.type_nodes[udt->self_type_idx];
uint64_t name_size = 0;
uint8_t *name = raddbg_string_from_idx(&rdbg, type->user_defined.name_string_idx, &name_size);
uint8_t *name = raddbgi_string_from_idx(&rdbg, type->user_defined.name_string_idx, &name_size);
printf("[%I64u] %.*s\n", udt_idx, (int)name_size, name);
}
#endif
// for getting more info, look at the `RADDBG_Parsed` structure. all data is
// for getting more info, look at the `RADDBGI_Parsed` structure. all data is
// represented as a bunch of flat plain-old-data tables. data which must
// reference other data uses indices into that other data's table. for
// example, given a `type_idx`, I will index into `rdbg.type_nodes`. given a