libgo patch committed: Declare runtime_usestackmaps in .c file, not .h file

Message ID CAOyqgcX_jHh5JOznJa+oJWGdYhXhYO6ZoGQAnXvyFAKYUiNsiA@mail.gmail.com
State New
Headers show
Series
  • libgo patch committed: Declare runtime_usestackmaps in .c file, not .h file
Related show

Commit Message

Ian Lance Taylor Nov. 21, 2019, 1:06 a.m.
This libgo patch declares runtime_usestackmaps in stack.c, not
runtime.h.  This fixes https://gcc.gnu.org/PR92605.  Bootstrapped and
ran Go testsuite on x86_64-pc-linux-gnu.  Committed to mainline.

Ian

Patch

Index: gcc/go/gofrontend/MERGE
===================================================================
--- gcc/go/gofrontend/MERGE	(revision 278539)
+++ gcc/go/gofrontend/MERGE	(working copy)
@@ -1,4 +1,4 @@ 
-9cc7092b84c38d77d98ed856f1f613a6ca27122d
+017830d2a4bd2efbddf5e841ba9ccff8acf9d7c8
 
 The first line of this file holds the git revision number of the last
 merge done from the gofrontend repository.
Index: libgo/runtime/runtime.h
===================================================================
--- libgo/runtime/runtime.h	(revision 277299)
+++ libgo/runtime/runtime.h	(working copy)
@@ -475,7 +475,7 @@  bool scanstackwithmap(void*)
 bool doscanstack(G*, void*)
   __asm__("runtime.doscanstack");
 
-bool runtime_usestackmaps;
+extern bool runtime_usestackmaps;
 
 bool probestackmaps(void)
   __asm__("runtime.probestackmaps");
Index: libgo/runtime/stack.c
===================================================================
--- libgo/runtime/stack.c	(revision 277299)
+++ libgo/runtime/stack.c	(working copy)
@@ -16,6 +16,8 @@  extern void * __splitstack_find_context
 
 #endif
 
+bool runtime_usestackmaps;
+
 // Calling unwind_init in doscanstack only works if it does not do a
 // tail call to doscanstack1.
 #pragma GCC optimize ("-fno-optimize-sibling-calls")