OLD | NEW |
(Empty) | |
| 1 # Startup Tracing with MemoryInfra |
| 2 |
| 3 [MemoryInfra](memory_infra.md) supports startup tracing. |
| 4 |
| 5 ## The Simple Way |
| 6 |
| 7 Start Chrome as follows: |
| 8 |
| 9 $ chrome --no-sandbox \ |
| 10 --trace-startup=-*,disabled-by-default-memory-infra \ |
| 11 --trace-startup-file=/tmp/trace.json \ |
| 12 --trace-startup-duration=7 |
| 13 |
| 14 This will use the default configuration: one memory dump every 250 ms with a |
| 15 detailed dump ever two seconds. |
| 16 |
| 17 ## The Advanced Way |
| 18 |
| 19 If you need more control over the granularity of the memory dumps, you can |
| 20 specify a custom trace config file as follows: |
| 21 |
| 22 $ cat > /tmp/trace.config |
| 23 { |
| 24 "startup_duration": 4, |
| 25 "result_file": "/tmp/trace.json", |
| 26 "trace_config": { |
| 27 "included_categories": ["disabled-by-default-memory-infra"], |
| 28 "excluded_categories": ["*"], |
| 29 "memory_dump_config": { |
| 30 "triggers": [ |
| 31 { "mode": "light", "periodic_interval_ms": 50 }, |
| 32 { "mode": "detailed", "periodic_interval_ms": 1000 } |
| 33 ] |
| 34 } |
| 35 } |
| 36 } |
| 37 |
| 38 $ chrome --no-sandbox --trace-config-file=/tmp/trace.config |
| 39 |
| 40 ## Related Pages |
| 41 |
| 42 * [General information about startup tracing](https://sites.google.com/a/chromi
um.org/dev/developers/how-tos/trace-event-profiling-tool/recording-tracing-runs) |
| 43 * [Memory tracing with MemoryInfra](memory_infra.md) |
OLD | NEW |