aboutsummaryrefslogtreecommitdiff
path: root/src/client/linux/microdump_writer/microdump_writer_unittest.cc
Commit message (Collapse)AuthorAgeFilesLines
* Add API to skip dump if crashing thread doesn't reference a given moduleTobias Sargeant2017-01-181-18/+11
| | | | | | | | | | | | | | | | | | | | | | | | This CL makes it possible to skip a dump if the crashing thread doesn't have any pointers to a given module. The concrete use case is WebView where we would like to skip generating microdump output when webview is unreferenced by the stack and thus cannot be responsible for the crash in a way that would be debuggable. The range of interesting addresses is chosen by examining the process mappings to find the one that contains a pointer that is known to be in the right shared object (i.e. an appropriately chosen function pointer) passed from the client. If the extracted stack does not contain a pointer in this range, then we do not generate a microdump. If the stack extraction fails, we still generate a microdump (without a stack). BUG=664460 Change-Id: If19406a13168264f7751245fc39591bd6cdbf5df Reviewed-on: https://chromium-review.googlesource.com/419476 Reviewed-by: Robert Sesek <rsesek@chromium.org> Reviewed-by: Primiano Tucci <primiano@chromium.org>
* Fix unit tests expecting no output when a microdump is suppressed.Tobias Sargeant2016-12-121-9/+9
| | | | | | | | BUG= Change-Id: Ie4d190c68ecbd8709874a3f1ceb872b94b36914f Reviewed-on: https://chromium-review.googlesource.com/419036 Reviewed-by: Primiano Tucci <primiano@chromium.org>
* Fix sign-compare compiler warning in MicrodumpWriterTestMike Percy2016-12-101-2/+2
| | | | | | | | | | | | | | Commit 7a8980997d0e0dcf3f3a5d8ccf3c1d8c2840ea27 introduced additional tests into MicrodumpWriterTest, two of which throw warnings which break "make check" under default settings on Linux, because the Makefiles are configured with -Werror=sign-compare. This patch just makes the signedness of the assertion arguments match. Change-Id: Ib522f44205c84f91bc9b93276fad60ebbf005f60 Reviewed-on: https://chromium-review.googlesource.com/418938 Reviewed-by: Tobias Sargeant <tobiasjs@chromium.org> Reviewed-by: Mike Frysinger <vapier@chromium.org>
* Do not generate a microdump if there are no webview pointers on the stack.Tobias Sargeant2016-12-011-31/+94
| | | | | | | | | | | | | | The stack interest range is passed in MicrodumpExtraInfo from the client. If the extracted stack does not contain a pointer in this range, then we assume that this is not a WebView crash, and do not generate a microdump. If the stack extraction fails, we still generate a microdump (without a stack). BUG=664460 Change-Id: Ic762497f76f074a3621c7ec88a8c20ed768b9211 Reviewed-on: https://chromium-review.googlesource.com/412781 Reviewed-by: Primiano Tucci <primiano@chromium.org>
* Add GPU fingerprint information to breakpad microdumps.Primiano Tucci2015-09-281-14/+66
| | | | | | | | | | | | | | | | | | Although strictly the GPU fingerprint is defined by the build fingerprint, there is not currently a straightforward mapping from build fingerprint to useful GPU / GL driver information. In order to aid debugging of WebView crashes that occur in GL drivers, and to better understand the range of drivers and versions for feature blacklisting purposes, it is useful to have GPU fingerprints in breakpad microdumps. Landing this patch on behalf of Tobias Sargeant<tobiasjs@chromium.org> BUG=chromium:536769 R=primiano@chromium.org, thestig@chromium.org Review URL: https://codereview.chromium.org/1334473003 .
* [microdump] Fix hw architecture indication in build fingerprint lineprimiano@chromium.org2015-08-171-3/+44
| | | | | | | | | | | | | | | | r1456 introduced the possibility to customize the OS-line of the microdump, enabling to replace, in the case of android, the generic uname() info with the Android build fingerprint. While doing that, it mistakenly removed the HW architecture indication from the format. See crbug.com/520075 for more details. BUG=chromium:520075 R=mmandlis@chromium.org, torne@chromium.org Review URL: https://codereview.chromium.org/1288313002 . git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1489 4c0a9323-5329-0410-9bdc-e9ce6186880e
* [microdump] Add build fingerprint and product info metadata.primiano@chromium.org2015-05-151-25/+56
| | | | | | | | | | | | | | | | This is to add build fingerprint and product name/version to microdumps. Conversely to what happens in the case of minidumps with MIME fields, due to the nature of minidumps, extra metadata cannot be reliably injected after the dump is completed. This CL adds the plumbing to inject two optional fields plus the corresponding tests. BUG=chromium:410294 R=thestig@chromium.org Review URL: https://codereview.chromium.org/1125153008 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1456 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Remove unused variable 'kGUIDStringSize' in microdump_writer_unittest.benchan@chromium.org2015-01-281-4/+0
| | | | | | | | R=mark@chromium.org Review URL: https://breakpad.appspot.com/3754002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1417 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Microdumps: support aarch64 and lib mapping from APKprimiano@chromium.org2014-12-021-0/+7
| | | | | | | | | | | | | | | | | | - Filter modules by prot flags (only +x) not extensions. It wouldn't otherwise catch the case of Chrome mapping the library from the apk (which is mapped r-x but doesn't end in .so). - Use compile-time detection of target arch, in order to cope with multilib OSes, where uname() doesn't reflect the run-time arch. - Add OS information and CPU arch / count. - Add support for aarch64. - Add tests and stackwalk expectations for aarch64. - Fix a potential overflow bug in the processor. - Rebaseline the tests using smaller symbols. - Fix microdump_writer_unittest.cc on 32-bit host. BUG=chromium:410294 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1407 4c0a9323-5329-0410-9bdc-e9ce6186880e
* Fix microdump_writer and add unittest.primiano@chromium.org2014-11-251-0/+130
This adds some small fixes to the microdump writer and introduces a unittest. BUG=chromium:410294 R=mmandlis@chromium.org Review URL: https://breakpad.appspot.com/2814002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@1404 4c0a9323-5329-0410-9bdc-e9ce6186880e