OLD | NEW |
1 # Tips for debugging on Linux | 1 # Tips for debugging on Linux |
2 | 2 |
3 This page is for Chromium-specific debugging tips; learning how to run gdb is | 3 This page is for Chromium-specific debugging tips; learning how to run gdb is |
4 out of scope. | 4 out of scope. |
5 | 5 |
6 [TOC] | 6 [TOC] |
7 | 7 |
8 ## Symbolized stack trace | 8 ## Symbolized stack trace |
9 | 9 |
10 The sandbox can interfere with the internal symbolizer. Use `--no-sandbox` (but | 10 The sandbox can interfere with the internal symbolizer. Use `--no-sandbox` (but |
(...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
404 | 404 |
405 or within gdb: | 405 or within gdb: |
406 | 406 |
407 set environment CHROME_IPC_LOGGING 1 | 407 set environment CHROME_IPC_LOGGING 1 |
408 | 408 |
409 If some messages show as unknown, check if the list of IPC message headers in | 409 If some messages show as unknown, check if the list of IPC message headers in |
410 [chrome/common/logging_chrome.cc](/chrome/common/logging_chrome.cc) is | 410 [chrome/common/logging_chrome.cc](/chrome/common/logging_chrome.cc) is |
411 up to date. In case this file reference goes out of date, try looking for usage | 411 up to date. In case this file reference goes out of date, try looking for usage |
412 of macros like `IPC_MESSAGE_LOG_ENABLED` or `IPC_MESSAGE_MACROS_LOG_ENABLED`. | 412 of macros like `IPC_MESSAGE_LOG_ENABLED` or `IPC_MESSAGE_MACROS_LOG_ENABLED`. |
413 | 413 |
414 ## Using valgrind | |
415 | |
416 To run valgrind on the browser and renderer processes, with our suppression file | |
417 and flags: | |
418 | |
419 $ cd $CHROMIUM_ROOT/src | |
420 $ tools/valgrind/valgrind.sh out/Debug/chrome | |
421 | |
422 You can use valgrind on chrome and/or on the renderers e.g | |
423 `valgrind --smc-check=all ../sconsbuild/Debug/chrome` | |
424 or by passing valgrind as the argument to `--render-cmd-prefix`. | |
425 | |
426 Beware that there are several valgrind "false positives" e.g. pickle, sqlite and | |
427 some instances in webkit that are ignorable. On systems with prelink and address | |
428 space randomization (e.g. Fedora), you may also see valgrind errors in libstdc++ | |
429 on startup and in gnome-breakpad. | |
430 | |
431 Valgrind doesn't seem to play nice with tcmalloc. To disable tcmalloc set the GN
arg: | |
432 | |
433 use_allocator="none" | |
434 | |
435 and rebuild. | |
436 | |
437 ## Profiling | 414 ## Profiling |
438 | 415 |
439 See | 416 See |
440 https://sites.google.com/a/chromium.org/dev/developers/profiling-chromium-and-we
bkit | 417 https://sites.google.com/a/chromium.org/dev/developers/profiling-chromium-and-we
bkit |
441 and [Linux Profiling](linux_profiling.md). | 418 and [Linux Profiling](linux_profiling.md). |
442 | 419 |
443 ## i18n | 420 ## i18n |
444 | 421 |
445 We obey your system locale. Try something like: | 422 We obey your system locale. Try something like: |
446 | 423 |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
537 [Running layout tests on Linux](layout_tests_linux.md) page. | 514 [Running layout tests on Linux](layout_tests_linux.md) page. |
538 | 515 |
539 If you need to test something with hardware accelerated compositing | 516 If you need to test something with hardware accelerated compositing |
540 (e.g., compiz), you can use `Xgl` (`sudo apt-get install xserver-xgl`). E.g.: | 517 (e.g., compiz), you can use `Xgl` (`sudo apt-get install xserver-xgl`). E.g.: |
541 | 518 |
542 Xgl :1 -ac -accel glx:pbuffer -accel xv:pbuffer -screen 1024x768 | 519 Xgl :1 -ac -accel glx:pbuffer -accel xv:pbuffer -screen 1024x768 |
543 | 520 |
544 ## Mozilla Tips | 521 ## Mozilla Tips |
545 | 522 |
546 https://developer.mozilla.org/en/Debugging_Mozilla_on_Linux_FAQ | 523 https://developer.mozilla.org/en/Debugging_Mozilla_on_Linux_FAQ |
OLD | NEW |