fix(@angular/build): aggregate parallel worker performance timings on the main thread - #33425
fix(@angular/build): aggregate parallel worker performance timings on the main thread#33425alan-agius4 wants to merge 0 commit into
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces performance timing aggregation across parallel compilation workers by adding helper functions to retrieve, clear, and merge cumulative durations, and updating the parallel compilation and worker diagnostics to pass and merge these timings. The feedback suggests simplifying the map-to-object conversion in profiling.ts using Object.fromEntries, extending timing aggregation to other compilation phases like initialize and emit, and adding unit tests to verify the serialization and merging of timings from the parallel worker.
d740020 to
9f8bc46
Compare
9f8bc46 to
e664314
Compare
|
This pull request has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Rather than having the parallel worker thread print its cumulative durations separately to the console (which causes console spam and disjointed/incomplete final logs), we serialize and return the worker's durations to the main thread upon completing the diagnostics task. The main thread then merges them into the global cumulative durations map, producing a single, complete, and perfectly aggregated performance report at the end of the build.