[tracing] Improve and simplify startup tracing This CL aligns behavior across child processes, and supports tracing earlier during startup generally. - Only Gpu process previously implemented early initialization, this is now implemented on all child processes. - Logic around SetupStartupTracingBlocking is simplified as a result, we call it directly as soon as field trials are initialized. Gpu process on linux/chromeos restarts the tracing thread. For simplicity, this isn't implemented in other processes and we fallback to "later" startup tracing (needs_startup_tracing_after_sandbox_init), which is still earlier than what we had before. I encountered an underlying issue where UpdateDataSource complains about missing DataSourceDescriptor.id; I believe this started happening because the reordering leads us to register e.g. v8 TrackEvent after we started tracing. The consequences are benign; we don't really rely on DataSourceDescriptor other than being informative. The fix is simply to forward the id through mojo. Change-Id: I7f4afc5f97956bc7f97dc00741c317482be3ab5d Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6685790 Reviewed-by: Gabriel Charette <gab@chromium.org> Reviewed-by: Kramer Ge <fangzhoug@chromium.org> Reviewed-by: Ken Buchanan <kenrb@chromium.org> Reviewed-by: Dave Tapuska <dtapuska@chromium.org> Reviewed-by: Mikhail Khokhlov <khokhlov@google.com> Commit-Queue: Etienne Pierre-Doray <etiennep@chromium.org> Cr-Commit-Position: refs/heads/main@{#1482672}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
To check out the source code locally, don't use git clone! Instead, follow the instructions on how to get the code.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure.
For historical reasons, there are some small top level directories. Now the guidance is that new top level directories are for product (e.g. Chrome, Android WebView, Ash). Even if these products have multiple executables, the code should be in subdirectories of the product.
If you found a bug, please file it at https://crbug.com/new.