[clang] [llvm] [ThinLTO][Split] Split module for parallel compilation in backend (1/N) (PR #198702)

via llvm-commits llvm-commits at lists.llvm.org
Sat Aug 29 02:06:53 PDT 2026


================

----------------
mmjjpp wrote:

Good point — I've switched FunctionMapTy to std::map for deterministic iteration.
The non-deterministic iteration order of DenseMap does not affect the final partitioning output: FunctionMap is iterated in createWorkList() to discover call-graph roots (in-degree 0), where the result is collected into a DenseSet (EntryFuncs) and the resulting FWDWorkList is subsequently sorted by (TotalCost desc, Function name asc). Each FunctionWithDependencies entry's content (dependencies set, total cost) is also order-independent. However, print() would still produce non-deterministic debug output, hence the switch to std::map.

https://github.com/llvm/llvm-project/pull/198702


More information about the llvm-commits mailing list