Commit graph

171 commits

Author SHA1 Message Date
mark@chromium.org
4f291f0307 Changes to get the breakpad client compiling and running on Android using
ndk-7b.

Patch by Carlos Valdivia <carlosvaldivia@google.com>

Review URL: https://breakpad.appspot.com/363001/


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@945 4c0a9323-5329-0410-9bdc-e9ce6186880e
2012-04-03 16:38:53 +00:00
jimblandy
6eccfe32b1 Add partial unit tests for dwarf2reader::CompilationUnit.
This is really incomplete --- it's just what's needed to get started
testing support for the DWARF 4 attribute forms.


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@910 4c0a9323-5329-0410-9bdc-e9ce6186880e
2012-02-01 14:57:58 +00:00
benchan@chromium.org
30566abed8 Implement core dump to minidump conversion.
This patch is part of a bigger patch that helps merging the breakpad code
with the modified version in Chromium OS.

Specifically, this patch makes the following changes:
1. Turn the LinuxDumper class into a base class and move ptrace related
   code into a new derived class, LinuxPtraceDumper.
2. Add a LinuxCoreDumper class, which is derived from LinuxDumper, to
   extract information from a crashed process via a core dump file instead
   of ptrace.
3. Add a WriteMinidumpFromCore function to
     src/client/linux/minidump_writer/minidump_writer.h,
   which uses LinuxCoreDumper to extract information from a core dump file.
4. Add a core2md utility, which simply wraps WriteMinidumpFromCore, for
   converting a core dump to a minidump.

BUG=455
TEST=Tested the following:
1. Build on 32-bit and 64-bit Linux with gcc 4.4.3 and gcc 4.6.
2. Build on Mac OS X 10.6.8 with gcc 4.2 and clang 3.0 (with latest gmock).
3. All unit tests pass.
4. Run Chromium OS tests to test core2md.
Review URL: http://breakpad.appspot.com/343001

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@905 4c0a9323-5329-0410-9bdc-e9ce6186880e
2012-01-19 07:14:51 +00:00
thestig@chromium.org
03c31f2100 Build LinuxLibcSupportTest and make it pass.
Review URL: http://breakpad.appspot.com/341001

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@903 4c0a9323-5329-0410-9bdc-e9ce6186880e
2012-01-11 20:35:18 +00:00
benchan@chromium.org
07e521c396 Add utilities for processing Linux core dump files.
This patch is part of a bigger patch that helps merging the breakpad code
with the modified version in Chromium OS.

Specifically, this patch makes the following changes:
1. Add an ElfCoreDump class for processing Linux core dump files, which will
   later be used to implement the core dump to minidump conversion.
2. Add a CrashGenerator class for generating a crash with a core dump file
   for testing the functionalities of ElfCoreDump.
3. Move some utility functions for reading/writing files to file_utils.h.

BUG=455
TEST=Tested the following:
1. Build on 32-bit and 64-bit Linux with gcc 4.4.3 and gcc 4.6.
2. Build on Mac OS X 10.6.8 with gcc 4.2 and clang 3.0 (with latest gmock).
3. All unit tests pass.
Review URL: http://breakpad.appspot.com/337001

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@900 4c0a9323-5329-0410-9bdc-e9ce6186880e
2012-01-07 02:25:22 +00:00
benchan@chromium.org
33c135a16f Replace MMappedRange with MinidumpMemoryRange.
This patch is part of a bigger patch that helps merging the breakpad code
with the modified version in Chromium OS.

The MemoryRange class was added in r895 (http://breakpad.appspot.com/332001),
which is largely based on MMappedRange but generalized to be used in other
code. However, MemoryRange does not support minidump data structures. This
patch adds a MinidumpMemoryRange class that extends MemoryRange to handle
minidump data structures, which can then replace MMappedRange.

As with MemoryRange, MinidumpMemoryRange is unit tested.

BUG=455
TEST=Tested the following:
1. Build on 32-bit and 64-bit Linux with gcc 4.4.3 and gcc 4.6.
2. Build on Mac OS X 10.6.8 with gcc 4.2 and clang 3.0 (with latest gmock).
3. All unit tests pass.
4. Run minidump-2-core to covnert a minidump file to a core file.
Review URL: http://breakpad.appspot.com/335001

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@898 4c0a9323-5329-0410-9bdc-e9ce6186880e
2011-12-21 22:33:21 +00:00
benchan@chromium.org
ae5193c24e Replace readlink calls with a safer version that guarantees NULL-termination.
This patch is part of a bigger patch that helps merging the breakpad code
with the modified version in Chromium OS.

Specifically, this patch makes the following changes:
1. Add a SafeReadLink function that wraps sys_readlink() to resolve a
   symbolic link but guarantees the result is NULL-terminated on success.
2. Refactor other source code to use SafeReadLink instead of readlink()
   or sys_readlink().

BUG=455
TEST=Tested the following:
1. Build on 32-bit and 64-bit Linux with gcc 4.4.3 and gcc 4.6.
2. Build on Mac OS X 10.6.8 with gcc 4.2 and clang 3.0 (with latest gmock).
3. All unit tests pass.
4. Run minidump-2-core to covnert a minidump file to a core file.
Review URL: http://breakpad.appspot.com/334001

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@896 4c0a9323-5329-0410-9bdc-e9ce6186880e
2011-12-21 17:51:40 +00:00
benchan@chromium.org
f044345c23 Refactor code in preparation of merging with the fork in Chromium OS.
This patch is part of a bigger patch that helps merging the breakpad code
with the modified version in Chromium OS.

Specifically, this patch makes the following changes:
1. Add a MemoryRange class for encapsulating and checking read access
   to a contiguous range of memory.
2. Add a MemoryMappedFile class for mapping a file into memory for
   read-only access.
3. Refactor other source code to use MemoryMappedFile.

BUG=455
TEST=Tested the following:
1. Build on 32-bit and 64-bit Linux with gcc 4.4.3 and gcc 4.6.
2. Build on Mac OS X 10.6.8 with gcc 4.2 and clang 3.0 (with latest gmock).
3. All unit tests pass.
4. Run minidump-2-core to covnert a minidump file to a core file.
Review URL: http://breakpad.appspot.com/332001

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@895 4c0a9323-5329-0410-9bdc-e9ce6186880e
2011-12-16 16:42:59 +00:00
ted.mielczarek
84571a2b91 Rename md5.c to md5.cc, put its contents inside the google_breakpad namespace.
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@887 4c0a9323-5329-0410-9bdc-e9ce6186880e
2011-11-18 21:40:27 +00:00
ted.mielczarek
69607b678f Remove NetworkSourceLine{Resolver,Server} and related code. It never wound up being useful enough to use in production, so let's drop the maintenence burden
R=jessicag at http://breakpad.appspot.com/292001/show

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@795 4c0a9323-5329-0410-9bdc-e9ce6186880e
2011-07-07 20:53:52 +00:00
ted.mielczarek
3ca4a120de Add some unit tests for Linux WriteSymbolFile
This patch adds synth_elf::{StringTable,SymbolTable,ELF} classes to
produce in-memory ELF files to properly test the Linux symbol dumping
code. It also uses those classes to add some basic tests for
the WriteSymbolFile function.

R=jimb at http://breakpad.appspot.com/277001/show

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@794 4c0a9323-5329-0410-9bdc-e9ce6186880e
2011-07-06 17:05:59 +00:00
ted.mielczarek
b2f96f314c Dump PUBLIC + CFI records from libraries without debug info on Linux, use .dynsym for symbol names if there are no usable debug symbols.
R=jimb at http://breakpad.appspot.com/275001/show

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@793 4c0a9323-5329-0410-9bdc-e9ce6186880e
2011-07-06 17:05:49 +00:00
ted.mielczarek
dbf409ca20 Make programs in src/tools/linux build via the automake build system
R=jimb at http://breakpad.appspot.com/265001

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@775 4c0a9323-5329-0410-9bdc-e9ce6186880e
2011-02-28 14:05:22 +00:00
ted.mielczarek
b7fdc7396d Add module_serializer.cc to libbreakpad.a. Not sure why it wasn't there in the first place. Trivial patch, landing without review.
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@759 4c0a9323-5329-0410-9bdc-e9ce6186880e
2011-01-19 17:02:10 +00:00
SiyangXie@gmail.com
41f998fe5a FastSourceLineResolver implementation for optimization purpose.
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@719 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-10-21 17:13:01 +00:00
SiyangXie@gmail.com
08730fc9a6 Add static version of map wrappers and corresponding serializers.
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@714 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-10-15 20:36:31 +00:00
SiyangXie@gmail.com
5b117cf53a Refactor source line resolver, add interface in supplier and resolver.
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@711 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-10-07 20:31:36 +00:00
ted.mielczarek
d192a71e24 ditch libtool, only build static libs
R=mark at http://breakpad.appspot.com/210001/show

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@709 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-10-05 19:38:51 +00:00
ted.mielczarek
e574a2adc6 add a --disable-processor configure arg to skip building processor libs and just build client libs
R=nealsid at http://breakpad.appspot.com/209001/show

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@708 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-10-05 19:38:22 +00:00
cdn@chromium.org
2b4274afc4 Added libdisasm to the repository. This library is no longer under development so there
is no reason not to keep it locally. Implemented a basic disassembler which can be used
to scan bytecode for interesting conditions. This should be pretty easy to add to for
things other than exploitability if there is a desire. This also adds several tests to
the windows exploitability ranking code to take advantage of the disassembler for x86
code.

BUG=None
TEST=DisassemblerX86Test.*

Review URL: http://breakpad.appspot.com/203001

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@705 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-10-01 22:38:10 +00:00
ted.mielczarek
82a0188946 add top_srcdir/src to CPPFLAGS for all unittests to fix compilation of unittests when configuring outside the srcdir
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@701 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-09-29 14:02:09 +00:00
ted.mielczarek
4621ee0691 Write a window of memory around the instruction pointer from the crashing thread to the minidump on OS X.
R=nealsid at http://breakpad.appspot.com/200001/show

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@699 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-09-23 14:55:50 +00:00
cdn@chromium.org
cec12872c4 Added the base exploitability module for windows. This only adds the very basic exception type based analysis for now.
BUG=NONE
TEST=MinidumpProcessorTest.TestExploitilityEngine

Review URL: http://breakpad.appspot.com/189001

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@698 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-09-22 02:37:19 +00:00
SiyangXie@gmail.com
378e28e301 Add StaticMap implementation and unittest to breakpad.
StaticMap is a fundamental component class for in-memory representation of loaded symbol.


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@694 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-09-20 17:45:15 +00:00
ted.mielczarek
efa30c13f2 Write a window of memory around the instruction pointer from the crashing thread to the minidump on Linux.
R=nealsid at http://breakpad.appspot.com/194001/show

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@693 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-09-17 13:36:11 +00:00
ted.mielczarek
53a8b1a204 Issue 378 - Don't compile Linux client libraries on non-Linux systems
R=nealsid at http://breakpad.appspot.com/173001/show

git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@679 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-08-31 15:09:01 +00:00
ted.mielczarek
34d3a2e0f3 Update Makefile.am from r662 (which only updated Makefile.in)
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@669 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-08-25 20:16:17 +00:00
jimblandy
865df5af57 Breakpad test support: Move test_assembler.{h,cc} from src/processor to src/common.
The google_breakpad::TestAssembler classes are used in both the processor's
and the Linux dumper's test suites, and will soon be used in the Mac
dumper's tests as well. This patch moves their source files from
src/processor to src/common.

a=jimblandy, r=thestig


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@574 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-04-27 19:17:59 +00:00
ted.mielczarek
b223627d81 provide a network source line resolver + server. r=mark,jimb at http://breakpad.appspot.com/36001
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@569 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-04-08 23:06:23 +00:00
jimblandy
e7e1e1ebf5 Breakpad processor: Support AMD64 stack unwinding driven by DWARF CFI.
This adds support for 'STACK CFI' records (DWARF CFI) to the AMD64
stack walker. This is necessary for the stack trace to include any
frames other than the youngest. Unit tests are included.

a=jimblandy, r=mmentovai


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@554 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-03-16 16:49:53 +00:00
jimblandy
c609f474a9 Breakpad: Support DWARF CFI-driven stack walking on ARM.
This patch allows the Breakpad minidump processor to use data from
STACK CFI records to generate stack traces for the ARM processor.

In the symbol dumper, we need a table mapping DWARF CFI register
numbers to their names: STACK CFI records refer to registers by name.

In the processor, we expand StackwalkerARM::GetCallerFrame to see if
there are STACK CFI records covering the callee, and then use those to
recover the caller's register values.

There's no good reason the ARM walker couldn't use the SimpleCFIWalker
interface declared in cfi_frame_info.h. Unfortunately, that interface
assumes that one can map register names to member pointers of the raw
context type, while MDRawContextARM uses an array to hold the
registers' values: C++ pointer-to-member types can't refer to elements
of member arrays. So we have to write out SimpleCFIWalker::FindCallerRegisters
in StackwalkerARM::GetCallerFrame.

We define enum MDARMRegisterNumbers in minidump_cpu_arm.h, for
convenience in referring to certain ARM registers with dedicated
purposes, like the stack pointer and the PC.

We define validity flags in StackFrameARM for all the registers, since
CFI could theoretically recover any of them. In the same vein, we
expand minidump_stackwalk.cc to print the values of all valid
callee-saves registers in the context --- and use the proper names for
special-purpose registers.

We provide unit tests that give full code and branch coverage (with
minor exceptions). We add a testing interface to StackwalkerARM that
allows us to create context frames that lack some register values.

a=jimblandy, r=mmentovai


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@553 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-03-16 16:46:22 +00:00
jimblandy
6d3a825dbf Breakpad: Add minidump processor support for DWARF Call Frame Information.
Add a CFIFrameInfo class (named for symmetry with WindowsFrameInfo) to
represent the set of STACK CFI rules in effect at a given instruction,
and apply them to a set of register values. Provide a SimpleCFIWalker
class template, to allow the essential CFI code to be shared amongst
the different architectures.

Teach BasicSourceLineResolver to partially parse 'STACK CFI' records,
and produce the set of rules in effect at a given instruction on
demand, by combining the initial rule set and the appropriate rule
deltas in a CFIFrameInfo object.

Adapt StackwalkerX86 and StackFrameX86 to retrieve, store, and apply
CFI stack walking information.

Add validity flags for all the general-purpose registers to
StackFrameX86::ContextValidity.

a=jimblandy, r=mmentovai


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@549 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-03-16 16:28:32 +00:00
jimblandy
a7eb2329de Breakpad processor: Unit tests for StackwalkerX86.
Issue 53001 (http://breakpad.appspot.com/53001) defines the
TestAssembler classes; those, along with a new set of mock classes
defined in stackwalker_unittest_utils.h, make it possible for us to
actually do proper unit testing of a stack walker. These tests get us
full code coverage for stackwalker_x86.cc.

a=jimblandy, r=mmentovai


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@548 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-03-16 16:25:30 +00:00
jimblandy
9244496c6f Breakpad Processor: Add new unit tests for google_breakpad::Minidump
This also adds two new test utility class groups, TestAssembler and
SynthMinidump. These are overkill for what I'm doing with them here
(and may simply be overkill, period), but they make it easy to write
unit tests for code that works on binary files or raw memory contents
in a cross-platform way. I'm planning to use them for the DWARF CFI
unwinding tests and the DWARF CFI parser tests.

a=jimblandy, r=nealsid


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@547 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-03-16 16:20:34 +00:00
nealsid
de545c09d0 ARM support, with some build system changes to support x86-64, arm, and i386 in an autoconf style build in Linux. The O2 build for the unit tests is still broken but I'm checking this in to unblock people
A=nealsid
R=ajwong, hannahtang, ted.mielczarek



git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@541 4c0a9323-5329-0410-9bdc-e9ce6186880e
2010-03-02 00:39:48 +00:00
jimblandy
b64d76a3b8 Issue 49012: Breakpad Processor: Rename 'StackFrameInfo' structure to 'WindowsFrameInfo'.
Also, rename stack_frame_info.h to windows_frame_info.h.

If it seems odd to have functions like FillSourceLineInfo returning
Windows-specific data structures... well, it is! This patch just makes
it more obvious what's going on.

a=jimblandy, r=nealsid


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@471 4c0a9323-5329-0410-9bdc-e9ce6186880e
2009-12-23 22:32:14 +00:00
ted.mielczarek
9276b0d301 Basic arm cpu support for processor. r=mark at http://breakpad.appspot.com/49011
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@454 4c0a9323-5329-0410-9bdc-e9ce6186880e
2009-12-19 21:43:53 +00:00
ted.mielczarek
0cbd50c975 Allow Minidump class to be instantiated with stream instead of file. r=mark at http://breakpad.appspot.com/46001
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@438 4c0a9323-5329-0410-9bdc-e9ce6186880e
2009-12-09 01:24:37 +00:00
nealsid
b56cfa067a Add more error information to minidump processing return code. Also added dependency on google test, and modified minidump processing unit tests to use google test
R=brdevmn
A=nealsid



git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@343 4c0a9323-5329-0410-9bdc-e9ce6186880e
2009-05-29 00:53:02 +00:00
ted.mielczarek
8eb7111814 Issue 196 - Breakpad processor support for x86-64. r=mento
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@227 4c0a9323-5329-0410-9bdc-e9ce6186880e
2007-10-31 19:20:31 +00:00
mmentovai
68004c84d6 Solaris version of symbol dumper (#207). Patch by Alfred Peng. r=me
http://groups.google.com/group/google-breakpad-dev/browse_thread/thread/e4cbdbf7ddaf7f51


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@218 4c0a9323-5329-0410-9bdc-e9ce6186880e
2007-09-28 18:14:48 +00:00
mmentovai
13f0b2666b Update EXTRA_DIST for packaging.
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@216 4c0a9323-5329-0410-9bdc-e9ce6186880e
2007-09-26 18:37:39 +00:00
mmentovai
ea2bba9706 Add SPARC/Solaris support to client handler and processor (#201, 200).
Patch by Michael shang <satisfy123>.  r=me, r=Alfred Peng.

http://groups.google.com/group/google-breakpad-discuss/browse_thread/thread/2fba07577f1fa35e


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@215 4c0a9323-5329-0410-9bdc-e9ce6186880e
2007-09-26 18:28:05 +00:00
mmentovai
2e0e2234b9 Allow building with -pedantic (#186). r=ted.mielczarek
http://groups.google.com/group/google-breakpad-dev/browse_thread/thread/6aa39d7f0ffa3c42


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@183 4c0a9323-5329-0410-9bdc-e9ce6186880e
2007-05-31 19:44:52 +00:00
mmentovai
65571f17ed Add logging to minidump processor (#82). Part 2: add messages to the rest of
the processor.  r=ted.mielczarek

http://groups.google.com/group/google-breakpad-dev/browse_thread/thread/cf56b767383a5d4b


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@172 4c0a9323-5329-0410-9bdc-e9ce6186880e
2007-05-21 20:09:33 +00:00
mmentovai
af3c43f00e Add logging to minidump processor (#82). First part: logging infrastructure
and messages for minidump.cc and minidump_processor.cc.  r=bryner.

http://groups.google.com/group/google-breakpad-dev/browse_thread/thread/b056994d675f623c


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@169 4c0a9323-5329-0410-9bdc-e9ce6186880e
2007-05-17 18:34:37 +00:00
mmentovai
e5dc60822e Rename Airbag to Breakpad.
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@122 4c0a9323-5329-0410-9bdc-e9ce6186880e
2007-02-14 19:51:05 +00:00
mmentovai
d986a54f67 Add module list to machine-readable minidump_stackwalk output (#119).
Patch by Ted Mielczarek.  r=me

http://groups.google.com/group/airbag-dev/browse_thread/thread/144e66b1de80b1db


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@114 4c0a9323-5329-0410-9bdc-e9ce6186880e
2007-01-29 21:30:31 +00:00
mmentovai
97d392dc4b Communicate OS and CPU to SymbolSupplier (#107). r=bryner
Interface change: moved a few fields around in ProcessState; added new
arguments to Stackwalker and SymbolSupplier.

http://groups.google.com/group/airbag-dev/browse_thread/thread/17e4a48ec3ede932


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@101 4c0a9323-5329-0410-9bdc-e9ce6186880e
2007-01-10 22:47:56 +00:00
bryner
fd38d48e6d Add an abstract interface to SourceLineResolver, and allow any implementation
to be used with MinidumpProcessor.  The basic SourceLineResolver is now a
public interface (#89)



git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@83 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-12-11 23:22:54 +00:00
mmentovai
db3342a10e Module API (#32). r=waylonis, bryner
- Introduces a standard API for dealing with modules.  MinidumpModule
   is now a concrete implementation of this API.  Code may interact with
   single modules using the CodeModule interface, and collections of
   modules using its container, the CodeModules interface.
 - CodeModule is used directly by SymbolSupplier implementations and
   SourceLineResolver.  Reliance on the specific implementation in
   MinidumpModule has been eliminated.
 - Module lists are now added to ProcessState objects.  Module references
   in each stack frame are now pointers to objects in these module lists.
 - The sample minidump_stackwalk tool prints the module list after printing
   all threads' stacks.

http://groups.google.com/group/airbag-dev/browse_frm/thread/a9c0550edde54cf8


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@74 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-12-05 22:52:28 +00:00
mmentovai
fe82bf24a9 Move headers for exported interfaces into src/google_airbag (#51). r=bryner
http://groups.google.com/group/airbag-dev/browse_thread/thread/e01f177386e8794a


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@60 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-11-06 19:39:47 +00:00
mmentovai
c34850a202 minidump_stackwalk should use MinidumpProcessor (#64). r=bryner
- minidump_stackwalk is now much more useful as a debugging tool and
   even as a standalone tool.
 - Reimplementation of minidump_stackwalk around MinidumpProcessor.
 - minidump_stackwalk displays all pertinent information returned by
   MinidumpProcessor in the ProcessState.
 - New PathnameStripper::File static utility method to display only the
   leaf file name in a pathname, cleaning up minidump_stackwalk's output.
 - New SimpleSymbolSupplier class, which implements a simple
   filesystem-based symbol supplier compatible with the layout used by
   Microsoft Symbol Server and its client cache.
 - minidump_stackwalk now accepts an optional second argument, a pathname
   to use as a symbol directory for a SimpleSymbolSupplier.
 - Updated test data to be compatible with SimpleSymbolSupplier, and added
   test data for kernel32.pdb.  Test data converted from CRLF line endings
   to LF.

http://groups.google.com/group/airbag-dev/browse_thread/thread/cce30a84f6b2d728


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@53 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-10-27 00:40:56 +00:00
mmentovai
e5468b8a49 MinidumpProcessor should process all threads (#35). r=bryner
- MinidumpProcessor now processes all threads and returns a new ProcessState
   object.  (Interface change.)
 - ProcessState contains a CallStack for each thread in the process, and
   additional information about whether the process crashed, which thread
   crashed, the reason for the crash, and identifying attributes for the
   OS and CPU.
 - MinidumpSystemInfo now contains a GetCPUVendor() method that returns the
   vendor information from CPUID 0 on x86 processors ("GenuineIntel").

http://groups.google.com/group/airbag-dev/browse_thread/thread/16dd2c981e3361ba


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@47 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-10-24 19:31:21 +00:00
mmentovai
2466d8e993 Replace auto_ptr with scoped_ptr (#56). r=bryner
http://groups.google.com/group/airbag-dev/browse_thread/thread/54c66451ed8e2835


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@46 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-10-23 20:25:42 +00:00
mmentovai
2fc823f579 Add PUBLIC support to SourceLineResolver (resolve function names in Windows
system libraries) (#53)
StackFrame::function_base is not populated (#49)
r=bryner

http://groups.google.com/group/airbag-dev/browse_thread/thread/a17d35348e7027bb


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@43 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-10-20 19:50:01 +00:00
mmentovai
246f406828 Handle frame pointer omission, (#21), part 4 (final part!): FPO stackwalker.
r=bryner
 - This change allows Airbag to properly walk win32 stacks produced by code
   built with MSVC's frame pointer omission optimization (/Oy).  This
   optimization is enabled at /O1 and /O2.
 - There too many interface and file format changes to list here.

http://groups.google.com/group/airbag-dev/browse_thread/thread/85ce85bfa8457ece


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@42 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-10-20 01:46:38 +00:00
mmentovai
fc1c78e60e Handle frame pointer omission (#21), part 3: SourceLineResolver and PDBSourceLineWriter changes. r=bryner.
- PDBSourceLineWriter (dump_syms) outputs stack frame debugging information
 - SourceLineResolver reads the new information and puts it into a
   new StackFrameInfo structure, which is stored in a ContainedRangeMap.
   FillSourceLineInfo passes the StackFrameInfo back to the caller.
 - The base Stackwalker makes StackFrameInfo data available to subclasses
   during stackwalking, but does not use this information directly itself.
   Stackwalkers may access stack_frame_info_ for enhanced stackwalking
   (this will be part 4).
 - New test data for the updated dumped-symbol format

http://groups.google.com/group/airbag-dev/browse_thread/thread/735f191c9a1a1de4


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@38 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-28 21:09:37 +00:00
mmentovai
0dbedc973d Better testing for Stackwalker (#18). r=bryner
- Test StackwalkerX86 and StackwalkerPPC on the current process, if built
   by a supported compiler (gcc) on a supported (walkable) CPU (x86, ppc).
 - This test is not enabled by default because of certain optimizations
   that interfere with it (stack frame reuse, frame pointer omission).  See
   the comments at the top of stackwalker_selftest.cc.  To enable this
   test in the standard "make check" suite, configure with --enable-selftest.

http://groups.google.com/group/airbag-dev/browse_thread/thread/2ca1c8e72c809bec


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@35 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-25 21:16:15 +00:00
mmentovai
960e5277ee ppc stackwalker (#30). r=bryner
- Implementation of PowerPC stackwalker.  Tested using stackwalker_selftest
   (#18).
 - Hook up processor-side multi-CPU support in MinidumpProcessor and
   minidump_stackwalk using the new Stackwalker::StackwalkerForCPU method.

http://groups.google.com/group/airbag-dev/browse_thread/thread/1c2fa7c5182a77a9


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@34 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-25 18:29:48 +00:00
mmentovai
b934bb974a Handle frame pointer omission (#21), part 2: PostfixEvaluator. r=bryner.
- A postfix (reverse-Polish) notation expression evaluator that we can
   feed stack-frame debug information into, crank, and get pointers to
   the calling frame from.

http://groups.google.com/group/airbag-dev/browse_thread/thread/a1d6c5d1fd5fdcb9


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@32 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-22 00:42:23 +00:00
mmentovai
7daf246e4b Relicense to BSD (#29). r=bryner
http://groups.google.com/group/airbag-dev/browse_thread/thread/5f19f13fc172c4e0


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@31 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-20 21:16:16 +00:00
mmentovai
8c2a4def4e Handle frame pointer omission (#21), part 1: ContainedRangeMap. r=bryner.
- ContainedRangeMap is the data structure that will be used to store and
   look up debugging information for frames by instruction address.  The
   debugging information includes a way to locate the calling frame in
   the absence of a saved frame pointer.
 - Restructure RangeMap into an -inl file to match ContainedRangeMap.

http://groups.google.com/group/airbag-dev/browse_thread/thread/c5823bfc1828ed42


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@29 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-20 16:20:15 +00:00
bryner
cce3492afc Get rid of CrashReport, and rename CrashReportProcessor to MinidumpProcessor
(#26) r=mmentovai.



git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@26 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-19 21:58:41 +00:00
mmentovai
cb9fd5b773 Make SourceLineResolver use RangeMap (#13). r=bryner
- Eliminate MemAddrMap from source_line_resolver.cc and adapt it to use
   RangeMap, also used by minidump.cc.
 - RangeMap operates on both a base address and a size, where MemAddrMap
   only used a base address, so the dumped symbol file format is modified
   to include size information.  dump_syms produces these files and
   SourceLineResolver consumes them.
 - Provide updated test data conforming to the new dumped symbol format.

http://groups.google.com/group/airbag-dev/browse_thread/thread/e9403cf3ad6336a1


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@21 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-08 18:03:56 +00:00
bryner
d5e66382d1 Add support to the StackWalker for resolving symbols, using a
caller-implemented SymbolSupplier object to get a symbol file.

Add a CrashReportProcessor object which provides a simple API for processing
a CrashReport struct, given a SymbolSupplier and a minidump file.

r=mmentovai (#17))


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@18 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-08 02:35:53 +00:00
mmentovai
213800d30c Initial implementation of x86 stackwalker (#9). r=bryner
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@12 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-06 19:28:46 +00:00
mmentovai
3261e8b6ea Initial implementation of minidump reader (#6). r=bryner
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@11 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-06 02:56:44 +00:00
bryner
07f8ef56ac Change header paths and include guards to be relative to the "src" directory. r=mmentovai.
http://groups.google.com/group/airbag-dev/msg/cbe061dd563e9d17



git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@10 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-09-05 19:42:57 +00:00
mmentovai
425d256321 Make build system less annoying (#8) r=bryner
- Place objects in the appropriate directories, instead of filling up
   the root directory.
 - Remove namespace macros, which made maintenance troublesome and which
   created a dependency on config.h in public headers
 - Skip useless Fortran checks at configure time


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@8 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-08-30 20:05:05 +00:00
bryner
cb91a2f879 Initial import, which includes the Windows client-side dump_syms tool, and
part of the server-side dump processor.



git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@4 4c0a9323-5329-0410-9bdc-e9ce6186880e
2006-08-25 21:14:45 +00:00