runtime: handle PPC/PPC64 GNU/Linux in getSiginfo
authorIan Lance Taylor <ian@gcc.gnu.org>
Fri, 21 Jul 2017 18:08:01 +0000 (18:08 +0000)
committerIan Lance Taylor <ian@gcc.gnu.org>
Fri, 21 Jul 2017 18:08:01 +0000 (18:08 +0000)
    Updates golang/go#20931

    Reviewed-on: https://go-review.googlesource.com/50631

From-SVN: r250436

gcc/go/gofrontend/MERGE
libgo/runtime/go-signal.c

index 364312f2202dc13f478b58872435d05bc7bfc17c..accb55f768ec3534489afc7c37bb2a551f585f87 100644 (file)
@@ -1,4 +1,4 @@
-e34cb8dee6c1f215329e0eea79202b48cb83817c
+a9f1aeced86691de891fbf2a8c97e848faf1962e
 
 The first line of this file holds the git revision number of the last
 merge done from the gofrontend repository.
index ad29662d0fda46ceb2be2ca05130efb888bf9eb7..d274865074f7094d5006ba995300166e78c8b41a 100644 (file)
@@ -215,6 +215,11 @@ getSiginfo(siginfo_t *info, void *context __attribute__((unused)))
        ret.sigpc = ((ucontext_t*)(context))->uc_mcontext.gregs[REG_EIP];
   #endif
 #endif
+#ifdef __PPC__
+  #ifdef __linux__
+       ret.sigpc = ((ucontext_t*)(context))->uc_mcontext.regs->nip;
+  #endif
+#endif
 
        if (ret.sigpc == 0) {
                // Skip getSiginfo/sighandler/sigtrampgo/sigtramp/handler.