mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-07-03 09:48:29 +00:00
Improve backtraces
We're now able to rewind the instruction pointer in x86 backtraces. This helps ensure addr2line cannot print information about unrelated adjacent code. I've restored -fno-schedule-insns2 in most cases because it really does cause unpredictable breakage for backtraces.
This commit is contained in:
parent
cd672e251f
commit
9b6718ac99
11 changed files with 118 additions and 24 deletions
10
libc/intrin/iscall.internal.h
Normal file
10
libc/intrin/iscall.internal.h
Normal file
|
@ -0,0 +1,10 @@
|
|||
#ifndef COSMOPOLITAN_LIBC_INTRIN_ISCALL_H_
|
||||
#define COSMOPOLITAN_LIBC_INTRIN_ISCALL_H_
|
||||
COSMOPOLITAN_C_START_
|
||||
|
||||
// returns true if `p` is preceded by x86 call instruction
|
||||
// this is actually impossible to do but we'll do our best
|
||||
int __is_call(const unsigned char *);
|
||||
|
||||
COSMOPOLITAN_C_END_
|
||||
#endif /* COSMOPOLITAN_LIBC_INTRIN_ISCALL_H_ */
|
Loading…
Add table
Add a link
Reference in a new issue