add garbage collector for COMDAT sections

This commit is contained in:
Nikita Smith
2025-07-23 16:09:48 -07:00
committed by Ryan Fleury
parent a6b2cf64ba
commit 17d35cd327
4 changed files with 324 additions and 292 deletions
+2
View File
@@ -15,6 +15,7 @@ typedef struct LNK_Obj
U32 *comdats;
B8 hotpatch;
U32Node **associated_sections;
U32 *symlinks;
} LNK_Obj;
typedef struct LNK_ObjNode
@@ -110,6 +111,7 @@ internal U32 lnk_obj_get_vol_md(LNK_Obj *obj);
internal COFF_ParsedSymbol lnk_parsed_symbol_from_coff(LNK_Obj *obj, void *coff_symbol);
internal COFF_ParsedSymbol lnk_parsed_symbol_from_coff_symbol_idx(LNK_Obj *obj, U64 symbol_idx);
internal COFF_SectionHeader * lnk_coff_section_header_from_section_number(LNK_Obj *obj, U64 section_number);
internal COFF_SectionHeader * lnk_coff_section_table_from_obj(LNK_Obj *obj);
internal B32 lnk_try_comdat_props_from_section_number(LNK_Obj *obj, U32 section_number, COFF_ComdatSelectType *select_out, U32 *section_number_out, U32 *section_length_out, U32 *check_sum_out);
internal B32 lnk_is_coff_section_debug(LNK_Obj *obj, U64 sect_idx);