aboutsummaryrefslogtreecommitdiff
path: root/gcc/go/go-lang.c
diff options
context:
space:
mode:
authorCherry Zhang <cherryyz@google.com>2018-02-02 00:00:04 +0000
committerIan Lance Taylor <ian@gcc.gnu.org>2018-02-02 00:00:04 +0000
commit2794baab686973f39045327970e4a7302c31ea88 (patch)
tree86c02d77baa7232c84a3d624601cc0f9e7405174 /gcc/go/go-lang.c
parent90bf94878bea2883158d02370cb2692d4b2ed4a1 (diff)
downloadgcc-2794baab686973f39045327970e4a7302c31ea88.zip
gcc-2794baab686973f39045327970e4a7302c31ea88.tar.gz
gcc-2794baab686973f39045327970e4a7302c31ea88.tar.bz2
compiler: turn on escape analysis by default
The escape analysis now runs by default. It can be disabled with the negative flag, -fno-go-optimize-allocs. Reviewed-on: https://go-review.googlesource.com/86247 * lang.opt (fgo-optimize): Remove RejectNegative. * go-c.h (go_enable_optimize): Update declaration to take value argument. * go-lang.c (go_langhook_handle_option): Pass value to go_enable_optimize. * gccgo.texi (Invoking gccgo): Update -fgo-optimize-allocs doc. From-SVN: r257319
Diffstat (limited to 'gcc/go/go-lang.c')
-rw-r--r--gcc/go/go-lang.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/go/go-lang.c b/gcc/go/go-lang.c
index b5d8224..45dee88 100644
--- a/gcc/go/go-lang.c
+++ b/gcc/go/go-lang.c
@@ -194,7 +194,7 @@ static bool
go_langhook_handle_option (
size_t scode,
const char *arg,
- int value ATTRIBUTE_UNUSED,
+ int value,
int kind ATTRIBUTE_UNUSED,
location_t loc ATTRIBUTE_UNUSED,
const struct cl_option_handlers *handlers ATTRIBUTE_UNUSED)
@@ -251,7 +251,7 @@ go_langhook_handle_option (
break;
case OPT_fgo_optimize_:
- ret = go_enable_optimize (arg) ? true : false;
+ ret = go_enable_optimize (arg, value) ? true : false;
break;
case OPT_fgo_pkgpath_: