From: Jan Hubicka Date: Wed, 1 Feb 2006 20:31:29 +0000 (+0100) Subject: opts.c (no_unit_at_a_time_default): New global variable. X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=46fd0f8c241a0afd36adf9c63b56839ace3a0210;p=platform%2Fupstream%2Fgcc.git opts.c (no_unit_at_a_time_default): New global variable. 2006-02-01 Jan Hubicka * opts.c (no_unit_at_a_time_default): New global variable. (decode_options): Use it. * opts.h (no_unit_at_a_time_default): Declare. java/ * decl.c (end_java_method): Kill hack disabling unit-at-a-time. * lang.c (java_init_options): Set no_unit_at_a_time_default. From-SVN: r110479 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d9ebf25..1898c2a 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2006-02-01 Jan Hubicka + + * opts.c (no_unit_at_a_time_default): New global variable. + (decode_options): Use it. + * opts.h (no_unit_at_a_time_default): Declare. + 2006-02-01 Paul Brook * function.c (assign_parm_setup_reg): Use function argument promotion diff --git a/gcc/java/ChangeLog b/gcc/java/ChangeLog index f986030..39fb643 100644 --- a/gcc/java/ChangeLog +++ b/gcc/java/ChangeLog @@ -1,3 +1,8 @@ +2006-02-01 Jan Hubicka + + * decl.c (end_java_method): Kill hack disabling unit-at-a-time. + * lang.c (java_init_options): Set no_unit_at_a_time_default. + 2006-01-30 Andrew Haley PR java/21428 diff --git a/gcc/java/decl.c b/gcc/java/decl.c index 7ef1325..65fa4c6 100644 --- a/gcc/java/decl.c +++ b/gcc/java/decl.c @@ -2072,7 +2072,6 @@ end_java_method (void) attach_init_test_initialization_flags, block_body); } - flag_unit_at_a_time = 0; finish_method (fndecl); if (! flag_unit_at_a_time) diff --git a/gcc/java/lang.c b/gcc/java/lang.c index f435fde..3dc13c5 100644 --- a/gcc/java/lang.c +++ b/gcc/java/lang.c @@ -574,6 +574,10 @@ java_init_options (unsigned int argc ATTRIBUTE_UNUSED, /* Java requires left-to-right evaluation of subexpressions. */ flag_evaluation_order = 1; + /* Unit at a time is disabled for Java because it is considered + too expensive. */ + no_unit_at_a_time_default = 1; + jcf_path_init (); return CL_Java; diff --git a/gcc/opts.c b/gcc/opts.c index 1218e99..91a5fc2 100644 --- a/gcc/opts.c +++ b/gcc/opts.c @@ -80,6 +80,11 @@ bool use_gnu_debug_info_extensions; /* The default visibility for all symbols (unless overridden) */ enum symbol_visibility default_visibility = VISIBILITY_DEFAULT; +/* Disable unit-at-a-time for frontends that might be still broken in this + respect. */ + +bool no_unit_at_a_time_default; + /* Global visibility options. */ struct visibility_flags visibility_options; @@ -538,7 +543,8 @@ decode_options (unsigned int argc, const char **argv) flag_tree_copy_prop = 1; flag_tree_sink = 1; flag_tree_salias = 1; - flag_unit_at_a_time = 1; + if (!no_unit_at_a_time_default) + flag_unit_at_a_time = 1; if (!optimize_size) { diff --git a/gcc/opts.h b/gcc/opts.h index 2c2340c..bfa9ccc 100644 --- a/gcc/opts.h +++ b/gcc/opts.h @@ -63,6 +63,7 @@ struct cl_option_state { extern const struct cl_option cl_options[]; extern const unsigned int cl_options_count; extern const char *const lang_names[]; +extern bool no_unit_at_a_time_default; #define CL_DISABLED (1 << 21) /* Disabled in this configuration. */ #define CL_TARGET (1 << 22) /* Target-specific option. */