RFA: add debug hook to unwinder
Richard Henderson
rth@redhat.com
Fri Jun 12 05:43:00 GMT 2009
Tom Tromey wrote:
> +/* This function is called during unwinding. It is intended as a hook
> + for a debugger to intercept exceptions. CFA is the CFA of the
> + target frame. HANDLER is the PC to which control will be
> + transferred. */
> +static void
> +_Unwind_DebugHook (void *cfa __attribute__ ((__unused__)),
> + void *handler __attribute__ ((__unused__)))
> +{
> + asm ("");
> +}
I think you should mark this function noinline for safety.
Otherwise some future version of the compiler could decide
to inline this and eliminate the _Unwind_DebugHook symbol
entirely.
r~
More information about the Gcc-patches
mailing list