Hi! OK to apply the following cleanup patches to trunk, assuming that testing (still running) is fine?
commit 68c9deec084dff1e5d8caf6a17ec3eec1f8f9f33 Author: Thomas Schwinge <tho...@codesourcery.com> Date: Wed Oct 23 19:40:10 2013 +0200 Fix description of OpenMP parallel directive in the C and C++ front ends. gcc/c/ * c-parser.c (c_parser_omp_parallel): Fix description. gcc/cp/ parser.c (cp_parser_omp_parallel): Fix description. diff --git gcc/c/c-parser.c gcc/c/c-parser.c index c78d269..28f53c1 100644 --- gcc/c/c-parser.c +++ gcc/c/c-parser.c @@ -12032,9 +12032,16 @@ c_parser_omp_sections (location_t loc, c_parser *parser, } /* OpenMP 2.5: - # pragma parallel parallel-clause new-line - # pragma parallel for parallel-for-clause new-line - # pragma parallel sections parallel-sections-clause new-line + # pragma omp parallel parallel-clause[optseq] new-line + structured-block + # pragma omp parallel for parallel-for-clause[optseq] new-line + structured-block + # pragma omp parallel sections parallel-sections-clause[optseq] new-line + structured-block + + OpenMP 4.0: + # pragma omp parallel for simd parallel-for-simd-clause[optseq] new-line + structured-block LOC is the location of the #pragma token. */ diff --git gcc/cp/parser.c gcc/cp/parser.c index dd02734..9f8ad39 100644 --- gcc/cp/parser.c +++ gcc/cp/parser.c @@ -29512,12 +29512,16 @@ cp_parser_omp_sections (cp_parser *parser, cp_token *pragma_tok, } /* OpenMP 2.5: - # pragma parallel parallel-clause new-line - # pragma parallel for parallel-for-clause new-line - # pragma parallel sections parallel-sections-clause new-line + # pragma omp parallel parallel-clause[optseq] new-line + structured-block + # pragma omp parallel for parallel-for-clause[optseq] new-line + structured-block + # pragma omp parallel sections parallel-sections-clause[optseq] new-line + structured-block OpenMP 4.0: - # pragma parallel for simd parallel-for-simd-clause new-line */ + # pragma omp parallel for simd parallel-for-simd-clause[optseq] new-line + structured-block */ #define OMP_PARALLEL_CLAUSE_MASK \ ( (OMP_CLAUSE_MASK_1 << PRAGMA_OMP_CLAUSE_IF) \ commit 46ac50be669906346aee96c88509962ca2d0efb3 Author: Thomas Schwinge <tho...@codesourcery.com> Date: Wed Oct 23 20:01:38 2013 +0200 Properly order chapters in GCC Internals manual. gcc/ * doc/gccint.texi (Top): Fix inclusion order. diff --git gcc/doc/gccint.texi gcc/doc/gccint.texi index 7d79500..a80cc5d 100644 --- gcc/doc/gccint.texi +++ gcc/doc/gccint.texi @@ -143,12 +143,12 @@ Additional tutorial information is linked to from @include sourcebuild.texi @include options.texi @include passes.texi -@include rtl.texi @include generic.texi @include gimple.texi @include tree-ssa.texi -@include loop.texi +@include rtl.texi @include cfg.texi +@include loop.texi @include md.texi @include tm.texi @include hostconfig.texi commit 2fdb23db57bfa7a27b2d14b0e98d6d6f764e5261 Author: Thomas Schwinge <tho...@codesourcery.com> Date: Thu Oct 31 14:55:47 2013 +0100 Document passes.def. gcc/ * doc/cfg.texi (Control Flow): Refer to passes.def instead of passes.c. * doc/passes.texi (Pass manager): Refer to passes.def. diff --git gcc/doc/cfg.texi gcc/doc/cfg.texi index b759e36..1be3f47 100644 --- gcc/doc/cfg.texi +++ gcc/doc/cfg.texi @@ -23,7 +23,7 @@ used to represent the control flow graph are defined in In GCC, the representation of control flow is maintained throughout the compilation process, from constructing the CFG early in -@code{pass_build_cfg} to @code{pass_free_cfg} (see @file{passes.c}). +@code{pass_build_cfg} to @code{pass_free_cfg} (see @file{passes.def}). The CFG takes various different modes and may undergo extensive manipulations, but the graph is always valid between its construction and its release. This way, transfer of information such as data flow, diff --git gcc/doc/passes.texi gcc/doc/passes.texi index 3ed9a4f..9a68ad2 100644 --- gcc/doc/passes.texi +++ gcc/doc/passes.texi @@ -208,6 +208,7 @@ semantic checks), it should return @code{GS_ERROR}. The pass manager is located in @file{passes.c}, @file{tree-optimize.c} and @file{tree-pass.h}. +It processes passes as described in @file{passes.def}. Its job is to run all of the individual passes in the correct order, and take care of standard bookkeeping that applies to every pass. commit b345a58a0c66a2e1bc29bb842740773caa6088e0 Author: Thomas Schwinge <tho...@codesourcery.com> Date: Wed Oct 30 12:16:53 2013 +0100 gcc/gimplify.c:gimplify_omp_ctx is a variable remapping context. gcc/ * gimplify.c (gimplify_omp_ctx): Describe as a variable remapping context. diff --git gcc/gimplify.c gcc/gimplify.c index 7203456..f54e6e1 100644 --- gcc/gimplify.c +++ gcc/gimplify.c @@ -129,6 +129,8 @@ struct gimplify_ctx bool in_cleanup_point_expr; }; +/* Variable remapping context. */ + struct gimplify_omp_ctx { struct gimplify_omp_ctx *outer_context; @@ -340,7 +342,7 @@ splay_tree_compare_decl_uid (splay_tree_key xa, splay_tree_key xb) return DECL_UID (a) - DECL_UID (b); } -/* Create a new omp construct that deals with variable remapping. */ +/* Create a new variable remapping context for REGION_TYPE. */ static struct gimplify_omp_ctx * new_omp_context (enum omp_region_type region_type) @@ -361,7 +363,7 @@ new_omp_context (enum omp_region_type region_type) return c; } -/* Destroy an omp construct that deals with variable remapping. */ +/* Destroy variable remapping context C. */ static void delete_omp_context (struct gimplify_omp_ctx *c) @@ -645,7 +647,8 @@ gimple_add_tmp_var (tree tmp) DECL_CHAIN (tmp) = gimplify_ctxp->temps; gimplify_ctxp->temps = tmp; - /* Mark temporaries local within the nearest enclosing parallel. */ + /* If applicable, mark temporaries as local within the nearest enclosing + variable remapping context. */ if (gimplify_omp_ctxp) { struct gimplify_omp_ctx *ctx = gimplify_omp_ctxp; @@ -1715,7 +1718,7 @@ gimplify_var_or_parm_decl (tree *expr_p) return GS_ERROR; } - /* When within an OpenMP context, notice uses of variables. */ + /* Within a variable remapping context, notice uses of variables. */ if (gimplify_omp_ctxp && omp_notice_variable (gimplify_omp_ctxp, decl, true)) return GS_ALL_DONE; @@ -5338,9 +5341,9 @@ gimplify_stmt (tree *stmt_p, gimple_seq *seq_p) return last != gimple_seq_last (*seq_p); } -/* Add FIRSTPRIVATE entries for DECL in the OpenMP the surrounding parallels - to CTX. If entries already exist, force them to be some flavor of private. - If there is no enclosing parallel, do nothing. */ +/* If applicable, add private entries for DECL to CTX and any outer variable + remapping contexts, or, if entries already exist, force them to be some + flavor of private. */ void omp_firstprivatize_variable (struct gimplify_omp_ctx *ctx, tree decl) @@ -5430,7 +5433,7 @@ omp_firstprivatize_type_sizes (struct gimplify_omp_ctx *ctx, tree type) lang_hooks.types.omp_firstprivatize_type_sizes (ctx, type); } -/* Add an entry for DECL in the OpenMP context CTX with FLAGS. */ +/* Add an entry for DECL in CTX with FLAGS. */ static void omp_add_variable (struct gimplify_omp_ctx *ctx, tree decl, unsigned int flags) @@ -5472,7 +5475,7 @@ omp_add_variable (struct gimplify_omp_ctx *ctx, tree decl, unsigned int flags) /* Add the pointer replacement variable as PRIVATE if the variable replacement is private, else FIRSTPRIVATE since we'll need the address of the original variable either for SHARED, or for the - copy into or out of the context. */ + copy into or out of the variable remapping context. */ if (!(flags & GOVD_LOCAL)) { nflags = flags & GOVD_MAP @@ -5531,7 +5534,7 @@ omp_add_variable (struct gimplify_omp_ctx *ctx, tree decl, unsigned int flags) splay_tree_insert (ctx->variables, (splay_tree_key)decl, flags); } -/* Notice a threadprivate variable DECL used in OpenMP context CTX. +/* Notice a threadprivate variable DECL used in CTX. This just prints out diagnostics about threadprivate variable uses in untied tasks. If DECL2 is non-NULL, prevent this warning on that variable. */ @@ -5573,7 +5576,7 @@ omp_notice_threadprivate_variable (struct gimplify_omp_ctx *ctx, tree decl, return false; } -/* Record the fact that DECL was used within the OpenMP context CTX. +/* Record the fact that DECL was used within CTX. IN_CODE is true when real code uses DECL, and false when we should merely emit default(none) errors. Return true if DECL is going to be remapped and thus DECL shouldn't be gimplified into its @@ -5744,8 +5747,9 @@ omp_notice_variable (struct gimplify_omp_ctx *ctx, tree decl, bool in_code) n->value = flags; do_outer: - /* If the variable is private in the current context, then we don't - need to propagate anything to an outer context. */ + /* If the variable is private in the current variable remapping context, then + we don't need to propagate anything to an outer variable remapping + context. */ if ((flags & GOVD_PRIVATE) && !(flags & GOVD_PRIVATE_OUTER_REF)) return ret; if (ctx->outer_context @@ -5848,7 +5852,7 @@ omp_check_private (struct gimplify_omp_ctx *ctx, tree decl, bool copyprivate) } /* Scan the OpenMP clauses in *LIST_P, installing mappings into a new - and previous omp contexts. */ + and previous variable remapping contexts. */ static void gimplify_scan_omp_clauses (tree *list_p, gimple_seq *pre_p, @@ -6135,8 +6139,8 @@ gimplify_scan_omp_clauses (tree *list_p, gimple_seq *pre_p, gimplify_omp_ctxp = ctx; } -/* For all variables that were not actually used within the context, - remove PRIVATE, SHARED, and FIRSTPRIVATE clauses. */ +/* For all variables that were not actually used within the variable remapping + context remove PRIVATE, SHARED, and FIRSTPRIVATE clauses. */ static int gimplify_adjust_omp_clauses_1 (splay_tree_node n, void *data) @@ -7859,7 +7863,7 @@ gimplify_expr (tree *expr_p, gimple_seq *pre_p, gimple_seq *post_p, break; case RESULT_DECL: - /* When within an OpenMP context, notice uses of variables. */ + /* Within a variable remapping context, notice uses of variables. */ if (gimplify_omp_ctxp) omp_notice_variable (gimplify_omp_ctxp, *expr_p, true); ret = GS_ALL_DONE; commit d9d250d3da7025bb1f01d59db84da6214619be78 Author: Thomas Schwinge <tho...@codesourcery.com> Date: Fri Oct 18 15:01:27 2013 +0200 Reflect reality in comment. gcc/ * omp-low.c (check_combined_parallel): Reflect reality in comment; from the initial r126226. diff --git gcc/omp-low.c gcc/omp-low.c index 1222df6..a3bcf58 100644 --- gcc/omp-low.c +++ gcc/omp-low.c @@ -9046,7 +9046,7 @@ lower_omp_for (gimple_stmt_iterator *gsi_p, omp_context *ctx) } /* Callback for walk_stmts. Check if the current statement only contains - GIMPLE_OMP_FOR or GIMPLE_OMP_PARALLEL. */ + GIMPLE_OMP_FOR or GIMPLE_OMP_SECTIONS. */ static tree check_combined_parallel (gimple_stmt_iterator *gsi_p, commit 149ddeaf06affcdd7ed048e0c71b4e02badbf5e9 Author: Thomas Schwinge <tho...@codesourcery.com> Date: Thu Oct 17 21:10:22 2013 +0200 Fix typo in dg-warning comment. gcc/testsuite/ * gcc.dg/dfp/wtr-conversion-1.c (testfunc1): Fix typo, from the initial r109604. diff --git gcc/testsuite/gcc.dg/dfp/wtr-conversion-1.c gcc/testsuite/gcc.dg/dfp/wtr-conversion-1.c index 2b50fe6..4eff007 100644 --- gcc/testsuite/gcc.dg/dfp/wtr-conversion-1.c +++ gcc/testsuite/gcc.dg/dfp/wtr-conversion-1.c @@ -24,7 +24,7 @@ testfunc1 () { foo_i (i); foo_i (d32); /* { dg-warning "as integer rather than floating" "prototype conversion warning" } */ - foo_i (d64); /* { dg-warning "as integer rather than floating" "prototype convDersion warning" } */ + foo_i (d64); /* { dg-warning "as integer rather than floating" "prototype conversion warning" } */ foo_i (d128); /* { dg-warning "as integer rather than floating" "prototype conversion warning" } */ foo_d32 (i); /* { dg-warning "as floating rather than integer" "prototype conversion warning" } */ foo_d32 (f); /* { dg-warning "as '_Decimal32' rather than 'float'" "prototype conversion warning" } */ commit 9d973b191c3d0d8e6942ee5b46d0f90063ceeafa Author: Thomas Schwinge <tho...@codesourcery.com> Date: Fri Dec 13 08:48:44 2013 +0100 Remove leftover comment. gcc/ * omp-low.c: Remove leftover comment from function removed in r112935. diff --git gcc/omp-low.c gcc/omp-low.c index a3bcf58..819c442 100644 --- gcc/omp-low.c +++ gcc/omp-low.c @@ -1220,8 +1220,6 @@ omp_copy_decl (tree var, copy_body_data *cb) } -/* Return the parallel region associated with STMT. */ - /* Debugging dumps for parallel regions. */ void dump_omp_region (FILE *, struct omp_region *, int); void debug_omp_region (struct omp_region *); commit 30763705628d28c87200519589a526a1ee2a7020 Author: Thomas Schwinge <tho...@codesourcery.com> Date: Thu Oct 31 15:17:50 2013 +0100 Remove leftover function declaration. gcc/ * tree-pass.h (make_pass_expand_omp_ssa): Remove leftover declaration of function removed in r135786. diff --git gcc/tree-pass.h gcc/tree-pass.h index b7b43de..44b3308 100644 --- gcc/tree-pass.h +++ gcc/tree-pass.h @@ -400,7 +400,6 @@ extern gimple_opt_pass *make_pass_lower_vector_ssa (gcc::context *ctxt); extern gimple_opt_pass *make_pass_lower_omp (gcc::context *ctxt); extern gimple_opt_pass *make_pass_diagnose_omp_blocks (gcc::context *ctxt); extern gimple_opt_pass *make_pass_expand_omp (gcc::context *ctxt); -extern gimple_opt_pass *make_pass_expand_omp_ssa (gcc::context *ctxt); extern gimple_opt_pass *make_pass_object_sizes (gcc::context *ctxt); extern gimple_opt_pass *make_pass_strlen (gcc::context *ctxt); extern gimple_opt_pass *make_pass_fold_builtins (gcc::context *ctxt); commit 9226e28436a030083690bc151c2fa1dcbb416fb1 Author: Thomas Schwinge <tho...@codesourcery.com> Date: Thu Oct 17 22:07:14 2013 +0200 Remove leftover variable definition. gcc/ * omp-low.c (tmp_ompfn_id_num): Remove leftover definition of variable that is unused as of r160016. diff --git gcc/omp-low.c gcc/omp-low.c index 819c442..54628f7 100644 --- gcc/omp-low.c +++ gcc/omp-low.c @@ -1820,8 +1820,6 @@ scan_sharing_clauses (tree clauses, omp_context *ctx) /* Create a new name for omp child function. Returns an identifier. */ -static GTY(()) unsigned int tmp_ompfn_id_num; - static tree create_omp_child_function_name (bool task_copy) { Grüße, Thomas
pgpif_4Y1tLCN.pgp
Description: PGP signature