[PATCH] PR 54789: Fix driver error when GCC_COMPARE_DEBUG is defined
This patch simplifies process_command a bit by using save_switch and sets the "known" switch field to "true". gcc/ChangeLog: 2012-10-05 Dmitry Gorbachev PR driver/54789 * gcc.c (process_command): Use save_switch for synthesized -fcompare-debug=* option; mark the switch as known. --- gcc/gcc.c +++ gcc/gcc.c @@ -3961,18 +3961,12 @@ process_command (unsigned int decoded_options_count, if (n_infiles == last_language_n_infiles && spec_lang != 0) warning (0, "%<-x %s%> after last input file has no effect", spec_lang); + /* Synthesize -fcompare-debug flag from the GCC_COMPARE_DEBUG + environment variable. */ if (compare_debug == 2 || compare_debug == 3) { - alloc_switch (); - switches[n_switches].part1 = concat ("fcompare-debug=", - compare_debug_opt, - NULL); - switches[n_switches].args = 0; - switches[n_switches].live_cond = 0; - switches[n_switches].validated = false; - switches[n_switches].known = false; - switches[n_switches].ordering = 0; - n_switches++; + const char *opt = concat ("-fcompare-debug=", compare_debug_opt, NULL); + save_switch (opt, 0, NULL, false, true); compare_debug = 1; }
[Patch, trivial] PR 56653: Fix warning when verifying checksums from MD5SUMS file in tarballs
This patch is to fix `md5sum: WARNING: 1 line is improperly formatted' thing. 2013-12-28 Dmitry Gorbachev PR 56653 * gcc_release: Add an extra `#' character to the comment header of MD5SUMS. *** maintainer-scripts/gcc_release --- maintainer-scripts/gcc_release *** *** 214,218 # Suggested usage: # md5sum -c MD5SUMS | grep -v \"OK$\" ! " > MD5SUMS find . -type f | --- 214,218 # Suggested usage: # md5sum -c MD5SUMS | grep -v \"OK$\" ! #" > MD5SUMS find . -type f |
[Ping][Patch, trivial] PR 56653: Fix warning when verifying checksums from MD5SUMS file in tarballs
-- Forwarded message -- From: Dmitry Gorbachev Date: Sat, 28 Dec 2013 02:33:18 +0400 Subject: [Patch, trivial] PR 56653: Fix warning when verifying checksums from MD5SUMS file in tarballs To: gcc-patches@gcc.gnu.org This patch is to fix `md5sum: WARNING: 1 line is improperly formatted' thing. 2013-12-28 Dmitry Gorbachev PR 56653 * gcc_release: Add an extra `#' character to the comment header of MD5SUMS. *** maintainer-scripts/gcc_release --- maintainer-scripts/gcc_release *** *** 214,218 # Suggested usage: # md5sum -c MD5SUMS | grep -v \"OK$\" ! " > MD5SUMS find . -type f | --- 214,218 # Suggested usage: # md5sum -c MD5SUMS | grep -v \"OK$\" ! #" > MD5SUMS find . -type f |
Re: Prevent inliner from removing aliases of used comdats
Would a testcase from PR50226 suffice?
Trivial patch to fix build with --enable-build-with-cxx
../../gcc-4.7/gcc/tree-inline.c: In function 'tree_node* maybe_inline_call_in_expr(tree)': ../../gcc-4.7/gcc/tree-inline.c:5229:40: error: converting 'false' to pointer type 'void (*)(tree)' [-Werror=conversion-null] 2011-05-02 Dmitry Gorbachev * tree-inline.c (maybe_inline_call_in_expr): Replace false by NULL. --- gcc/tree-inline.c +++ gcc/tree-inline.c @@ -5226,7 +5226,7 @@ id.transform_call_graph_edges = CB_CGE_DUPLICATE; id.transform_new_cfg = false; id.transform_return_to_modify = true; - id.transform_lang_insert_block = false; + id.transform_lang_insert_block = NULL; /* Make sure not to unshare trees behind the front-end's back since front-end specific mechanisms may rely on sharing. */
Re: Trivial patch to fix build with --enable-build-with-cxx
Uh, there is another one: ../../gcc-4.7/gcc/cp/parser.c: In function 'tree_node* cp_parser_init_declarator(cp_parser*, cp_decl_specifier_seq*, VEC_deferred_access_check_gc*, bool, bool, int, bool*, tree_node**)': ../../gcc-4.7/gcc/cp/parser.c:14612:19: error: converting 'false' to pointer type 'tree' [-Werror=conversion-null] 2011-05-02 Dmitry Gorbachev * parser.c (cp_parser_init_declarator): Replace false by NULL. --- gcc/cp/parser.c +++ gcc/cp/parser.c @@ -14609,7 +14609,7 @@ if (pushed_scope) { pop_scope (pushed_scope); - pushed_scope = false; + pushed_scope = NULL; } decl = grokfield (declarator, decl_specifiers, initializer, !is_non_constant_init,
[PATCH] Fix error: 'previous' may be used uninitialized in this function
2011-05-15 Dmitry Gorbachev * gengtype-state.c (read_state_param_structs): Initialize "previous". --- gcc/gengtype-state.c +++ gcc/gengtype-state.c @@ -2137,7 +2137,7 @@ read_state_param_structs (type_p *param_structs) int nbparamstructs = 0; int countparamstructs = 0; type_p head = NULL; - type_p previous; + type_p previous = NULL; type_p tmp; struct state_token_st *t0 = peek_state_token (0); struct state_token_st *t1 = peek_state_token (1);