aboutsummaryrefslogtreecommitdiff
path: root/gcc/go
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@google.com>2016-01-27 18:37:14 +0000
committerIan Lance Taylor <ian@gcc.gnu.org>2016-01-27 18:37:14 +0000
commitede673766742e2e48e43e3fa1c08c86d2ca8c893 (patch)
tree55a02d0b4831c0812687d7b14549fdd49d4763ef /gcc/go
parent1a218fc914c5693297312ea6869c94f0cf15b35a (diff)
downloadgcc-ede673766742e2e48e43e3fa1c08c86d2ca8c893.zip
gcc-ede673766742e2e48e43e3fa1c08c86d2ca8c893.tar.gz
gcc-ede673766742e2e48e43e3fa1c08c86d2ca8c893.tar.bz2
go-lang.c (go_langhook_init_options_struct): Default to -fkeep-gc-roots-live.
* go-lang.c (go_langhook_init_options_struct): Default to -fkeep-gc-roots-live. From-SVN: r232890
Diffstat (limited to 'gcc/go')
-rw-r--r--gcc/go/ChangeLog5
-rw-r--r--gcc/go/go-lang.c3
2 files changed, 8 insertions, 0 deletions
diff --git a/gcc/go/ChangeLog b/gcc/go/ChangeLog
index d985328..c0a6dda 100644
--- a/gcc/go/ChangeLog
+++ b/gcc/go/ChangeLog
@@ -1,3 +1,8 @@
+2016-01-27 Ian Lance Taylor <iant@google.com>
+
+ * go-lang.c (go_langhook_init_options_struct): Default to
+ -fkeep-gc-roots-live.
+
2016-01-04 Jakub Jelinek <jakub@redhat.com>
Update copyright years.
diff --git a/gcc/go/go-lang.c b/gcc/go/go-lang.c
index 1606524..9f21424 100644
--- a/gcc/go/go-lang.c
+++ b/gcc/go/go-lang.c
@@ -150,6 +150,9 @@ go_langhook_init_options_struct (struct gcc_options *opts)
opts->x_flag_exceptions = 1;
opts->x_flag_non_call_exceptions = 1;
+ /* We need to keep pointers live for the garbage collector. */
+ opts->x_flag_keep_gc_roots_live = 1;
+
/* Go programs expect runtime.Callers to work, and that uses
libbacktrace that uses debug info. Set the debug info level to 1
by default. In post_options we will set the debug type if the