diff --git a/src/df/core/df_core.c b/src/df/core/df_core.c index f8659b66..f3b2890c 100644 --- a/src/df/core/df_core.c +++ b/src/df/core/df_core.c @@ -6972,7 +6972,8 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt) } //- rjf: clear members cache - if(df_state->member_cache_reggen_idx != new_reg_gen && !df_ctrl_targets_running()) + if(df_state->member_cache_reggen_idx != new_reg_gen && + !df_ctrl_targets_running()) { df_state->member_cache_gen += 1; DF_RunLocalsCache *cache = &df_state->member_caches[df_state->member_cache_gen%ArrayCount(df_state->member_caches)]; diff --git a/src/lib_raddbgi_make/raddbgi_make.c b/src/lib_raddbgi_make/raddbgi_make.c index 7f15dcbe..11b41166 100644 --- a/src/lib_raddbgi_make/raddbgi_make.c +++ b/src/lib_raddbgi_make/raddbgi_make.c @@ -2723,6 +2723,7 @@ rdim_bake_type_node_section_list_from_params(RDIM_Arena *arena, RDIM_BakeStringM //- rjf: fill shared type node info dst->kind = src->kind; + dst->flags = (RDI_U16)src->flags; // TODO(rjf): @u32_to_u16 dst->byte_size = src->byte_size; //- rjf: fill built-in-only type node info diff --git a/src/raddbgi_breakpad_from_pdb/raddbgi_breakpad_from_pdb_main.c b/src/raddbgi_breakpad_from_pdb/raddbgi_breakpad_from_pdb_main.c index 491baf79..23b593d5 100644 --- a/src/raddbgi_breakpad_from_pdb/raddbgi_breakpad_from_pdb_main.c +++ b/src/raddbgi_breakpad_from_pdb/raddbgi_breakpad_from_pdb_main.c @@ -167,11 +167,14 @@ internal TS_TASK_FUNCTION_DEF(p2b_dump_proc_chunk_task__entry_point) RDI_Line *line = &line_info.lines[line_info_idx]; U64 line_voff_min = line_info.voffs[line_info_idx]; U64 line_voff_opl = line_info.voffs[line_info_idx+1]; - str8_list_pushf(arena, out, "%I64x %I64x %I64u %I64u\n", - line_voff_min, - line_voff_opl-line_voff_min, - (U64)line->line_num, - (U64)line->file_idx); + if(line->file_idx != 0) + { + str8_list_pushf(arena, out, "%I64x %I64x %I64u %I64u\n", + line_voff_min, + line_voff_opl-line_voff_min, + (U64)line->line_num, + (U64)line->file_idx); + } last_voff = voff; voff = line_voff_opl; } diff --git a/src/raddbgi_from_pdb/raddbgi_from_pdb.c b/src/raddbgi_from_pdb/raddbgi_from_pdb.c index 86b9cf99..e8239e84 100644 --- a/src/raddbgi_from_pdb/raddbgi_from_pdb.c +++ b/src/raddbgi_from_pdb/raddbgi_from_pdb.c @@ -1257,7 +1257,7 @@ internal TS_TASK_FUNCTION_DEF(p2r_udt_convert_task__entry_point) CV_LeafKind field_kind = *(CV_LeafKind *)read_ptr; U64 field_leaf_header_size = cv_header_struct_size_from_leaf_kind(field_kind); U8 *field_leaf_first = read_ptr+2; - U8 *field_leaf_opl = field_leaf_first+range->hdr.size-2; + U8 *field_leaf_opl = field_list_opl; next_read_ptr = field_leaf_opl; // rjf: skip out-of-bounds fields @@ -1282,6 +1282,9 @@ internal TS_TASK_FUNCTION_DEF(p2r_udt_convert_task__entry_point) CV_LeafIndex *lf = (CV_LeafIndex *)field_leaf_first; CV_TypeId new_itype = lf->itype; + // rjf: bump next read pointer past header + next_read_ptr = (U8 *)(lf+1); + // rjf: determine if index itype is new B32 is_new = 1; for(FieldListTask *t = fl_done_stack; t != 0; t = t->next) @@ -1573,6 +1576,9 @@ internal TS_TASK_FUNCTION_DEF(p2r_udt_convert_task__entry_point) U8 *num2_ptr = num1_ptr + num1.encoded_size; CV_NumericParsed num2 = cv_numeric_from_data_range(num2_ptr, field_leaf_opl); + // rjf: bump next read pointer past header + next_read_ptr = (U8 *)(lf+1); + // rjf: emit member RDIM_UDTMember *mem = rdim_udt_push_member(arena, udts, dst_udt); mem->kind = RDI_MemberKind_VirtualBase; @@ -1583,6 +1589,10 @@ internal TS_TASK_FUNCTION_DEF(p2r_udt_convert_task__entry_point) case CV_LeafKind_VFUNCTAB: { CV_LeafVFuncTab *lf = (CV_LeafVFuncTab *)field_leaf_first; + + // rjf: bump next read pointer past header + next_read_ptr = (U8 *)(lf+1); + // NOTE(rjf): currently no-op this case (void)lf; }break; @@ -1970,7 +1980,7 @@ internal TS_TASK_FUNCTION_DEF(p2r_symbol_stream_convert_task__entry_point) if(container_name_opl > 2) { String8 container_name = str8(name.str, container_name_opl - 2); - CV_TypeId cv_type_id = pdb_tpi_first_itype_from_name(in->tpi_hash, in->tpi_leaf, name, 0); + CV_TypeId cv_type_id = pdb_tpi_first_itype_from_name(in->tpi_hash, in->tpi_leaf, container_name, 0); container_type = p2r_type_ptr_from_itype(cv_type_id); } @@ -2007,7 +2017,7 @@ internal TS_TASK_FUNCTION_DEF(p2r_symbol_stream_convert_task__entry_point) if(container_name_opl > 2) { String8 container_name = str8(name.str, container_name_opl - 2); - CV_TypeId cv_type_id = pdb_tpi_first_itype_from_name(in->tpi_hash, in->tpi_leaf, name, 0); + CV_TypeId cv_type_id = pdb_tpi_first_itype_from_name(in->tpi_hash, in->tpi_leaf, container_name, 0); container_type = p2r_type_ptr_from_itype(cv_type_id); } @@ -2182,7 +2192,7 @@ internal TS_TASK_FUNCTION_DEF(p2r_symbol_stream_convert_task__entry_point) if(container_name_opl > 2) { String8 container_name = str8(name.str, container_name_opl - 2); - CV_TypeId cv_type_id = pdb_tpi_first_itype_from_name(in->tpi_hash, in->tpi_leaf, name, 0); + CV_TypeId cv_type_id = pdb_tpi_first_itype_from_name(in->tpi_hash, in->tpi_leaf, container_name, 0); container_type = p2r_type_ptr_from_itype(cv_type_id); } @@ -3026,11 +3036,18 @@ p2r_convert(Arena *arena, P2R_User2Convert *in) if(lf->flags & CV_ModifierFlag_Volatile) {flags |= RDI_TypeModifierFlag_Volatile;} // rjf: fill type - dst_type = rdim_type_chunk_list_push(arena, &all_types, (U64)itype_opl); - dst_type->kind = RDI_TypeKind_Modifier; - dst_type->flags = flags; - dst_type->direct_type = p2r_type_ptr_from_itype(lf->itype); - dst_type->byte_size = dst_type->direct_type ? dst_type->direct_type->byte_size : 0; + if(flags == 0) + { + dst_type = p2r_type_ptr_from_itype(lf->itype); + } + else + { + dst_type = rdim_type_chunk_list_push(arena, &all_types, (U64)itype_opl); + dst_type->kind = RDI_TypeKind_Modifier; + dst_type->flags = flags; + dst_type->direct_type = p2r_type_ptr_from_itype(lf->itype); + dst_type->byte_size = dst_type->direct_type ? dst_type->direct_type->byte_size : 0; + } }break; //- rjf: POINTER @@ -3072,10 +3089,10 @@ p2r_convert(Arena *arena, P2R_User2Convert *in) } // rjf: fill type - dst_type = rdim_type_chunk_list_push(arena, &all_types, (U64)itype_opl); if(modifier_flags != 0) { RDIM_Type *pointer_type = rdim_type_chunk_list_push(arena, &all_types, (U64)itype_opl); + dst_type = rdim_type_chunk_list_push(arena, &all_types, (U64)itype_opl); dst_type->kind = RDI_TypeKind_Modifier; dst_type->flags = modifier_flags; dst_type->direct_type = pointer_type; @@ -3086,6 +3103,7 @@ p2r_convert(Arena *arena, P2R_User2Convert *in) } else { + dst_type = rdim_type_chunk_list_push(arena, &all_types, (U64)itype_opl); dst_type->kind = type_kind; dst_type->byte_size = arch_addr_size; dst_type->direct_type = direct_type;