parallelize section garbage collection

currently we tag pointers to solve ABA problem however if the list
has more than max_U16 items, the tag will overflow and cause serious issues.
To fix this, we need to use 64-bit tags together with 128-bit interlocked
compare-exchange intrinsic
This commit is contained in:
Nikita Smith
2025-09-17 15:21:37 -07:00
committed by Ryan Fleury
parent cc8fdc6c6f
commit 5a12513306
4 changed files with 299 additions and 128 deletions
+3 -3
View File
@@ -2934,9 +2934,9 @@ THREAD_POOL_TASK_FUNC(lnk_push_dbi_sec_contrib_task)
for (U64 sect_idx = 0; sect_idx < obj->header.section_count_no_null; sect_idx += 1) {
COFF_SectionHeader *obj_sect_header = &obj_section_table[sect_idx];
if (obj_sect_header->flags & COFF_SectionFlag_LnkInfo) { continue; }
if (obj_sect_header->flags & COFF_SectionFlag_LnkRemove) { continue; }
if (obj_sect_header->flags & LNK_SECTION_FLAG_DEBUG_INFO) { continue; }
if (obj_sect_header->flags & COFF_SectionFlag_LnkInfo) { continue; }
if (obj_sect_header->flags & COFF_SectionFlag_LnkRemove) { continue; }
if (obj_sect_header->flags & LNK_SECTION_FLAG_DEBUG) { continue; }
U64 sect_number;
String8 sect_data;