1
0
Fork 0
mirror of https://github.com/tobast/libunwind-eh_elf.git synced 2024-11-05 17:24:30 +01:00
Commit graph

1296 commits

Author SHA1 Message Date
hp.com!davidm
ee6eeb4f7d (get_script_cache): Use HAVE_ATOMIC_H instead of __linux && __KERNEL__.
(Logical change 1.294)
2005-05-20 09:48:08 +00:00
hp.com!davidm
8a1e0a2bcd Auto merged
2005/05/17 14:14:23-07:00 hp.com!davidm
(tdep_access_reg): Access AR.EC via ec_loc instead of cfm_loc.

(Logical change 1.293)
2005-05-17 21:28:19 +00:00
hp.com!davidm
26fdb45d76 Auto merged
2005/05/17 14:14:23-07:00 hp.com!davidm
(linux_sigtramp): Add "prev_cfm_loc" argument.  Use it to set c->ec_loc.
(linux_interrupt): Likewise.
(hpux_sigtramp): Likewise.
(update_frame_state): Copy old cfm_loc to prev_cfm_loc and pass it to
	ABI-specific handlers.  Initialize c->ec_loc to c->cfm_loc by default.

(Logical change 1.293)
2005-05-17 21:28:19 +00:00
hp.com!davidm
a6ba57d556 Auto merged
2005/05/17 06:10:13-07:00 hp.com!davidm
(tdep_access_reg): Don't rotate contents of UNW_IA64_PR.

(Logical change 1.292)
2005-05-17 13:24:49 +00:00
hp.com!davidm
8462f1f87d (pr_ltop): Remove.
(pr_ptol): Remove.

(Logical change 1.292)
2005-05-17 13:24:49 +00:00
mostang.com!davidm
23884c98cb Rename: src/sigsetjmp.c -> src/setjmp/sigsetjmp.c
}(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
4d7f2a5be7 Rename: src/sigsetjmp.c -> src/setjmp/sigsetjmp.c
(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
5ac5853589 Rename: src/setjmp.c -> src/setjmp/setjmp.c
}(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
8e06df0e52 Rename: src/setjmp.c -> src/setjmp/setjmp.c
(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
9bc79a618b Rename: src/dwarf/dwarf-eh.h -> include/dwarf-eh.h
}(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
06d223e924 Initial revision 2005-05-03 09:13:17 +00:00
mostang.com!davidm
4e833d43fc Include "setjmp_i.h".
Abstract ia64-specific code into bsp_match() routine.
Support any platform with at least 2 EH argument registers.

}(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
4f16756123 Include "setjmp_i.h".
Abstract ia64-specific code into bsp_match() routine.
Support any platform with at least 2 EH argument registers.

2004/12/06 01:33:16-08:00 mostang.com!davidm
Rename: src/longjmp.c -> src/setjmp/longjmp.c

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
203c0a5363 Include "setjmp_i.h".
Abstract ia64-specific code into bsp_match() and
resume_restores_sigmask() routines.

}(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
acf90b1f82 Include "setjmp_i.h".
Abstract ia64-specific code into bsp_match() and
resume_restores_sigmask() routines.

2004/12/06 01:33:01-08:00 mostang.com!davidm
Rename: src/siglongjmp.c -> src/setjmp/siglongjmp.c

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
239ea4e7ea Implement for real. Note: this version is currently broken.
We don't pass sigmask the way this routine expects because it
can't work.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
7a5549f2d8 Drop "inline" since it's now part of ALWAYS_INLINE.
(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
411331eecb Delete: src/hppa/Lget_reg.c
}(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
ca02ad1708 Delete: src/hppa/Lget_proc_name.c
}(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
181bddfba0 Delete: src/hppa/Gget_reg.c
}(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
f45210852c Delete: src/hppa/Gget_proc_name.c
}(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
10a269d6d0 Also enable DWARF code for UNW_TARGET_HPPA.
2004/11/23 16:59:56-08:00 mostang.com!davidm
(_UPTi_find_unwind_table): Implement first draft for x86/-64.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
b267dfc8c9 Adjust for sigset_t to intrmask_t renaming.
}(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
dc89a17613 Adjust for sigset_t to intrmask_t renaming.
2004/12/02 00:40:45-08:00 mostang.com!davidm
Add copyright notice.
Provide canonical DWARF-based implementation.

2004/11/30 23:38:42-08:00 mostang.com!davidm
Rename: src/hppa/global.c -> src/hppa/Gglobal.c

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
1f5ac0f5bd Adjust for sigset_t to intrmask_t renaming.
2004/11/17 02:43:39-08:00 mostang.com!davidm
(struct callback_data): New structure.
(linear_search): New function.
(callback): Convert to getting auxiliary info passed via a pointer to
	a callback_data structure, rather than an unw_dyn_info_t
	structure.
	Keep track of the maximum load address in max_load_addr.
	If an object doesn't have a binary search-table, fall back
	on a linear search.
(dwarf_find_proc_info): Fill in callback-data structure before calling
	dl_iterate_phdr().  Upon returning, check whether
	cb_data.single_fde is set and, if so, return directly, without
	searching the DWARF unwind-table.
(dwarf_search_unwind_table): Adjust for renaming of
	dwarf_parse_fde() to dwarf_extract_proc_info_from_fde().
	If IP doesn't fall into the IP-range of the FDE-entry found
	by the search, return UNW_ENOINFO.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
7fbb8a9593 Adjust for sigset_t to intrmask_t renaming.
(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
9f3360a546 Adjust for "ia64_rse" to "rse" prefix change.
2005/02/23 12:55:45-08:00 mostang.com!davidm
(inlined_uc_addr): Adjust for ALWAYS_INLINE change.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
7f8b54ae5c Adjust for "ia64_rse" to "rse" prefix change.
2005/02/20 21:42:55-08:00 mostang.com!davidm
Adjust for NELEMS to ARRAY_SIZE renaming.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
3f73836b87 Adjust for "ia64_rse" to "rse" prefix change.
2004/12/15 15:40:09-08:00 hp.com!davidm
Include "tdep.h" on ia64 (we need the cursor).
(bsp_match): Fix it so it compiles again.
(resume_restore_sigmask): Likewise.

2004/12/06 10:40:49-08:00 mostang.com!davidm

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
3e00b79170 Adjust for "ia64_rse" to "rse" prefix change.
2004/12/06 10:40:49-08:00 mostang.com!davidm
(tdep_access_reg): Fix typo in code to read EH argument registers.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
4849af2d09 Adjust for "ia64_rse" to "rse" prefix change.
2004/11/23 16:59:56-08:00 mostang.com!davidm
(_UPT_access_reg): If the register is out of range, set errno
	to EINVAL.
	When encountering an error while accessing a register,
	print the corresponding error string.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
87081cebab Adjust for "ia64_rse" to "rse" prefix change.
2004/10/25 07:52:30-07:00 hp.com!davidm
(unw_step): Add Debug statement to print return-value.

2004/10/25 05:21:51-07:00 hp.com!davidm
(unw_step): Print IP along with cursor address.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
bf832fc29e Adjust for "ia64_rse" to "rse" prefix change.
(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
3f16641760 (x86_local_resume): Delete unused code.
(establish_machine_state): Fix off-by-one error.
	Fix Debug-statement formatting & debug-level.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
17bf4d0af8 (unw_step): If dwarf_step() fails and the frame doesn't look like
a signal-trampoline, assume that it's a PLT stub.
	If non-DWARF stepping fails to change IP and CFA, declare
	it a bad frame.

2004/11/23 16:59:56-08:00 mostang.com!davidm
(unw_step): Also print IP as part of the function-trace.

2004/11/23 16:17:37-08:00 mostang.com!davidm
(unw_step): When dwarf_step() fails on a signal-frame, fill in all
	the known locations because dwarf_step() fails on older
	kernels which don't export the kernel vDSO even though every-
	thing else may be providing proper DWARF unwind-info.

2004/10/25 17:43:57+02:00 homeip.net!davidm
Add Debug statement for return-value.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
fa0828ac7d (unw_step): Also print IP as part of the function-trace.
2004/11/23 12:49:54-08:00 mostang.com!davidm
(unw_step): If dwarf_step() fails on a signal-frame, fill in the
	save-locations for everything that gets saved in the
	sigcontext structure.

2004/10/25 17:43:57+02:00 homeip.net!davidm
Add Debug statement for return-value.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
93599dc278 (unw_init_local): Implement it based on the DWARF unwinder.
(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
0f27732d35 (unw_get_proc_info): Implement it based on dwarf_make_proc_info().
(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
7ac9665fd3 (unw_get_proc_info): Don't freak out if dwarf_make_proc_info() fails.
Unfortunately, it must fail for current versions of libc
	since they fail to provide unwind-info for _start() and
	_dl_start().

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
b1b84400b9 (tdep_uc_addr): Define as HIDDEN.
(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
db1517609c (tdep_access_reg): Buffer writes to EH argument registers (EAX
and EDX) in dwarf.eh_args[].


2004/11/17 02:43:39-08:00 mostang.com!davidm
(tdep_access_reg): Treat UNW_X86_ESP exactly like UNW_X86_CFA.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
caa61dfec1 (remote_install_cursor): Fix off-by-one error.
2004/10/25 05:21:51-07:00 hp.com!davidm
(unw_resume): Print IP along with cursor-address.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
46b7b8196c (is_cie_id): New function.
(parse_cie): Adjust for moving DWARF2 extra-info from
	unw_dyn_dwarf_fde_info_t to dwarf_cie_info.
	Add support for `S' augmentation ("special frames").
(dwarf_extract_proc_info_from_fde): Rename frm dwarf_parse_fde().
	Convert to returning data via dwarf_cie_info rather than
	unw_dyn-dwarf_fde_info_t.  Allow 0-length FDE since those
	can be used to indicate the end of the FDE-table.  Return
	the end of the FDE via *ADDRP.  Ignore CIEs (we may pick them
	up during linear searches through the FDE-table).
	Fill in the unwind-info only if really needed.  When needed,
	return the info via a dynamically allocated dwarf_cie_info
	structure.  Add support for `S' augmentation (ABI/tag pairs).

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
c14371409a (fetch_proc_info): Decrement IP before searching for dynamic/static
unwind-info, since DWARF expects us to do so (unlikey for ia64,
	where we are guaranteed that the (return) IP points to the
	correct unwind-info).

2004/11/17 02:43:39-08:00 mostang.com!davidm
(run_cfi_program): Switch over to using dwarf_cie_info instead of
	unw_dyn_dwarf_fde_info_t.
(fetch_proc_info): Clear c->pi before filling it in.
(put_unwind_info): If we got non-dynamic unwind-info, free it
	via a call to mempool_free().
(parse_fde): Switch over to using dwarf_cie_info instead of
	unw_dyn_dwarf_fde_info_t.
(apply_reg_state): Drop accessees to c->cfa_is_sp.

2004/10/25 17:38:51+02:00 homeip.net!davidm
Fix typo: DW_CFA_CFA_expression -> DW_CFA_expression.

2004/10/21 11:15:44+02:00 homeip.net!davidm
Auto merged

2004/10/21 11:15:12+02:00 homeip.net!davidm
(run_cfi_program): Add missing newline in Debug statement.
(apply_reg_state): It was wrong to do a dwarf_get() on the CFA-location
	returned by eval_location_expr().  Instead, we must make sure
	we're dealing with a memory-location and, if so, just extract
	the memory address as the CFA.
	Also, update c->cfa only _after_ the other frame-state has
	been updated.  This seems to be necessary for correct parsing
	of the sigtramp unwind info.  Not sure yet this is 100% correct,
	but it gets us through Gtest-resume-sig.

2004/10/19 23:24:56-07:00 mostang.com!davidm
(run_cfi_program): Fix typos in Debug statements.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
4502aa0ff2 (dwarf_read_encoded_pointer): Implement simply by calling
dwarf_read_encoded_pointer_inlined().

2004/11/17 02:43:39-08:00 mostang.com!davidm
(dwarf_read_encoded_pointer): Declare proc-info-pointer argument
	as "const".

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
3239e7db60 (dwarf_cie_info_pool): New variable.
(dwarf_init): Initialize dwarf_cie_info_pool.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
bbe87ea403 (common_init): Don't forget to clear c->dwarf members args_size,
ret_addr_column, pi_valid, and pi_is_dynamic.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
7fcb8006a9 (common_init): Adjust for ALWAYS_INLINE change.
(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
8a66c9c635 (access_reg): Delete left-over Debug statement.
(Logical change 1.290)
2005-05-03 09:13:17 +00:00
mostang.com!davidm
9c025efac2 (_UI_siglongjmp_cont): Provide dummy implementation.
(_UI_longjmp_cont): Likewise.

(Logical change 1.290)
2005-05-03 09:13:17 +00:00