* go-lang.c (go_langhook_post_options): Disable sibling calls by
authorian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 12 Dec 2013 02:24:20 +0000 (02:24 +0000)
committerian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 12 Dec 2013 02:24:20 +0000 (02:24 +0000)
default.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@205915 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/go/ChangeLog
gcc/go/go-lang.c

index 0c03656..db0212c 100644 (file)
@@ -1,3 +1,8 @@
+2013-12-11  Ian Lance Taylor  <iant@google.com>
+
+       * go-lang.c (go_langhook_post_options): Disable sibling calls by
+       default.
+
 2013-12-10  Ian Lance Taylor  <iant@google.com>
 
        * Make-lang.in (check_go_parallelize): Test go-test.exp r* tests
index d207a31..ae133f7 100644 (file)
@@ -270,6 +270,10 @@ go_langhook_post_options (const char **pfilename ATTRIBUTE_UNUSED)
   if (flag_excess_precision_cmdline == EXCESS_PRECISION_DEFAULT)
     flag_excess_precision_cmdline = EXCESS_PRECISION_STANDARD;
 
+  /* Tail call optimizations can confuse uses of runtime.Callers.  */
+  if (!global_options_set.x_flag_optimize_sibling_calls)
+    global_options.x_flag_optimize_sibling_calls = 0;
+
   /* Returning false means that the backend should be used.  */
   return false;
 }