| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@870 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
| |
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@864 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
forbidden by the style guide, and are bad practice in headers even under
style rules that tolerate this construct.
This fixes warnings such as:
In file included from dwarf2reader.cc:34:
dwarf2reader.h:53:17: warning: using namespace directive in global context in header [-Wheader-hygiene]
Review URL: http://breakpad.appspot.com/312002
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@862 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
After the final DIE in a compilation unit, there may be any number of
zero bytes present. This is meant to allow producers to align
compilation unit starting points when necessary.
This patch changes the dwarf2reader::CompilationUnit class to skip
those zero bytes, rather than interpreting them as 'end of children'
markers for DIEs that do not exist. Without this change, the padding
bytes will cause the reader to attempt to pop an offset from an empty
stack, and call EndDIE with a garbage offset.
a=jimblandy, r=mmentovai
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@667 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
| |
stack<uint64> would do.
Perhaps there once was some reason one needed the DIE offset stack to
have an unusual lifetime, but there is none now.
a=jimblandy, r=mmentovai
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@666 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
| |
The 64-bit cleanups made last month (http://breakpad.appspot.com/133001/show)
introduced unit test suite failures when built for a 32-bit architecture. The
fix for those test suite failures (http://breakpad.appspot.com/140001/show)
introduce build failures on Linux.
a=jimblandy
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@665 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
| |
a=dmaclach, r=jimb
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@664 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
| |
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@652 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
| |
Review: http://breakpad.appspot.com/133001
BUG:none
TEST:Compile on Leopard
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@631 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
| |
Fix up some broken mac projects.
Consolidate project settings in xcconfig files.
http://breakpad.appspot.com/130001
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@627 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
| |
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@622 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch avoids unnecessary use of the <cfoo> headers in files that don't
actually use the identifiers they declare in the std:: namespace.
It also changes some files to better conform with the "Names and Order of
Includes" rules in the Google C++ Style Guide.
A=jimb R=mark
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@619 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
| |
I came across a bunch of comments Neal had made on issue 55011 that I
hadn't addressed. This patch takes care of them.
A=jimb R=thestig
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@618 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CallFrameInfo::Rule subclasses.
The subclasses of CallFrameInfo::Rule store the rule currently in
force for recovering a register or computing the canonical frame
address. Their sole responsibility is to accurately convey rules from
the parser, which creates them, to a CallFrameInfo::Handler member
function, which consumes them. So, the types of their data members
should match those of the corresponding arguments of the corresponding
Handler member function.
CallFrameInfo::OffsetRule and CallFrameInfo::ValOffsetRule use an
'int' to store the rule's offset value, but
CallFrameInfo::Handler::OffsetRule and ...::ValOffsetRule expect a
'long'. On ABIs where 'long' is larger than 'int', this can cause
values to be truncated or sign-extended unexpectedly.
This patch changes those members to 'long'.
Fortunately, offsets appearing in real DWARF call frame information
never even come close to the limits of a 32-bit int, so this bug is
unlikely to cause any practical problems.
A=jimb R=thestig
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@615 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch adds files defining new classes in the google_breakpad::Mach_O
namespace for parsing fat binaries and Mach-O files. These are used in the
new dumper to handle STABS debugging information, DWARF call frame
information, and .eh_frame exception handling stack walking information.
These new classes are independent of endianness and word size, and
therefore can be used on binaries of all the relevant architectures: x86,
x86_64, ppc, and ARM.
The patch adds a complete set of unit tests for the new classes.
A=jimb R=mark (http://breakpad.appspot.com/93001/show, http://breakpad.appspot.com/115001/show)
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@610 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
| |
Patch by Adam Langley <agl@chromium.org>. r=me
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@568 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The comments don't accurately describe what the style guide says.
Regardless of what the style guide says, RTTI seems to make trouble in
practice, because so many people build with it disabled. Since only the
symbol dumper uses RTTI, not the client library, it may be practical for
people to simply enable RTTI for the dumper. Failing that, it may be best
in the long run to violate the style guide and make the code work sans
RTTI.
a=jimblandy, r=mmentovai
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@561 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
| |
- Use manifest constants for 'z' augmentation letters.
- Fix typos and rearrange some code for legibility.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@560 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Extend google_breakpad::CFISection with the ability to produce
.eh_frame data. Entry headers have a different format, and pointers
can be encoded in new and fascinating ways.
Extend dwarf2reader::CallFrameInfo to be able to parse either DWARF
CFI or .eh_frame data, as determined by an argument to the
constructor. Cope with variations in header formats, encoded pointers,
and additional data in 'z' augmentation data blocks. Extend the unit
tests appropriately.
Extend dump_syms to look for a .eh_frame section, and if it is
present, find the necessary base addresess and parse its contents.
There's no need for DwarfCFIToModule to check the version numbers; if
CallFrameInfo can parse it, DwarfCFIToModule should be able to handle
it. Adjust tests accordingly.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@552 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
| |
The Linux C++ exception handling data format (.eh_frame) can specify a
number of different encodings for the addresses it contains. This
patch extends dwarf2reader::ByteReader to read pointers encoded in
these ways.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@551 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Define a new DWARF parser class, dwarf2reader::CallFrameInfo.
Extend google_breakpad::Module to store and write out 'STACK CFI' records.
Define a new google_breakpad::DwarfCFIToModule class, to accept DWARF
CFI data from the parser and populate a Module with the equivalent
STACK CFI records.
Extend the Linux symbol dumping tool, dump_syms, to use
dwarf2reader::CallFrameInfo, google_breakpad::DwarfCFIToModule, and
google_breakpad::Module to extract DWARF CFI from the executable or
shared library files and write it to the Breakpad symbol file.
Define CFISection, a new class derived from TestAssembler::Section,
for use in creating DWARF CFI data for test cases.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@550 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is preparation for adding support for reading Linux C++ exception
handling data's encoded pointers. The change should have no user-visible
effect; it simply expands the comments for dwarf2reader::ByteReader, and
regroups the member functions.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@522 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Without this patch, debugging information like the following will produce
FUNC records with no names, because the dumper (correctly) ignores the
DW_TAG_subprogram DIEs that lack DW_AT_low_pc/DW_AT_high_pc attributes, but
won't follow the DW_AT_abstract_origin link from the DIE that does have
code addresses to find its name.
<1><168>: Abbrev Number: 5 (DW_TAG_class_type)
<169> DW_AT_name : Foo
<2><183>: Abbrev Number: 7 (DW_TAG_subprogram)
<185> DW_AT_name : Foo
<18b> DW_AT_declaration : 1
<1><1b7>: Abbrev Number: 12 (DW_TAG_subprogram)
<1b8> DW_AT_specification: <0x183>
<1bc> DW_AT_inline : 2 (declared as inline but ignored)
<1><1dc>: Abbrev Number: 16 (DW_TAG_subprogram)
<1dd> DW_AT_abstract_origin: <0x1b7>
<1e1> DW_AT_low_pc : 0x8048578
<1e5> DW_AT_high_pc : 0x8048588
a=dmuir, r=jimblandy
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@520 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This also includes some comments I promised Cary Coutant I'd write
about the appropriateness of processing attributes in EndAttributes
calls.
The Google C++ Style Guide requires each file to have an author notice
and a comment explaining the file's general purpose. For the record, I
don't think putting an author notice on the files is a good idea; it's
odd to have the original author retain prominence even if the file has
been heavily edited by others; the version control system answers this
question more accurately. This is only for Style Guide compliance. The
Apache group decided to discourage author annotations, partially for
these reasons:
http://mail-archives.apache.org/mod_mbox/jakarta-jmeter-dev/200402.mbox/%3C4039F65E.7020406@atg.com%3E
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@518 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
| |
We've gotten mixed advice from the lawyery types about whether this
matters. But it's easy enough to do.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@517 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
| |
This patch moves the ReadInitialFunction from dwarf2reader.cc, where
it was a static function, to being a member function of
google_breakpad::ByteReader.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@504 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
| |
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@496 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
dwarf2reader::CompilationUnit is a simple and direct parser for DWARF
data, but its handler interface is not convenient to use. In
particular, the same handler object receives data about all DIEs
processed. One can't use distinct classes to separate the information
needed to handle different kinds of data.
This patch defines a new adapter type, dwarf2reader::DIEHandler, which
implements the existing DWARF parser's handler interface, given a
handler written to a more comfortable, object-orient interface. The
comments in dwarf2diehandler.h provide more detail.
a=jimblandy, r=ccoutant
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@495 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
length.
Breakpad's DWARF line number info parser provides a code address,
file, and line number for each code/source pairing, but doesn't
provide the length of the machine code. This makes that change, as
discussed in the following thread:
http://groups.google.com/group/google-breakpad-dev/browse_thread/thread/ed8d2fde79319368p
This patch also makes the corresponding changes to the functioninfo.cc
module, used by the Mac dumper. This patch has no effect on the Mac
dumper's output.
a=jimblandy, r=ccoutant
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@494 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
| |
The DWARF specification specifices which names the sections containing
DWARF information should have. OSX uses slightly different names. This
patch changes the DWARF reader to look for the sections under both
sets of names.
a=jimblandy, r=ccoutant
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@493 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a new member function to dwarf2reader::Dwarf2Handler,
ProcessAttributeReference, for reporting attribute values that are
references to other DIEs. This handler member function always receives
an absolute offset (that is, relative to the start of the .debug_info
section, not to the start of the compilation unit), regardless of the
form the attribute uses. (Some forms are CU-relative, some are
absolute.)
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@482 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
| |
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@479 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix typos.
For CompilationUnit::Start, I was confused by the '-' in the original
comment, taking it for a parenthetic clause marker, assuming an
implicit "of the next compilation unit" at the end of the sentence.
The comments should refer to the ".debug_info" section, not the
"debug_info" section. The latter is not the section name actually used
on any system (ELF or Mach-O), and the former is the name prescribed
by the DWARF spec.
Some of the comments for ProcessAttribute* member functions claim that
OFFSET is from the start of the compilation unit, but that's not so:
the code has always passed an offset relative to the start of the
.debug_info section.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@453 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
| |
GNU C++ 4.3.3.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@450 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
src/common/dwarf/dwarf2reader.cc uses the old-fashioned <stdio.h>
facilities to report errors. Ideally, we would add a 'Warning' message
to the handler and make the client responsible for dealing with the
errors, but this at least allows us to compile.
Ubuntu 9.10 uses GCC 4.4.1; under older versions of GCC, this wasn't a
problem, probably because stdio.h was being brought in inadvertently
somewhere else.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@449 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It seems that a use of the <stdint.h> type uintptr_t has crept into
the DWARF parser. This defines a workaround for the GNU compilers
(tested on both Mac and Linux) which will raise an error if it doesn't
work.
My personal preference would be just to assume that the <stdint.h>
header is available and use the standard types everywhere, but 1) that
would be a large change, likely to make merges with the other branches
of the DWARF parser more difficult, and 2) it would make it quite
difficult to build under Microsoft Visual Studio, which doesn't have
the <stdint.h> header; Microsoft has said they have no plans to
provide it, as they would rather "focus their efforts" on C++ and
.NET.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@448 4c0a9323-5329-0410-9bdc-e9ce6186880e
|
|
platform-independent directory.
Move the DWARF parser, and the functioninfo.cc DWARF consumer, from
src/common/mac/dwarf to src/commmon/dwarf, so that it can be shared
between the Mac and Linux dumpers.
Fix up #include directives, multiple inclusion protection macros, and
Xcode build files.
a=jimblandy, r=nealsid
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@446 4c0a9323-5329-0410-9bdc-e9ce6186880e
|