| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Bug: http://b/27299236
Change-Id: I26ef47f80d4d6048a316ba51e83365ff65d70439
|
|
|
|
|
|
|
|
|
|
|
|
| |
If the signal handler doesn't fire in the given time when trying to unwind
a thread, put on a logging handler. This prevents crashes if the signal
does eventually fire.
Bug: 23783762
(cherry picked from commit d7226f9a1485ba19f714369fd7f8b444d66feb61)
Change-Id: Ib990a06733cc93717752ab4998f4ae26afd7e249
|
|
|
|
|
|
|
|
|
|
|
| |
The dlopen of a shared library in an apk results in large map offsets.
Unfortunately, the current way that the frame data is printed, it's
impossible to tell what the relative pc is relative to. With the
addition of the offset, it's possible to figure out what the relative
pc actually references.
Bug: 23348999
Change-Id: Ia51b669ea3f810158cfd0d71d9ae89bf9a3170d3
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This error message has no meaning and makes it look like an unwinding
failure occurred. These messages are showing up more often now
that a lot more of debuggerd is using the ReadWord and Read calls.
If a higher level function wants to indicate there is an error, then
it can add a more meaningful error.
Bug: 21818730
(cherry picked from commit 35c8136d96a6007ac83f828ac02cc6b75d3f5cc0)
Change-Id: Ie6e20fbc18702fde935f2cf8cbf1b297fda43282
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If the signal to dump a thread is never delivered, then it's
possible for a deadlock. The signal handler is responsible for
unlocking and deleting the ThreadEntry created for the pid/tid
combination. This means if the signal is lost, the ThreadEntry
gets stuck locked and never deleted. If a second attempt to get
a backtrace of this thread occurs, there is a deadlock.
Also, decrease the timeout from 10 seconds to 5 seconds. The original
10 seconds was because the unwind was actually done in the signal
handler. Now the signal handler does nothing but copy the ucontext
structure and let the caller do the unwind.
Bug: 21086132
(cherry picked from commit 2d09171758b7d98c77f27e439a4caf35dd84c311)
Change-Id: I414c500eb08983a5017caf3fce4f499465575a9d
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Under some conditions, /proc/<pid>/maps might return nothing. If we
try and unwind in this case, we'll crash. Check this case and fail
the unwind.
Add checks that no other functions try and use map_ without
checking for nullptr.
Add logging when an unwind fails so it's clear what happened.
Bug: 21162746
Change-Id: I56ce51dda0cfc9db20475a441f118108196aa07c
(cherry picked from commit 30c942cf1024bf791c28ab9b67a1f752de72248c)
|
|
|
|
|
|
|
| |
Bug: 19517541
(cherry picked from commit 67aba6881d8857d3017e11695207eb2ade45a274)
Change-Id: I914636ccd814e041475b6b2d81119cac1745a9ff
|
|
|
|
|
|
|
|
|
|
|
| |
Also simplifies the Darwin implementation of gettid, because
apparently libbacktrace had a better way of doing it.
Bug: 19517541
(cherry picked from commit 23f750b068ddf5b20fb5d153a798b22562368992)
Change-Id: I2f888e8ed7a2f5719973786cbcbb399a81867ee9
|
|
|
|
|
|
|
|
|
|
|
| |
The BacktracePtrace::Read function crashes if the number of bytes to
read is less than the number of bytes needed to align the read to
a word_t boundary.
Fix this and add a test for this case.
Change-Id: I50808849ece44928f65dba1d25309e3885c829a2
(cherry picked from commit 944f417ccb86441060ffb670b4bdc2975fda08fc)
|
|
|
|
|
|
|
|
| |
Also, print the offset in the maps section.
Bug: 20864928
Change-Id: I71f005726e5ef73cf75bbcb8f829fd5127cb9d61
(cherry picked from commit 5c8856854de4ae7836fc1073d534f4b7b7a03eb9)
|
|
|
|
|
|
|
|
|
|
| |
The new linker relocation packing support uses non-zero load bases,
so we better handle them properly.
Also print out the load base for a map if it's non-zero.
Bug: 20687795
Change-Id: Iec2d1db2051e7b4a278c1dfa57d745128a7f2974
|
|
|
|
| |
Change-Id: Iae4a73546f672c208ffe1b224e8d9a9e693f95f0
|
|
|
|
| |
Change-Id: Id3b0b96a33441ce5d908aac38e639ac3598a7a89
|
|
|
|
|
|
|
|
| |
When doing a local unwind, do not include the frames that come
from either libunwind or libbacktrace.
Bug: 11518609
Change-Id: I0ec8d823aebbfa0903e61b16b7e5663f3fd65e78
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| | |
The object hierarchy was confusing and convoluted. This removes
a lot of unnecessary code, and consolidates the BacktraceCurrent
and BacktraceThread code into BacktraceCurrent.
Change-Id: I01c8407d493712a48169df49dd3ff46db4a7c3ae
|
|\ \
| |/
|/| |
|
| |
| |
| |
| |
| |
| |
| |
| | |
The latest clang (r230699) does not allow SP/PC to be declared in inline asm
lists. This is a problem for libraries that are attempting to save all
register state.
Change-Id: I1ce80530f8be85fd74e949d0c65b60080e0aaf2a
|
| |
| |
| |
| |
| |
| | |
This is a no-op.
Change-Id: Iecbcd5f6d818abbf98767a2e996c10f454b652e4
|
|/
|
|
|
|
| |
Otherwise it may have problems unwinding over itself.
Change-Id: I9b0d108018ae3f5d98b9ae6fb62d0af83a77d18e
|
|
|
|
|
|
|
|
|
|
| |
Included tests for this new feature.
Changed the NULLs to nullptr in backtrace_test.
Changed UniquePtr to std::unique_ptr in backtrace_test.
Change-Id: I92375465b8f8ba84589834cc162db5915bf1be81
|
|
|
|
|
|
|
|
|
|
|
| |
The backtrace structure used to include a pointer to a backtrace_map_t
that represented the map data for a particular pc. This introduced a
race condition where the pointer could be discarded, but the backtrace
structure still contained a pointer to garbage memory. Now all of the map
information is right in the structure.
Bug: 19028453
Change-Id: If7088a73f3c6bf1f3bc8cdd2bb4b62e7cab831c0
|
|
|
|
|
| |
Bug: 18930951
Change-Id: Ib7fd332b6e02241c0676ef33d2fa210a72efe1b1
|
|
|
|
|
|
| |
Removed unnecessary libbacktrace_c_includes variable
Change-Id: I2ef29dc9810f7d9a7dcf5c232e9e85d2fc2fd5e8
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Switch to the better supported pthread_cond to handle the Wait/Wake
functions.
Also, increase the number of simultaneous threads in the thread tests.
Bug: 18381207
(cherry picked from commit db44538387b08f367fc2419653639866f4c2fbd6)
Change-Id: Id326a7a7b92cb61573def3f761597c40f3ef2f4b
|
|
|
|
|
|
|
| |
This was previously set for libbacktrace_libc++, but apparently never
was for libbacktrace.
Change-Id: I85dc44b356710c6367f5cea3bc0a4d6c817ca202
|
|
|
|
|
|
|
| |
Rename the libc++ linked libbacktrace to the normal name.
Bug: 15193147
Change-Id: I75caf1ee527e3703825e0db757497fb8fa3dd122
|
|\
| |
| |
| |
| |
| |
| | |
BacktraceMap::Create on darwin"
* commit '2ea89b631d58ecd8edd7165ed8840d1e1047aa72':
Add uncached argument to BacktraceMap::Create on darwin
|
| |
| |
| |
| | |
Change-Id: I247a98fc3b98879a0c34a975f9914ccec95d1a04
|
| |
| |
| |
| |
| |
| | |
(cherry picked from commit f02593b0e61f8108449770094caa7bb39a646ec1)
Change-Id: I2012bf2dc553ebc663345b9eac6d794e80df9c00
|
|\ \
| | |
| | |
| | |
| | | |
* commit 'f02593b0e61f8108449770094caa7bb39a646ec1':
Allow getting an uncached process map.
|
| | |
| | |
| | |
| | | |
Change-Id: I58d7e90a7b5c4476a4b9f51640c54d13748ac220
|
|\ \ \
| |/ /
|/| /
| |/
| | |
* commit '83ddddaaba0fea8a1c0dcc64e795112bed67815f':
Update makefiles for host clang.
|
| |
| |
| |
| |
| |
| | |
bug 16172793
Change-Id: If7484c5dbcccce7d925bec97bff0a3e4c30e9434
|
|\ \
| |/
| |
| |
| |
| |
| | |
be multilib on the Mac too."
* commit '38dda3b8887286c44964dda0ce1c96425d9744f0':
libbacktrace_libc++ needs to be multilib on the Mac too.
|
| |
| |
| |
| | |
Change-Id: I2053345253c1d57c3485b790163ba0b4b10cc326
|
|\ \
| |/
| |
| |
| |
| |
| | |
testing."
* commit '4436749284dc2b74e6e0f430d0f803d1b7862d19':
Enable host multilib for ART testing.
|
| |
| |
| |
| | |
Change-Id: Ic3ae5122eba13565fb5a4cb1bd0e7e465fb2140c
|
|\ \
| |/
| |
| |
| |
| |
| | |
libbacktrace on the host for Mac."
* commit '2b95811601b05db7894359f037005a008274a973':
Build the libc++ variant of libbacktrace on the host for Mac.
|
| |
| |
| |
| |
| | |
Bug: 13751317
Change-Id: Iefadec1cd9b3ca109ac436bd5eb7c096c2dcbe40
|
|\ \
| |/
| |
| |
| |
| |
| | |
sigcontext."
* commit '012090e57b697133ad6f7d989e103d71302749f8':
Only copy mcontext data from sigcontext.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The ucontext_t data structure could be bigger than the kernel data
structure. Since the unwinder only cares about the mcontext data, only
copy that out of the structure. The mcontext data is the same size in
the kernel and in the ucontext_t structure.
Bug: 15189014
Change-Id: I5978169c4425b8212e11db85a57eb319cd0e264b
|
|\ \
| |/
| |
| |
| |
| |
| | |
from host libbacktrace"
* commit '633a2e3b6a1d00257965a5772a5467a6df9911a5':
Remove libstdc++ dependency from host libbacktrace
|
| |\ |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The libc++ version of libbacktrace on the host was still linking against
libstdc++, and this was causing problems in art.
Change-Id: I1d14fb9e18abd074affcf46c8044407041970669
|
|\ \ \
| |/ /
| | |
| | |
| | | |
* commit '219e867f61755720af3cddb5e8d2fe0e198a27ab':
Add missing headers
|
| |/
| |
| |
| |
| |
| |
| | |
These headers are needed for pid_t and free when using libc++ headers (POSIX
does not require that the symbols be exposed with the previous includes).
Change-Id: Ia51a4fdfdbae7377130a43c401c2d8d241671d1e
|
|\ \
| |/
| |
| |
| | |
* commit 'c6112ca4b8d0712fdd4c0ab3258d3ceaf2f8064e':
Really fixes the ub branches
|
| |
| |
| |
| | |
Change-Id: I1d78f4e6c1d8086c2895f6739c3202e9ef74fee2
|
|\ \
| |/
| |
| |
| | |
* commit '3f01965b3d1335ffff57e15fd47e5d99400dad3f':
Fix unbundled branches
|