/ChangeLog.jit b/gcc/ChangeLog.jit
index f8235f1..3a6ea52 100644
--- a/gcc/ChangeLog.jit
+++ b/gcc/ChangeLog.jit
@@ -1,3 +1,9 @@
+2014-07-14 David Malcolm
+
+ * cgraph.h (ipa_cp_c_finalize): Add prototype.
+ * ipa-cp.c (ipa_cp_c_finalize): New.
+ * toplev.c (toplev::finalize): Add
alue-not-a-numeric-type.c
diff --git a/gcc/jit/ChangeLog.jit b/gcc/jit/ChangeLog.jit
index 65fba51..3db15e8 100644
--- a/gcc/jit/ChangeLog.jit
+++ b/gcc/jit/ChangeLog.jit
@@ -1,3 +1,16 @@
+2014-07-25 David Malcolm
+
+ * TODO.rst (error-checking): Remove various items that either
+ al
On Mon, 2014-07-28 at 02:35 +0530, Prathamesh Kulkarni wrote:
> - if (o->type == operand::OP_CAPTURE)
> + if (is_a (o))
> {
> - capture *c = static_cast (o);
> - fprintf (f, "@%s", (static_cast (o))->where);
> + capture *c = as_a (o);
FWIW, if you're doing an is_a followed b
On Tue, 2014-07-29 at 19:36 +0200, Marc Glisse wrote:
> On Sun, 27 Jul 2014, Richard Sandiford wrote:
>
> > Marc Glisse writes:
> >> Hello,
> >>
> >> I followed the advice in this discussion:
> >> https://gcc.gnu.org/ml/gcc-patches/2014-04/msg00269.html
> >>
> >> and here is a new patch. I made a
On Tue, 2014-07-29 at 21:13 +0200, Marek Polacek wrote:
> On Tue, Jul 29, 2014 at 02:58:03PM -0400, David Malcolm wrote:
> > This is possibly a dumb question, but what happens for a static local,
> > rather than an auto local? e.g.
> >
> > int *f (void)
> > {
>
A complaint I heard at Cauldron with the C++ification of GCC passes is
that it's become much more difficult to set breakpoints on the execute
hooks of a pass, now that the passes are classes within anonymous
namespaces.
When this was first done, the execute methods were trivial
implementations tha
On Tue, 2014-07-29 at 16:44 -0400, David Malcolm wrote:
> A complaint I heard at Cauldron with the C++ification of GCC passes is
> that it's become much more difficult to set breakpoints on the execute
> hooks of a pass, now that the passes are classes within anonymous
> namespace
On Thu, 2014-04-17 at 19:52 +0200, Jan Hubicka wrote:
[...]
> Index: doc/invoke.texi
> ===
> --- doc/invoke.texi (revision 209461)
> +++ doc/invoke.texi (working copy)
> @@ -9409,7 +9409,8 @@ before applying @option{--param inlin
gcc/
* gimple.h (gimple_assign_single_p): Accept a const_gimple rather
than a gimple.
(gimple_store_p): Likewise.
(gimple_assign_load_p): Likewise.
(gimple_assign_cast_p): Likewise.
(gimple_clobber_p): Likewise.
---
gcc/gimple.h | 10 +-
1 fi
This updates all of the gimple_bind_* accessors in gimple.h from taking a
plain gimple to taking a gimple_bind (or const_gimple_bind), with the
checking happening at the point of cast.
Various other types are strengthened from gimple to gimple_bind, and from
plain vec to vec.
gcc/
* coret
gcc/
* tree-parloops.c (struct reduction_info): Strengthen field "new_phi"
from gimple to gimple_phi.
(create_phi_for_local_result): Convert local "new_phi" to gimple_phi.
(loop_has_vector_phi_nodes): Require a gimple_phi rather than a gimple.
(gather_scalar_
Accessors known not to need to be converted: 67
So this patch series as-is takes us a little over halfway there. The
remaining accessors would involve more substantial re-indenting (typically
to introduce blocks within case statements of a switch on statement code,
so I can introduce a type-checke
gcc/
* coretypes.h (gimple_assign): New typedef.
(const_gimple_assign): New typedef.
* gimple.h (struct gimple_statement_assign): New subclass of
gimple_statement_with_memory_ops, adding the invariant that
stmt->code == GIMPLE_ASSIGN.
(gimple_stateme
gcc/
* coretypes.h (gimple_omp_sections): New typedef.
(const_gimple_omp_sections): New typedef.
* gimple-pretty-print.c (dump_gimple_omp_sections): Require a
gimple_omp_sections rather than a plain gimple.
(pp_gimple_stmt_1): Add checked cast to gimple_omp_
gcc/
* tree-phinodes.h (add_phi_arg): Require a gimple_phi rather than
a plain gimple.
* tree-phinodes.c (add_phi_arg): Likewise.
* gimple-ssa-strength-reduction.c (create_phi_basis): Strengthen
local "phi" from plain gimple to gimple_phi.
* graphit
gcc/
* gimple.h (gimple_label_set_label): Require a gimple_label.
---
gcc/gimple.h | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/gcc/gimple.h b/gcc/gimple.h
index cf21083..38f4ea7 100644
--- a/gcc/gimple.h
+++ b/gcc/gimple.h
@@ -3490,9 +3490,8 @@ gimple_label_label
gcc/
* gimple.h (gimple_phi_arg_set_location): Require a gimple_phi
rather than a plain gimple.
---
gcc/gimple.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/gcc/gimple.h b/gcc/gimple.h
index e4d0455..6007516 100644
--- a/gcc/gimple.h
+++ b/gcc/gimple.h
gcc/
* gimple.h (gimple_catch_types): Require a const_gimple_catch
rather than a const_gimple.
---
gcc/gimple.h | 6 ++
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/gcc/gimple.h b/gcc/gimple.h
index 7dfd512..3c54119 100644
--- a/gcc/gimple.h
+++ b/gcc/gimple.h
gcc/
* gimple.h (gimple_eh_filter_set_types): Require a gimple_eh_filter.
(gimple_eh_filter_set_failure): Likewise.
* gimple.c (gimple_copy): Add checked casts to gimple_eh_filter
within GIMPLE_EH_FILTER case.
---
gcc/gimple.c | 13 +
gcc/gimple.h | 14 +
gcc/
* gimple.c (gimple_copy): Add checked casts to gimple_try.
* gimple.h (gimple_statement_base::dyn_cast_gimple_try): New.
(gimple_try_set_kind): Require a gimple_try.
(gimple_try_set_eval): Likewise.
(gimple_try_set_cleanup): Likewise.
* tree-eh
gcc/
* tree-parloops.c (reduction_info::keep_res): Strengthen field
from plain gimple to gimple_phi.
(transform_to_exit_first_loop): Strengthen locals "phi", "nphi"
to gimple_phi. Eliminate early decl of gimple_stmt_iterator gsi
in favor of more tightly scop
gcc/
* gimple.h (gimple_cond_true_label): Require a const_gimple_cond
rather than just a const_gimple.
(gimple_cond_false_label): Likewise.
* omp-low.c (diagnose_sb_2): Add checked cast to gimple_cond within
case GIMPLE_COND.
* tree-eh.c (maybe_recor
gcc/
* gimple.h (gimple_cond_lhs_ptr): Require a const_gimple_cond
rather than just a const_gimple_cond.
(gimple_cond_rhs_ptr): Likewise.
* gimplify-me.c (gimple_regimplify_operands): Add a checked cast
to gimple_cond within "case GIMPLE_COND".
* omp
gcc/
* asan.c (insert_if_then_before_iter): Require a gimple cond
rathern than a plain gimple.
(instrument_mem_region_access): Strengthen local from gimple to
gimple_cond.
* cfgloopmanip.c (create_empty_if_region_on_edge): Likewise.
* omp-low.c (sim
gcc/
* tree-ssa-dom.c (struct hashable_expr): Strengthen field
call.fn_from from gimple to gimple_call.
(initialize_hash_element): Replace check against GIMPLE_CALL
with dyn_cast_gimple_call and update gimple_call_ uses to use
new gimple_call local, along wit
gcc/
* gimple.h (gimple_call_set_tail): Require a gimple_call.
(gimple_call_tail_p): Likewise.
* cfgexpand.c (expand_gimple_tailcall): Likewise.
(expand_gimple_basic_block): Convert calls to is_gimple_call to a
dyn_cast, introducing a new "call_stmt" local.
gcc/
* ssa-iterators.h (FOR_EACH_PHI_OR_STMT_USE): Add checked cast to
gimple_phi.
(FOR_EACH_PHI_OR_STMT_DEF): Likewise.
* ssa-iterators.h (single_phi_def): Require a gimple_phi.
(op_iter_init_phiuse): Likewise.
(op_iter_init_phidef): Likewise.
gcc/
* gimple.h (gimple_call_copy_flags): Require gimple_calls.
* ipa-prop.c (ipa_modify_call_arguments): Require a gimple_call.
* ipa-prop.h (ipa_modify_call_arguments): Likewise.
* tree-inline.c (copy_bb): Replace is_gimple_call with new local
and call to
gcc/
* ipa-split.c (check_forbidden_calls): Replace check against
GIMPLE_COND with a dyn_cast_gimple_cond, introducing a gimple_cond
local.
* predict.c (predict_extra_loop_exits): Likewise.
* tree-vrp.c (fold_predicate_in): Likewise.
(simplify_stmt_fo
gcc/
* gimplify.c (gimplify_modify_expr): Introduce local "call_stmt".
---
gcc/gimplify.c | 20 +++-
1 file changed, 11 insertions(+), 9 deletions(-)
diff --git a/gcc/gimplify.c b/gcc/gimplify.c
index 031834b..d43304e 100644
--- a/gcc/gimplify.c
+++ b/gcc/gimplify.c
@@ -45
gcc/
* ipa-prop.c (detect_type_change): Require a gimple_call rather
than a plain gimple.
(detect_type_change_ssa): Likewise.
(compute_complex_assign_jump_func): Likewise.
(compute_complex_ancestor_jump_func): Likewise.
(compute_known_type_jump_func):
gcc/
* gimple.h (gimple_goto_set_dest): Require a gimple_goto.
* tree-cfg.c (factor_computed_gotos): Add checked cast to gimple_goto.
(cleanup_dead_labels): Likewise.
---
gcc/gimple.h | 3 +--
gcc/tree-cfg.c | 5 +++--
2 files changed, 4 insertions(+), 4 deletions(-)
di
gcc/
* gimple.h (gimple_try_set_catch_is_cleanup): Require a gimple_try.
* gimplify.c (gimplify_expr): Convert local "try_" from a gimple
to a gimple_try.
---
gcc/gimple.h | 2 +-
gcc/gimplify.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/gcc/g
gcc/
* coretypes.h (gimple_resx): New typedef.
(const_gimple_resx): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_resx): New.
(gimple_build_resx): Return a gimple_resx rather than a plain
gimple.
(gimple_resx_region): Require a const_gi
gcc/
* gimple.h (gimple_builtin_call_types_compatible_p): Accept a
const_gimple, rather than a gimple.
(gimple_call_builtin_p): Likewise, for the three variants.
* gimple.c (gimple_builtin_call_types_compatible_p): Likewise.
(gimple_call_builtin_p): Likewise
gcc/
* coretypes.h (gimple_omp_parallel): New typedef.
(const_gimple_omp_parallel): New typedef.
* cgraphbuild.c (build_cgraph_edges): Convert check of code
against GIMPLE_OMP_PARALLEL to a dyn_cast_gimple_omp_parallel and
new local.
* gimple-pretty
gcc/
* coretypes.h (gimple_omp_atomic_load): New typedef.
(const_gimple_omp_atomic_load): New typedef.
* gimple-pretty-print.c (dump_gimple_omp_atomic_load): Require a
gimple_omp_atomic_load rather than a plain gimple.
(pp_gimple_stmt_1): Add a checked cast
gcc/
* coretypes.h (gimple_omp_task): New typedef.
(const_gimple_omp_task): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_omp_task): New.
(gimple_build_omp_task): Return a gimple_omp_task
rather than a plain gimple.
* gimple-pretty-pri
gcc/
* coretypes.h (gimple_return): New typedef.
(const_gimple_return): New typedef.
* gimple.h (gimple_statement_return): New subclass of
gimple_statement_with_memory_ops, adding the invariant that
stmt->code == GIMPLE_RETURN.
(gimple_statement_base
gcc/
* coretypes.h (gimple_label): New typedef.
(const_gimple_label): New typedef.
* gimple.h (struct gimple_statement_label): New subclass of
gimple_statement_with_ops, adding the invariant that
stmt->code == GIMPLE_LABEL.
(gimple_statement_base::as
gcc/
* coretypes.h (gimple_cond): New typedef.
(const_gimple_cond): Likewise.
* gimple.h (struct gimple_statement_cond): New subclass of
gimple_statement_with_ops, adding the invariant that
stmt->code == GIMPLE_COND.
(gimple_statement_base::as_a_gimp
gcc/
* tree-ssa-loop-ivopts.c (determine_biv_step): Require a gimple_phi.
(find_bivs): Convert local "phi" into a gimple_phi.
(mark_bivs): Likewise.
---
gcc/tree-ssa-loop-ivopts.c | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/gcc/tree-ssa-loop-i
gcc/
* gimple.h (gimple_statement_switch): New subclass of
gimple_statement_with_ops, adding the invariant that
stmt->code == GIMPLE_SWITCH.
(gimple_statement_base::as_a_gimple_switch): New.
(gimple_statement_base::dyn_cast_gimple_switch): New.
(is_a_
gcc/
* tree-scalar-evolution.c (follow_ssa_edge): Require a gimple_phi,
rather than a gimple.
(follow_ssa_edge_binary): Likewise.
(follow_ssa_edge_expr): Likewise.
(follow_ssa_edge_in_rhs): Likewise.
(backedge_phi_arg_p): Likewise.
(follow_ssa
gcc/
* omp-low.c (expand_omp_for_init_counts): Eliminate local "stmt"
in favor of new locals "cond_stmt" and "assign_stmt" with more
concrete types.
---
gcc/omp-low.c | 25 +
1 file changed, 13 insertions(+), 12 deletions(-)
diff --git a/gcc/omp-low
gcc/
* gimple.h (gimple_call_set_nothrow): Require a gimple_call.
* trans-mem.c (ipa_tm_insert_gettmclone_call): Likewise.
(ipa_tm_transform_calls_redirect): Add checked cast to gimple call; this
is only called for gsi on a GIMPLE_CALL statement.
---
gcc/gimple.h
gcc/
* gimple.h (gimple_phi_arg_location): Require a gimple_phi.
* tree-into-ssa.c (rewrite_update_phi_arguments): Replace a check
for code GIMPLE_PHI with a dyn_cast and a new local.
* tree-ssa-ter.c (ter_is_replaceable_p): Likewise.
* tree-ssa-live.c (rem
gcc/
* gimple.h (gimple_call_arg_flags): Require a const_gimple_call
rather than a const_gimple.
* gimple.c (gimple_call_fnspec): Likewise.
(gimple_call_arg_flags): Likewise.
---
gcc/gimple.c | 4 ++--
gcc/gimple.h | 2 +-
2 files changed, 3 insertions(+), 3 deleti
gcc/
* gimple.h (gimple_call_set_fntype): Require a gimple_call.
* omp-low.c (lower_omp_1): Add a new local gimple_call "call_stmt",
from a checked cast to gimple_call within the "case GIMPLE_CALL",
for the regions where "stmt" is not subsequently overwritten.
---
gcc/
* gimple.h (gimple_phi_arg_def_ptr): Require a gimple_phi rather
than a plain gimple.
(gimple_phi_arg_has_location): Likewise.
* gimple-streamer-in.c (input_phi): Return a gimple_phi rather
than a plain gimple.
* gimple-streamer-out.c (output_ph
gcc/
* gimple.h (gimple_phi_set_result): Require a gimple_phi rather
than a plain gimple.
(gimple_phi_set_arg): Likewise.
* tree-outof-ssa.c (remove_gimple_phi_args): Likewise; add a checked
cast to gimple_phi.
* tree-sra.c (replace_removed_params_s
gcc/
* gimple.h (gimple_cond_set_true_label): Require a gimple_cond.
(gimple_cond_set_false_label): Likewise.
* tree-cfg.c (make_cond_expr_edges): Convert "entry" from gimple to
a gimple_cond.
(cleanup_dead_labels): Introduce a checked cast to a gimple_cond
gcc/
* gimple.h (gimple_phi_arg_location_from_edge): Require a
gimple_phi.
* tree-parloops.c (create_parallel_loop): Split up local variable
"stmt", introducing other locals for the various statements created
by this function. Reuse "stmt" within the phi-ha
gcc/
* gimple.h (gimple_assign_nontemporal_move_p): Require a
const_gimple_assign rather than a const_gimple.
* cfgexpand.c (expand_gimple_stmt_1): Add local assign_stmt and
checked cast within "case GIMPLE_ASSIGN".
* gimple-streamer-out.c (output_gimple_st
gcc/
* coretypes.h (gimple_omp_target): New typedef.
(const_gimple_omp_target): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_omp_target): New.
(gimple_build_omp_target): Return a gimple_omp_target
rather than a plain gimple.
(gimple_om
gcc/
* gimple.h (gimple_call_nothrow_p): Require a gimple_call.
* tree-eh.c (stmt_could_throw_p): Add checked cast to gimple_call.
* tree-vect-slp.c (vect_build_slp_tree_1): Replace call to
is_gimple_call with dyn_cast_gimple_call, introducing a local.
---
gcc/gim
gcc/
* omp-low.c (finalize_task_copyfn): Strengthen local "bind" from
plain gimple to gimple_bind.
(lower_rec_input_clauses): Strengthen local "g" from
plain gimple to gimple_assign.
(lower_lastprivate_clauses): Likewise for "stmt" to gimple_cond
and
gcc/
* coretypes.h (gimple_omp_single): New typedef.
(const_gimple_omp_single): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_omp_single): New.
(gimple_build_omp_single): Return a gimple_omp_single rather than
a plain gimple.
(gimple_om
gcc/
* coretypes.h (gimple_omp_continue): New typedef.
(const_gimple_omp_continue): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_omp_continue): New.
(gimple_build_omp_continue): Return a gimple_omp_continue rather
than a plain gimple.
gcc/
* gimple.h (gimple_cond_make_false): Require a gimple_cond.
(gimple_cond_make_true): Likewise.
* tree-cfg.c (fold_cond_expr_cond): Add a checked cast to
gimple_cond within region guarded by check for GIMPLE_COND.
* tree-ssa-ccp.c (ccp_fold_stmt): Likewi
gcc/
* coretypes.h (gimple_transaction): New typedef.
(const_gimple_transaction): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_transaction): New.
(gimple_statement_base::dyn_cast_gimple_transaction): New.
(gimple_build_transaction): Return a g
gcc/
* gimple.h (gimple_switch_index): Require a const_gimple_switch rather
than a plain const_gimple.
(gimple_switch_index_ptr): Likewise.
* gimplify-me.c (gimple_regimplify_operands): Add checked cast to
gimple_switch within "case GIMPLE_SWITCH".
*
gcc/
* gimple.h (gimple_cond_set_code): Require a gimple_cond.
* tree-complex.c (expand_complex_comparison): Add a checked cast to
gimple_cond within "case GIMPLE_COND".
* tree-ssa-loop-ivcanon.c (create_canonical_iv): Convert local "cond"
to a gimple_cond,
gcc/
* gimple.h (gimple_label_label): Require a const_gimple_label
rather than just a const_gimple.
* cfgexpand.c (label_rtx_for_bb): Convert local from gimple to
gimple_label, replacing a check against GIMPLE_LABEL with a
dyn_cast_gimple_label.
* pr
gcc/
* coretypes.h (gimple_catch): New typedef.
(const_gimple_catch): New typedef.
* gimple-low.c (lower_try_catch): Add checked cast to gimple_catch.
(gimple_try_catch_may_fallthru): Likewise.
* gimple-pretty-print.c (dump_gimple_catch): Require a gimple_c
gcc/
* coretypes.h (gimple_eh_else): New typedef.
(const_gimple_eh_else): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_eh_else): New.
(gimple_build_eh_else): Return a gimple_eh_else rather than a
plain gimple.
(gimple_eh_else_n_body_pt
gcc/
* coretypes.h (gimple_omp_critical): New typedef.
(const_gimple_omp_critical): New typedef.
* gimple-pretty-print.c (dump_gimple_omp_critical): Require a
gimple_omp_critical rather than a plain gimple.
(pp_gimple_stmt_1): Add a checked cast to gimple_om
gcc/
* gimple.c (gimple_call_copy_skip_args): Require a gimple_call.
* gimple.h (gimple_call_copy_skip_args): Likewise.
---
gcc/gimple.c | 2 +-
gcc/gimple.h | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/gcc/gimple.c b/gcc/gimple.c
index 6de651d..75a9f5f 10
gcc/
* coretypes.h (gimple_try): New typedef.
(const_gimple_try): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_try): New.
* gimple-low.c (gimple_try_catch_may_fallthru): Require a
gimple_try rather than a plain gimple.
(gimple_stmt_ma
gcc/
* coretypes.h (gimple_phi): New typedef.
(const_gimple_phi): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_phi): New.
(gimple_statement_base::dyn_cast_gimple_phi): New.
* gdbhooks.py (build_pretty_printer): Add gimple_phi and its
gcc/
* graphite-scop-detection.c (canonicalize_loop_closed_ssa):
Strengthen local "psi" to be a gimple_phi_iterator and "phi" to
a gimple_phi.
* graphite-sese-to-poly.c (phi_arg_in_outermost_loop): Require
a gimple_phi rathen than a plain gimple.
(re
gcc/
* coretypes.h (gimple_eh_must_not_throw): New typedef.
(const_gimple_eh_must_not_throw): New typedef.
* gimple-pretty-print.c (dump_gimple_eh_must_not_throw): Require
a gimple_eh_must_not_throw rather than a plain gimple.
(pp_gimple_stmt_1): Add a check
gcc/
* tree-ssa-propagate.h (typedef ssa_prop_visit_phi_fn): Strengthen
type of parameter from gimple to gimple_phi.
* tree-complex.c (complex_visit_phi): Update signature of callback
implementation accordingly.
* tree-ssa-ccp.c (ccp_visit_phi_node): Likewis
gcc/
* tree-scalar-evolution.h (get_loop_exit_condition): Return a
gimple_cond.
* tree-scalar-evolution.c (get_loop_exit_condition): Likewise, also
concretizing local "res" from gimple to gimple_cond.
* tree-vect-loop-manip.c (slpeel_make_loop_iterate_ntimes)
gcc/
* tree-ssa-loop-manip.c (add_exit_phi): Convert local "phi" to be a
gimple_phi.
(split_loop_exit_edge): Likewise for "phi" and "new_phi".
---
gcc/tree-ssa-loop-manip.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/gcc/tree-ssa-loop-manip.c b/g
gcc/
* coretypes.h (gimple_eh_filter): New typedef.
(const_gimple_eh_filter): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_eh_filter): New.
(gimple_build_eh_filter): Return a gimple_eh_filter rather than a
plain gimple.
* gimple-prett
gcc/
* cgraph.h (cgraph_edge::call_stmt): Strengthen field from plain
gimple to a gimple_call.
(cgraph_create_edge): Require a gimple_call rather than a plain
gimple.
(cgraph_create_indirect_edge): Likewise.
(cgraph_set_call_stmt): Likewise.
(
gcc/
* gimple.h (gimple_cond_set_lhs): Require a gimple_cond.
(gimple_cond_set_rhs): Likewise.
* tree-parloops.c (transform_to_exit_first_loop): Convert locals
"cond_stmt" and "cond_nit" to gimple_cond, adding checked casts,
since the existing code assumes t
gcc/
* gimple.h (gimple_call_use_set): Require a gimple_call.
(gimple_call_clobber_set): Likewise.
---
gcc/gimple.h | 10 --
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/gcc/gimple.h b/gcc/gimple.h
index 3c54119..e4aeec6 100644
--- a/gcc/gimple.h
+++ b/gcc/
gcc/
* cgraphunit.c (thunk_adjust): Strengthen local "stmt" from gimple
to gimple_assign.
* gimple-ssa-isolate-paths.c
(insert_trap_and_remove_trailing_statements): Strengthen local
"new_stmt" from gimple to gimple_call.
* gimple-ssa-strength-reduct
gcc/
* gimple.h (gimple_call_set_fn): Require a gimple_call.
* trans-mem.c (dump_tm_memopt_transform): Likewise.
(tm_memopt_transform_blocks): Add checked casts to gimple_call in
suites guarded by is_tm_simple_{load|store}, which enforce that
the statement m
gcc/
* coretypes.h (gimple_omp_for): New.
(const_gimple_omp_for): New.
* gimple.h (gimple_statement_base::as_a_gimple_omp_for): New.
(gimple_statement_base::dyn_cast_gimple_omp_for): New.
(gimple_build_omp_for): Return a gimple_omp_for rather than a
gcc/
* coretypes.h (gimple_omp_atomic_store): New typedef.
(const_gimple_omp_atomic_store): New typedef.
* gimple-pretty-print.c (dump_gimple_omp_atomic_store): Require
a gimple_omp_atomic_store rather than a plain gimple.
(pp_gimple_stmt_1): Add checked cas
gcc/
* gimple.h (gimple_phi_arg_edge): Require a gimple_phi rather
than a plain gimple.
* graphite-sese-to-poly.c (rewrite_phi_out_of_ssa): Require a
gimple_phi_iterator; strengthen local "phi" from gimple to a
gimple_phi.
(rewrite_cross_bb_scalar_de
gcc/
* tree-predcom.c (find_looparound_phi): Return a gimple_phi rather
than just a gimple.
(insert_looparound_copy): Require a gimple_phi rather than just a
gimple.
(add_looparound_copies): Convert local "phi" to be a gimple_phi.
(initialize_root_var
gcc/
* coretypes.h (gimple_debug): New typedef.
(const_gimple_debug): New typedef.
* gimple.h (struct gimple_statement_debug): New subclass of
gimple_statement_with_ops, adding the invariant that
stmt->code == GIMPLE_DEBUG.
(gimple_statement_base::as
gcc/
* coretypes.h (gimple_goto): New typedef.
(const_gimple_goto): New typedef.
* gimple.h (gimple_statement_goto): New subclass of
gimple_statement_with_ops, adding the invariant that
stmt->code == GIMPLE_GOTO.
(gimple_statement_base::as_a_gimple_g
gcc/
* tree-ssa-loop-niter.c (chain_of_csts_start): Return a gimple_phi
rather than a gimple.
(get_base_for): Likewise; convert local "phi" to be a gimple_phi.
(loop_niter_by_eval): Convert local "phi" to be a gimple_phi.
---
gcc/tree-ssa-loop-niter.c | 11 ++---
gcc/
* coretypes.h (gimple_omp_teams): New typedef.
(const_gimple_omp_teams): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_omp_teams): New.
(gimple_build_omp_teams): Return a gimple_omp_teams rather than a
plain gimple.
(gimple_omp_tea
gcc/
* gimple.h (gimple_call_return_slot_opt_p): Require a gimple_call
rather than a plain gimple.
* gimple-walk.c (walk_stmt_load_store_addr_ops): Convert usage of
is_gimple_call to dyn_cast_gimple_call, introducing a new local
"call_stmt".
* trans
gcc/
* tree-cfg.c (verify_gimple_call): Require a gimple_call rather
than a plain gimple.
(verify_gimple_stmt): Add checked cast to gimple_call within
GIMPLE_CALL case of switch statement.
---
gcc/tree-cfg.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
gcc/
* gimple.h (gimple_return_retval_ptr): Require a const_gimple_return
rather than a const_gimple.
(gimple_return_retval): Likewise.
(gimple_return_set_retval): Require a gimple_return.
* cfgexpand.c (expand_gimple_stmt_1): Add a checked cast to
g
gcc/
* coretypes.h (gimple_asm): New typedef.
(const_gimple_asm): New typedef.
* gimple.h (gimple_statement_base::as_a_gimple_asm): New.
gimple_statement_base::dyn_cast_gimple_asm): New.
(gimple_build_asm_vec): Return a gimple_asm rather than
just a
gcc/
* tree-ssa-phiprop.c (phiprop_insert_phi): Strengthen types of
parameter "phi" and local "new_phi" from gimple to gimple_phi.
---
gcc/tree-ssa-phiprop.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/gcc/tree-ssa-phiprop.c b/gcc/tree-ssa-phiprop.c
inde
gcc/
* coretypes.h (gimple_eh_dispatch): New typedef.
(const_gimple_eh_dispatch): New typedef.
* gimple-pretty-print.c (dump_gimple_eh_dispatch): Require a
gimple_eh_dispatch rather than a plain gimple.
(pp_gimple_stmt_1): Add a checked cast to gimple_eh_dis
On Mon, 2014-04-21 at 12:43 -0600, Jeff Law wrote:
> On 04/21/14 10:56, David Malcolm wrote:
> > gcc/
> > * gimple.h (gimple_assign_single_p): Accept a const_gimple rather
> > than a gimple.
> > (gimple_store_p): Likewise.
> >
On Tue, 2014-04-22 at 09:03 +0100, Richard Sandiford wrote:
> First of all, thanks a lot for doing this. Maybe one day we'll have
> the same in rtl :-)
>
> But...
>
> David Malcolm writes:
> > In doing the checked downcasts I ran into the verbosity of the as_a <
On Mon, 2014-04-21 at 18:45 -0400, Trevor Saunders wrote:
> > --- a/gcc/tree-loop-distribution.c
> > +++ b/gcc/tree-loop-distribution.c
> > @@ -687,8 +687,9 @@ generate_loops_for_partition (struct loop *loop,
> > partition_t partition,
> > }
> > else if (gimple_code (stmt) ==
On Tue, 2014-04-22 at 11:37 -0400, Trevor Saunders wrote:
> > diff --git a/gcc/tree-vrp.c b/gcc/tree-vrp.c
> > index 902b879..62ec9f5 100644
> > --- a/gcc/tree-vrp.c
> > +++ b/gcc/tree-vrp.c
> > @@ -9517,10 +9517,11 @@ fold_predicate_in (gimple_stmt_iterator *si)
> >else
> > {
> >
On Tue, 2014-04-22 at 09:05 -0400, Andrew MacLeod wrote:
> On 04/22/2014 04:03 AM, Richard Sandiford wrote:
> > First of all, thanks a lot for doing this. Maybe one day we'll have
> > the same in rtl :-)
> >
> > But...
> >
> > David Malcolm writes:
&g
1201 - 1300 of 2079 matches
Mail list logo