Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rollup merge of rust-lang#92024 - pcwalton:per-codegen-unit-names, r=…
…davidtwco rustc_codegen_llvm: Give each codegen unit a unique DWARF name on all platforms, not just Apple ones. To avoid breaking split DWARF, we need to ensure that each codegen unit has a unique `DW_AT_name`. This is because there's a remote chance that different codegen units for the same module will have entirely identical DWARF entries for the purpose of the DWO ID, which would violate Appendix F ("Split Dwarf Object Files") of the DWARF 5 specification. LLVM uses the algorithm specified in section 7.32 "Type Signature Computation" to compute the DWO ID, which does not include any fields that would distinguish compilation units. So we must embed the codegen unit name into the `DW_AT_name`. Closes rust-lang#88521.
- Loading branch information