(access_reg) [HAVE_SYS_UC_ACCESS_H]: Sanitize and simplify this routine. Turns out
uc_access(3) works pretty much the way we need it, the only problem is that
the unwind info for getcontext() seems to be missing as of HP-UX 11.22.
(ia64_uc_access_reg): New function.
(ia64_uc_access_fpreg): Ditto.
(ia64_local_addr_space_init): Initialize "abi" member of local address space based
on the platform we're compiling on.
(Logical change 1.87)
nice backtrace, handling unwinding across signal handlers just fine. Main missing
piece right now is that unw_resume() doesn't work because uc_access(3) refuses to
write ar.bsp. Duh.
BKrev: 3ea84cd3PHuNw5JsGXBuCzkJLDGUcA
have an empty file here, as otherwise we won't get a valid program.
2003/04/24 12:58:16-07:00 mostang.com!davidm
Rename: src/ia64/Lmk_cursor_i-ia64.c -> src/ia64/mk_Lcursor_i-ia64.c
(Logical change 1.87)
(remote_install_cursor): Enable the short-cut for Linux only. Since HP-UX uses
an opaque data-structure for ucontext_t, we can't play the same trick
there. Fix two typos: "> 0" -> ">= 0".
(unw_resume): Handle non-UNW_LOCAL_ONLY case simp;u bu calling
remote_install_cursor().
(Logical change 1.87)
support for HP-UX.
(access_nat): Check for uc-location and pass it on to ia64_put()/ia64_get() if
it is. Handle NaT-bit-saved-in-scratch-register only for Linux.
(ia64_access_reg): Change dprintf() into debug() statement.
(ia64_access_fpreg): Move fph-partition initialization code to ia64_scratch_loc().
Change dprintf() into debug() statement.
(Logical change 1.87)
(foo): Add some newlines for better readability.
(sighandler): Always declare as per Single UNIX Spec.
On HP-UX, use __uc_get_ip() to read the interruption IP.
(main): Always use sigaction() to install a signal handler, so we can
turn on the SA_SIGINFO flag.
(Logical change 1.87)
end up not using it.
(UNWIND_TBL_32BIT): New macro.
(struct unwind_header): Rename "unknown1" member to "header_version".
(tdep_find_proc_info) [HAVE_DLMODINFO]: Don't forget to initialize di.gp.
Check unwind-header version and format.
(Logical change 1.87)
Rename Gmk_cursor to mk_Gcursor, Lmk_cursor to mk_Lcursor so to avoid
scripts/make-L-files overwriting the (handcrafted) local version.
(EXTRA_DIST): Mention libunwind_la_SOURCES_os_hpux.
(Logical change 1.87)
Update code to work both for UNW_LOCAL_ONLY-version of the cursor and the
generic version of the cursor.
(ia64_install_cursor): New macro.
}(Logical change 1.85)
Update code to work both for UNW_LOCAL_ONLY-version of the cursor and the
generic version of the cursor.
(ia64_install_cursor): New macro.
2003/04/23 11:25:31-07:00 mostang.com!davidm
Rename: src/ia64/_Uia64_install_cursor.S -> src/ia64/Ginstall_cursor.S
(Logical change 1.85)
and Linstall_cursor.S.
(Gmk_cursor_i_ia64_SOURCES): Rename from mk_cursor_i_ia64_SOURCES.
(Lmk_cursor_i_ia64_SOURCES): New mcro.
(Gcursor_i.h): Rename rule from cursor_i.h.
(Lcursor_i.h): New rule.
(noinst_PROGRAMS): Rename mk_cursor_i-ia64 to Gmk_cursor_i-ia64 and add
Lmk_cursor_i-ia64.
(BUILT_SOURCES): Ditto.
(Logical change 1.85)
more or less unchanged, but for the generic version, the save-location has been
expanded from a single word to two words. This is needed to accommodate 32-bit
targets and targets which require accessing the ucontext_t structure via uc_access(3).
Overall, this should be like a big no-op for Linux (apart from slowing down
the generic case a bit). However, at the moment, unw_resume() has not been updated
for the generic case (UNW_LOCAL_ONLY works fine though).
BKrev: 3ea62b2bm3Pz-s7tNlN5IA-1ENWKWw
(struct_offset): Delete.
(IA64_LOC_REG): New macro (replaces IA64_LOC() for registers).
(IA64_LOC_ADDR): New macro (replaces IA64_LOC() for addresses).
(IA64_LOC_UC_ADDR): New macro.
(IA64_NULL_LOC): Ditto.
(IA64_IS_NULL_LOC): Ditto.
(IA64_IS_UC_LOC): Ditto.
(struct ia64_state_record): Replace is_signal_frame bit with abi_marker.
(ia64_strloc): New declaration.
(rbs_switch): Change from UNW_ARCH_OBJ() to UNW_OBJ().
(rbs_find_stacked): Ditto.
(rbs_cover_and_flush): Ditto.
(rbs_get_rnat_loc): New inline function.
(rbs_loc): Ditto.
(Logical change 1.84)
Adjust for renaming of Linux sigcontext offset macros.
(check_rbs_switch): Handle Linux-case only if abi_marker==ABI_MARKER_LINUX_SIGTRAMP.
(update_frame_state): For cursor's with a non-zero abi_marker, do special
Linux or HP-UX sigtramp handling as appropriate.
Clear abi_marker instead of is_signal_frame.
(Logical change 1.84)
(emit_nat_info): For registers saved in a general-register, use IA64_INSN_SET_REG
instead of IA64_INSN_SET.
Set insn.dst to register number, instead of unw.preg_index[i].
(compile_reg): Set val directly to register number, instead of unw.preg_index[i].
Use IA64_INSN_INC_PSP instead of IA64_INSN_ADD to pop a fixed stack frame.
(build_script): Handle signal-frames by directly copying abi_marker, rather than
emitting an IA64_INSN_SET instruction.
(run_script): Copy abi_marker into cursor. Rather than updating a word, update
a save-location. Only exceptions are IA64_INSN_INC_PSP and
IA64_INSN_LOAD_PSP.
(Logical change 1.84)
(ia64_loc_t): New type. For UNW_LOCAL_ONLY, it's a single word, as before.
For the generic case, it's a 2-word structure. This provides enough
space to encode all necessary info both for 32-bit targets (which require
only 4-byte aligned addresses) and for targets which are limited to
accessing ucontext_t values via uc_access(3).
(ABI_MARKER_LINUX_SIGTRAMP): New macro.
(ABI_MARKER_HP_UX_SIGTRAMP): New macro.
(struct cursor): Consolidate bsp_loc, bspstore_loc, pfs_loc, rnat_loc, ip_loc,
pri_unat_loc, unat_loc, pr_loc, lc_loc, fpsr_loc, r4-r7_loc,
b1-b5_loc, f2-f7_loc, and fr_loc[] into loc[] array. Note that
there is now a separate PSP-loc (loc[IA64_REG_PSP]) in addition
to the cached psp value.
Rename sigcontext_loc to sigcontext_addr.
Remove is_signal_frame memeber and add abi_marker member instead.
Change type of rbs_area[].rnat_loc to ia64_loc_t.
(struct ia64_global_unwind_state): Remove preg_index[] array.
(Logical change 1.84)
Mask out only the least-significant 2 bits (rather than the least significant
3 bits).
2003/04/22 22:15:48-07:00 mostang.com!davidm
Rename: src/ia64/_Uia64_install_context.S -> src/ia64/_Uia64_install_cursor.S
(Logical change 1.84)