This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: gotools patch committed: Test runtime, misc/cgo/{test,testcarchive}


On Fri, Aug 4, 2017 at 3:54 AM, Uros Bizjak <ubizjak@gmail.com> wrote:
>
> The problem was following:
>
> runtime.Breakpoint comprises only call to __builtin_trap (), which in
> case of alpha maps to "call_pall 0x81". Since __builtin_trap () is a
> noreturn function, no other instructions are emitted after call_pal.
>
> However, when call_pal insn is executed, alpha updates program counter
> before the signal is raised. As call_pal was the last insn, updated PC
> points outside of the function boundaries, and backtrace (and gdb,
> FWIW) failed to found enclosing function.
>
> The solution is to emit nop after call_pal insn, so PC will always
> remain between function boundaries.
>
> Attached patch implements dumpregs function for alpha.

Thanks for analyzing the problem.

I committed the dump-registers patch to mainline.

Ian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]