summaryrefslogtreecommitdiff
path: root/llvm/lib/DWARFLinker/Parallel/DWARFLinkerCompileUnit.cpp
AgeCommit message (Collapse)Author
2025-07-04[llvm] Use llvm::fill (NFC) (#147099)Kazu Hirata
We can pass a range to llvm::fill.
2025-06-04[llvm] Remove unused includes (NFC) (#142733)Kazu Hirata
These are identified by misc-include-cleaner. I've filtered out those that break builds. Also, I'm staying away from llvm-config.h, config.h, and Compiler.h, which likely cause platform- or compiler-specific build failures.
2025-05-05[DWARFLinkerParallel] Fix incorrect uses of compare_exchange_weak (#138129)Martin Storsjö
The documentation for compare_exchange_weak says that it is allowed to spuriously fail. If compare_exchange_weak is called in a loop, spurious failures usually are benign - but in these cases, a spurious failure would give incorrect behaviour. E.g. in TypePool::getOrCreateTypeEntryBody, we assume that if the compare_exchange call returned false, we had been preempted by another thread and that DIE is non-null. This fixes running the dsymutil tests on Windows on aarch64 (built with a mingw toolchain with libc++).
2024-12-12[llvm] Migrate away from PointerUnion::{is,get} (NFC) (#119679)Kazu Hirata
Note that PointerUnion::{is,get} have been soft deprecated in PointerUnion.h: // FIXME: Replace the uses of is(), get() and dyn_cast() with // isa<T>, cast<T> and the llvm::dyn_cast<T> I'm not touching PointerUnion::dyn_cast for now because it's a bit complicated; we could blindly migrate it to dyn_cast_if_present, but we should probably use dyn_cast when the operand is known to be non-null.
2024-09-22[llvm] Use std::optional::value_or (NFC) (#109568)Kazu Hirata
2024-07-16Split DWARFFormValue::getReference into four functions (#98905)Pavel Labath
The result of the function cannot be correctly interpreted without knowing the precise form type (a type signature needs to be looked up very differently from a supplementary debug info reference). The function sort of worked because the two reference types (unit-relative and section-relative) that can be handled uniformly are also the most common types of references, but this setup made it easy to write code which does not support other kinds of reference (and if one tried to support them, the result didn't look pretty -- https://github.com/llvm/llvm-project/pull/97423/files#r1676217081). The split is based on the reference type classification from DWARFv5 (Section 7.5.5 Classes and Forms), and it should enable uniform (if slightly more verbose) hadling. Note that this only affects users which want more control of how (or if) the references are resolved. Users which just want to access the referenced DIE can use the higher level API (DWARFDie::GetAttributeValueAsReferencedDie) which returns (or will return after #97423 is merged) the correct die for all reference types (except for supplementary references, which we don't support right now).
2024-07-07[llvm] Remove redundant calls to std::unique_ptr<T>::get (NFC) (#97914)Kazu Hirata
2024-07-06[llvm] Remove redundant calls to std::unique_ptr<T>::get (NFC) (#97778)Kazu Hirata
2024-05-30[dsymutil] Also detect external downloadable toolchains (#93872)Adrian Prantl
and reject them when copying Swift interface files, since they can live outside of DEVELOPER_DIR.
2024-05-30Fix the dsymutil heuristic for excluding system interfaces. (#93745)Adrian Prantl
The function was meant to find the Developer/ dir, but it found a Developer directory nested deep inside the top-level Developer dir. The new implementation rejects everything in Xcode.app/Developer in broad strokes. rdar://128571037
2024-01-23[dsymutil] Add --linker parallel to more tests. (#78581)Alexey Lapshin
This patch adds check for parallel linker to tests located in the root of test/tools/dsymutil.
2024-01-19[llvm] Use SmallString::operator std::string (NFC)Kazu Hirata
2024-01-19[DWARFLinker][NFC] Decrease DWARFLinker dependence on DwarfStreamer. (#77932)Alexey Lapshin
This patch is extracted from #74725. The DwarfStreamer interface looks overcomplicated and has unnecessary dependencies. This patch avoids creation of DwarfStreamer by DWARFLinker and simplifies interface.
2024-01-11[DWARFLinker][NFC] Move common code into the base library: Utils.h (#77604)avl-llvm
This patch is extracted from #74725. Put some usefull routines into the common Utils.h.
2024-01-09[DWARFLinker][DWARFLinkerParallel][NFC] Refactor ↵avl-llvm
DWARFLinker&DWARFLinkerParallel to have a common library. Part 1. (#75925) This patch creates DWARFLinkerBase library, places DWARFLinker code into DWARFLinker\Classic, places DWARFLinkerParallel into DWARFLinker\Parallel. updates BOLT to use new library. This patch is NFC.