pollution when compiling with debugging enabled. The name-space
pollution came from the fact that functions won't be inlined in this
case and that ended up generating dead code with references to
non-existent functions.
(Logical change 1.154)
name-space pollution when compiling with debugging enabled. The
name-space pollution came from the fact that functions won't be
inlined in this case and that ended up generating dead code with
references to non-existent functions.
(Logical change 1.154)
(_Uia64_get_kernel_table): Define only when UNW_LOCAL_ONLY is not
defined.
(_Uia64_find_dyn_list): Likewise.
(ia64_local_validate_cache): Fix prototype (second argument was
missing).
(Logical change 1.154)
resolved within the library itself.
(is_local_addr_space): Define UNW_LOCAL_ONLY and generic versions.
(read_mem): New function.
(tdep_put_unwind_info): Define only if not UNW_LOCAL_ONLY.
(tdep_search_unwind_table): Rename from _Uia64_search_unwind_table().
Optimize away stuff that isn't needed for UNW_LOCAL_ONLY.
Use read_mem() instead of open-coding accesses via
access_mem() callback.
(get_kernel_table): Rename from _Uia64_get_kernel_table().
(_Uia64_get_kernel_table): Define for non-UNW_LOCAL_ONLY case so
that libunwind-ptrace.a can get to it.
}(Logical change 1.151)
resolved within the library itself.
(is_local_addr_space): Define UNW_LOCAL_ONLY and generic versions.
(read_mem): New function.
(tdep_put_unwind_info): Define only if not UNW_LOCAL_ONLY.
(tdep_search_unwind_table): Rename from _Uia64_search_unwind_table().
Optimize away stuff that isn't needed for UNW_LOCAL_ONLY.
Use read_mem() instead of open-coding accesses via
access_mem() callback.
(get_kernel_table): Rename from _Uia64_get_kernel_table().
(_Uia64_get_kernel_table): Define for non-UNW_LOCAL_ONLY case so
that libunwind-ptrace.a can get to it.
2004/01/03 00:33:30-08:00 hp.com!davidm
Rename: src/ia64/tables-ia64.c -> src/ia64/Gtables-ia64.c
(Logical change 1.151)
(unw_decode_r2): Likewise.
(unw_decode_r3): Likewise.
(unw_decode_p1): Likewise.
(unw_decode_p2_p5): Likewise.
(unw_decode_p6): Likewise.
(unw_decode_p7_p10): Likewise.
(unw_decode_b1): Likewise.
(unw_decode_b3_x4): Likewise.
(unw_decode_table): Remove.
(unw_decode): Do the first-level of decoding inline, rather than
through the unw_decode_table.
(Logical change 1.148)
(regname_len): New macro.
(regname_str): New macro.
(NREGS): New macro.
(unw_regname): Change it from using a regname[] array to using
a single string.
(Logical change 1.148)
the former to avoid compiler-warnings.
(run_script): Before doing the big switch, check for most common
case (IA64_INSN_MOVE_STACKED).
(Logical change 1.130)
(remote_lookup): New function.
(_Uia64_search_unwind_table): Handle UNW_INFO_FORMAT_REMOTE_TABLE.
(_Uia64_find_dyn_list): Take unw_dyn_info_t pointer argument instead of its
members and handle UNW_INFO_FORMAT_REMOTE_TABLE.
(Logical change 1.126)
not needed because we default to "no caching" and if the application
turns on caching via unw_set_caching_policy(), the cache will get
initialized at that time.
(Logical change 1.124)
(get_script_cache): Return NULL if caching is disabled. If
HAVE_ATOMIC_OPS_H is defined, set the busy flag and if
the script cache is busy already, return NULL.
(put_script_cache): Don't allow it to be called for UNW_CACHE_NONE case.
If HAVE_ATOMIC_OPS_H is defined, clear the "busy" flag via
AO_CLEAR.
(ia64_get_cached_proc_info): If we're unable to acquire the cache,
return -UNW_ENOINFO.
(script_init): New function.
(script_new): Replace open code with call to script_init().
(uncached_find_save_locs): New function.
(ia64_find_save_locs): Move code for uncached case to
uncached_find_save_locs(). If get_script_cache() is unable to
lock the script-cache, fall back to uncached_find_save_locs().
(ia64_script_cache_init): Delete.
(Logical change 1.124)
early. Always flush cache after changing the policy.
This is to ensure that the per-thread cache gets initialized
and no stale info remains.
(Logical change 1.118)
(ia64_init): Use unw.lock to protect against races during
initialization. Disable signal delivery during initialization
to ensure thread-safety (e.g., unw_init_local() may call
ia64_init() and the former must be thread-safe).
(Logical change 1.111)
personality-routine and LSDA address and dont' forget to
dereference the personality-routine function-pointer, so we
really get the address of the function-descriptor of the
personality routine.
(callback): Set the segment-base based on the segment that contains
the unwind-table. Normally, that the text segment but in
special cases, such as the kernel's gate DSO, it will be
in a different segment.
(Logical change 1.108)
hash-table, collision-chains, and hash-table in addition
to clearing the script's IP value. The latter wasn't nearly
sufficient because it could cause loops on the collision
chain...
(get_script_cache): Also lock the cache if global caching is in
effect. Take additional "saved_sigmaskp" argument.
After flushing the cache, update the cache generation
here.
(put_script_cache): New function.
(ia64_get_cached_proc_info): Adjust for get_script_cache() and
put_script_cache() changes.
(ia64_find_save_locs): Ditto.
(ia64_script_cache_init): Call flush_script_cache() instead of
opening-coding the equivalent code.
(Logical change 1.96)
state-record.
(ia64_fetch_proc_info): Rename from get_proc_info().
(create_state_record_for): Assert that c->pi_valid is TRUE at the
time of entry. Remove call to get_proc_info().
(Logical change 1.95)
a value that is potentially > 31. Casting it to (unsigned long)
is not enough on 32-bit platforms.
(create_state_record_for): Cast 0xf to (unw_word_t) instead of
(unsigned long) to avoid losing bits on 32-bit platforms.
(Logical change 1.92)
Linux kernel "struct pt_regs" layout.
(update_frame_state): Handle ABI_MARKER_OLD_LINUX_SIGTRAMP and
ABI_MARKRE_OLD_LINUX_INTERRUPT. Cast values of type unw_word_t
to (unsigned long) before printing them.
(Logical change 1.91)
(linux_scratch_loc): Add support for new pt_regs layout.
(access_nat): Check last_abi_marker instead of sigcontext_addr and
address-space ABI.
(Logical change 1.91)
(update_frame_state): Handle ABI_MARKER_LINUX_INTERRUPT by calling linux_interrupt().
If c->abi_marker is non-zero, copy it to c->last_abi_marker.
(Logical change 1.89)
(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)
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)
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)
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)
(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)
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)
(REASON_SYSCALL): Ditto.
(access_reg): Use __uc_get_reason() to determine how ucontext_t was created.
Handle UNW_IA64_AR_BSP differently depending on whether or not
ucontext_t was created by a syscall. Ditto for UNW_IA64_IP and
UNW_IA64_CFM. Add debug statement.
(Logical change 1.77)
is not defined.
(tdep_find_proc_info) [HAVE_DLMODINFO): Declare new type "struct unwind_header"
to accommodate HP-UX unwind header. Fetch unwind table from this
header.
(Logical change 1.75)
Include <inttypes.h> instead of <stdint.h>. HP-UX doesn't have the latter.
Use "inline" instead of "__inline__" (the former gets properly #define'd by
config.h).
(Logical change 1.63)
(_Uia64_search_unwind_table): Be sure to clear "proc_info" members as documented
by unw_get_proc_info(3).
Include <dlfcn.h> if we have dlmodinfo() (HP-UX only).
(tdep_find_proc_info): Use dl_iterate_phdr() only if we have it (glibc-based
systems). Use dlmodinfo() if we have it (HP-UX).
(Logical change 1.63)
(ia64_get_cached_proc_info): Rename from ia64_script_lookup() and modify it so
it directly updates the proc-info if the necessary script is in the cache.
(script_new): Remove locking comments and adjust formatting.
(ia64_find_save_locs): If global caching is enabled, mask signal delivery and
hold the cache lock while accessing the cache.
(ia64_script_cache_init): Initialize the cache lock.
(Logical change 1.59)
(parse_dynamic): Fix it so it actually works.
(create_state_record_for): Initialize return_link_reg to zero.
Don't print "no unwind info" unconditionally when UNW_DEBUG is
in effect.
(Logical change 1.56)
(.info): Use @gprel() reloc instead of @segrel() reloc for _U_dyn_info_list.
The latter doesn't work because the unwind-info is in a different segment.
(ia64_init): Clear unw.r0.
(Logical change 1.55)
(desc_prologue): Fix handling of region_start so it doesn't get corrupted by
state-record pushing/popping.
(parse_dynamic): Allow the last region to contain a negative insn_count, indicating
that the region covers the last portion of a procedure.
(Logical change 1.54)
we now switch to the new backing-store immediately.
(rbs_underflow): Remove.
(rbs_find_stacked): No longer assume that c->bsp is contained in the current
rbs. If it is not, first find the backing-store that's backing c->bsp.
(rbs_cover_and_flush): Use rbs_contains() instead of (broken) open code.
Handle the case where the initial bsp points to an RNaT slot.
(Logical change 1.52)
IP is outside the range of the old procedure.
When writing one of the exception argument registers, track the update
in c->eh_valid_mask.
(Logical change 1.45)
original stack-pointer from c->sigcontext_loc.
Handle rbs-switches for Linux signal deliver on alternate signal stack and
for general case, indicated by UNW_PI_FLAG_IA64_RBS_SWITCH.
Call rbs_underflow() when we detect a register-backing-store underflow.
(Logical change 1.40)
(create_state_record_for): Turn on UNW_PI_FLAG_IA64_RBS_SWITCH when a procedure
has saved all of ar.bsp, ar.bspstore, and ar.rnat.
(Logical change 1.40)