mirror of
https://github.com/react/react-native-devtools-frontend.git
synced 2026-10-29 17:35:02 +08:00
Previously when using the index map format[^1], we'd sort all the mappings that we had seen until that point after every single section, which scales really poorly as more sections are combined within a single source map. With this patch we only sort once after all the mappings from all the sections are processed. On the bundle10000.js.map example from the referenced bug, the time to execute `#ensureMappingsProcessed()` goes from ~22s to ~120ms, so roughly a 183x improvement. [^1]: http://doc/1U1RGAehQwRypUTovF1KRlpiOFze0b-_2gc6fAH0KY0k#heading=h.535es3xeprgt Fixed: chromium:1411617 Also-By: Tobias Koppers <tobias.koppers@googlemail.com> Change-Id: I64d6347f37152f13c2b2abde6484c5540946a46f Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/4207833 Commit-Queue: Simon Zünd <szuend@chromium.org> Auto-Submit: Benedikt Meurer <bmeurer@chromium.org> Commit-Queue: Benedikt Meurer <bmeurer@chromium.org> Reviewed-by: Simon Zünd <szuend@chromium.org>