Index: COFF/ICF.cpp =================================================================== --- COFF/ICF.cpp +++ COFF/ICF.cpp @@ -267,12 +267,14 @@ }); // Combine the hashes of the sections referenced by each section into its - // hash. + // hash. This is only needed for ARM64, where the .pdata format makes those + // sections less likely to be unique. parallelForEach(Chunks, [&](SectionChunk *SC) { uint32_t Hash = SC->Class[1]; - for (Symbol *B : SC->symbols()) - if (auto *Sym = dyn_cast_or_null(B)) - Hash ^= Sym->getChunk()->Class[1]; + if (Config->Machine == ARM64) + for (Symbol *B : SC->symbols()) + if (auto *Sym = dyn_cast_or_null(B)) + Hash ^= Sym->getChunk()->Class[1]; // Set MSB to 1 to avoid collisions with non-hash classs. SC->Class[0] = Hash | (1U << 31); });