2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106813
4 diff --git a/libgo/runtime/go-signal.c b/libgo/runtime/go-signal.c
5 index b429fdb..613021a 100644
6 --- a/libgo/runtime/go-signal.c
7 +++ b/libgo/runtime/go-signal.c
8 @@ -229,6 +229,10 @@ getSiginfo(siginfo_t *info, void *context __attribute__((unused)))
9 ret.sigpc = ((ucontext_t*)(context))->uc_mcontext.jmp_context.iar;
10 #elif defined(__aarch64__) && defined(__linux__)
11 ret.sigpc = ((ucontext_t*)(context))->uc_mcontext.pc;
12 +#elif defined(__x86_64__) && defined(__sun__)
13 + ret.sigpc = ((ucontext_t*)(context))->uc_mcontext.gregs[REG_RIP];
14 +#elif defined(__i386__) && defined(__sun__)
15 + ret.sigpc = ((ucontext_t*)(context))->uc_mcontext.gregs[REG_RIP];