typedef gimple gimple_seq_node;
-/* For each block, the PHI nodes that need to be rewritten are stored into
- these vectors. */
-typedef vec<gimple> gimple_vec;
-
enum gimple_code {
#define DEFGSCODE(SYM, STRING, STRUCT) SYM,
#include "gimple.def"
GF_CALL_NOTHROW = 1 << 4,
GF_CALL_ALLOCA_FOR_VAR = 1 << 5,
GF_CALL_INTERNAL = 1 << 6,
+ GF_CALL_CTRL_ALTERING = 1 << 7,
+ GF_CALL_WITH_BOUNDS = 1 << 8,
GF_OMP_PARALLEL_COMBINED = 1 << 0,
- GF_OMP_FOR_KIND_MASK = (1 << 2) - 1,
+ GF_OMP_FOR_KIND_MASK = 7 << 0,
GF_OMP_FOR_KIND_FOR = 0,
GF_OMP_FOR_KIND_DISTRIBUTE = 1,
+ GF_OMP_FOR_KIND_CILKFOR = 2,
/* Flag for SIMD variants of OMP_FOR kinds. */
- GF_OMP_FOR_SIMD = 1 << 1,
+ GF_OMP_FOR_SIMD = 1 << 2,
GF_OMP_FOR_KIND_SIMD = GF_OMP_FOR_SIMD | 0,
GF_OMP_FOR_KIND_CILKSIMD = GF_OMP_FOR_SIMD | 1,
- GF_OMP_FOR_COMBINED = 1 << 2,
- GF_OMP_FOR_COMBINED_INTO = 1 << 3,
+ GF_OMP_FOR_COMBINED = 1 << 3,
+ GF_OMP_FOR_COMBINED_INTO = 1 << 4,
GF_OMP_TARGET_KIND_MASK = (1 << 2) - 1,
GF_OMP_TARGET_KIND_REGION = 0,
GF_OMP_TARGET_KIND_DATA = 1,
/* Call statements that take both memory and register operands. */
struct GTY((tag("GSS_CALL")))
- gimple_statement_call : public gimple_statement_with_memory_ops_base
+ gcall : public gimple_statement_with_memory_ops_base
{
/* [ WORD 1-9 ] : base class */
/* GIMPLE_BIND */
struct GTY((tag("GSS_BIND")))
- gimple_statement_bind : public gimple_statement_base
+ gbind : public gimple_statement_base
{
/* [ WORD 1-6 ] : base class */
/* GIMPLE_CATCH */
struct GTY((tag("GSS_CATCH")))
- gimple_statement_catch : public gimple_statement_base
+ gcatch : public gimple_statement_base
{
/* [ WORD 1-6 ] : base class */
/* GIMPLE_EH_FILTER */
struct GTY((tag("GSS_EH_FILTER")))
- gimple_statement_eh_filter : public gimple_statement_base
+ geh_filter : public gimple_statement_base
{
/* [ WORD 1-6 ] : base class */
/* GIMPLE_EH_ELSE */
struct GTY((tag("GSS_EH_ELSE")))
- gimple_statement_eh_else : public gimple_statement_base
+ geh_else : public gimple_statement_base
{
/* [ WORD 1-6 ] : base class */
/* GIMPLE_EH_MUST_NOT_THROW */
struct GTY((tag("GSS_EH_MNT")))
- gimple_statement_eh_mnt : public gimple_statement_base
+ geh_mnt : public gimple_statement_base
{
/* [ WORD 1-6 ] : base class */
/* GIMPLE_PHI */
struct GTY((tag("GSS_PHI")))
- gimple_statement_phi : public gimple_statement_base
+ gphi : public gimple_statement_base
{
/* [ WORD 1-6 ] : base class */
};
struct GTY((tag("GSS_EH_CTRL")))
- gimple_statement_resx : public gimple_statement_eh_ctrl
+ gresx : public gimple_statement_eh_ctrl
{
/* No extra fields; adds invariant:
stmt->code == GIMPLE_RESX. */
};
struct GTY((tag("GSS_EH_CTRL")))
- gimple_statement_eh_dispatch : public gimple_statement_eh_ctrl
+ geh_dispatch : public gimple_statement_eh_ctrl
{
/* No extra fields; adds invariant:
stmt->code == GIMPLE_EH_DISPATH. */
/* GIMPLE_TRY */
struct GTY((tag("GSS_TRY")))
- gimple_statement_try : public gimple_statement_base
+ gtry : public gimple_statement_base
{
/* [ WORD 1-6 ] : base class */
/* GIMPLE_ASM */
struct GTY((tag("GSS_ASM")))
- gimple_statement_asm : public gimple_statement_with_memory_ops_base
+ gasm : public gimple_statement_with_memory_ops_base
{
/* [ WORD 1-9 ] : base class */
/* GIMPLE_OMP_CRITICAL */
struct GTY((tag("GSS_OMP_CRITICAL")))
- gimple_statement_omp_critical : public gimple_statement_omp
+ gomp_critical : public gimple_statement_omp
{
/* [ WORD 1-7 ] : base class */
/* GIMPLE_OMP_FOR */
struct GTY((tag("GSS_OMP_FOR")))
- gimple_statement_omp_for : public gimple_statement_omp
+ gomp_for : public gimple_statement_omp
{
/* [ WORD 1-7 ] : base class */
/* GIMPLE_OMP_PARALLEL */
struct GTY((tag("GSS_OMP_PARALLEL_LAYOUT")))
- gimple_statement_omp_parallel : public gimple_statement_omp_taskreg
+ gomp_parallel : public gimple_statement_omp_taskreg
{
/* No extra fields; adds invariant:
stmt->code == GIMPLE_OMP_PARALLEL. */
};
struct GTY((tag("GSS_OMP_PARALLEL_LAYOUT")))
- gimple_statement_omp_target : public gimple_statement_omp_parallel_layout
+ gomp_target : public gimple_statement_omp_parallel_layout
{
/* No extra fields; adds invariant:
stmt->code == GIMPLE_OMP_TARGET. */
/* GIMPLE_OMP_TASK */
struct GTY((tag("GSS_OMP_TASK")))
- gimple_statement_omp_task : public gimple_statement_omp_taskreg
+ gomp_task : public gimple_statement_omp_taskreg
{
/* [ WORD 1-10 ] : base class */
/* GIMPLE_OMP_SECTIONS */
struct GTY((tag("GSS_OMP_SECTIONS")))
- gimple_statement_omp_sections : public gimple_statement_omp
+ gomp_sections : public gimple_statement_omp
{
/* [ WORD 1-7 ] : base class */
do not need the body field. */
struct GTY((tag("GSS_OMP_CONTINUE")))
- gimple_statement_omp_continue : public gimple_statement_base
+ gomp_continue : public gimple_statement_base
{
/* [ WORD 1-6 ] : base class */
};
struct GTY((tag("GSS_OMP_SINGLE_LAYOUT")))
- gimple_statement_omp_single : public gimple_statement_omp_single_layout
+ gomp_single : public gimple_statement_omp_single_layout
{
/* No extra fields; adds invariant:
stmt->code == GIMPLE_OMP_SINGLE. */
};
struct GTY((tag("GSS_OMP_SINGLE_LAYOUT")))
- gimple_statement_omp_teams : public gimple_statement_omp_single_layout
+ gomp_teams : public gimple_statement_omp_single_layout
{
/* No extra fields; adds invariant:
stmt->code == GIMPLE_OMP_TEAMS. */
contains a sequence, which we don't need here. */
struct GTY((tag("GSS_OMP_ATOMIC_LOAD")))
- gimple_statement_omp_atomic_load : public gimple_statement_base
+ gomp_atomic_load : public gimple_statement_base
{
/* [ WORD 1-6 ] : base class */
};
struct GTY((tag("GSS_OMP_ATOMIC_STORE_LAYOUT")))
- gimple_statement_omp_atomic_store :
+ gomp_atomic_store :
public gimple_statement_omp_atomic_store_layout
{
/* No extra fields; adds invariant:
#define GTMA_HAS_NO_INSTRUMENTATION (1u << 7)
struct GTY((tag("GSS_TRANSACTION")))
- gimple_statement_transaction : public gimple_statement_with_memory_ops_base
+ gtransaction : public gimple_statement_with_memory_ops_base
{
/* [ WORD 1-9 ] : base class */
};
#undef DEFGSSTRUCT
+/* A statement with the invariant that
+ stmt->code == GIMPLE_COND
+ i.e. a conditional jump statement. */
+
+struct GTY((tag("GSS_WITH_OPS")))
+ gcond : public gimple_statement_with_ops
+{
+ /* no additional fields; this uses the layout for GSS_WITH_OPS. */
+};
+
+/* A statement with the invariant that
+ stmt->code == GIMPLE_DEBUG
+ i.e. a debug statement. */
+
+struct GTY((tag("GSS_WITH_OPS")))
+ gdebug : public gimple_statement_with_ops
+{
+ /* no additional fields; this uses the layout for GSS_WITH_OPS. */
+};
+
+/* A statement with the invariant that
+ stmt->code == GIMPLE_GOTO
+ i.e. a goto statement. */
+
+struct GTY((tag("GSS_WITH_OPS")))
+ ggoto : public gimple_statement_with_ops
+{
+ /* no additional fields; this uses the layout for GSS_WITH_OPS. */
+};
+
+/* A statement with the invariant that
+ stmt->code == GIMPLE_LABEL
+ i.e. a label statement. */
+
+struct GTY((tag("GSS_WITH_OPS")))
+ glabel : public gimple_statement_with_ops
+{
+ /* no additional fields; this uses the layout for GSS_WITH_OPS. */
+};
+
+/* A statement with the invariant that
+ stmt->code == GIMPLE_SWITCH
+ i.e. a switch statement. */
+
+struct GTY((tag("GSS_WITH_OPS")))
+ gswitch : public gimple_statement_with_ops
+{
+ /* no additional fields; this uses the layout for GSS_WITH_OPS. */
+};
+
+/* A statement with the invariant that
+ stmt->code == GIMPLE_ASSIGN
+ i.e. an assignment statement. */
+
+struct GTY((tag("GSS_WITH_MEM_OPS")))
+ gassign : public gimple_statement_with_memory_ops
+{
+ /* no additional fields; this uses the layout for GSS_WITH_MEM_OPS. */
+};
+
+/* A statement with the invariant that
+ stmt->code == GIMPLE_RETURN
+ i.e. a return statement. */
+
+struct GTY((tag("GSS_WITH_MEM_OPS")))
+ greturn : public gimple_statement_with_memory_ops
+{
+ /* no additional fields; this uses the layout for GSS_WITH_MEM_OPS. */
+};
+
template <>
template <>
inline bool
-is_a_helper <gimple_statement_asm *>::test (gimple gs)
+is_a_helper <gasm *>::test (gimple gs)
{
return gs->code == GIMPLE_ASM;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_bind *>::test (gimple gs)
+is_a_helper <gassign *>::test (gimple gs)
+{
+ return gs->code == GIMPLE_ASSIGN;
+}
+
+template <>
+template <>
+inline bool
+is_a_helper <gbind *>::test (gimple gs)
{
return gs->code == GIMPLE_BIND;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_call *>::test (gimple gs)
+is_a_helper <gcall *>::test (gimple gs)
{
return gs->code == GIMPLE_CALL;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_catch *>::test (gimple gs)
+is_a_helper <gcatch *>::test (gimple gs)
{
return gs->code == GIMPLE_CATCH;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_resx *>::test (gimple gs)
+is_a_helper <gcond *>::test (gimple gs)
+{
+ return gs->code == GIMPLE_COND;
+}
+
+template <>
+template <>
+inline bool
+is_a_helper <gdebug *>::test (gimple gs)
+{
+ return gs->code == GIMPLE_DEBUG;
+}
+
+template <>
+template <>
+inline bool
+is_a_helper <ggoto *>::test (gimple gs)
+{
+ return gs->code == GIMPLE_GOTO;
+}
+
+template <>
+template <>
+inline bool
+is_a_helper <glabel *>::test (gimple gs)
+{
+ return gs->code == GIMPLE_LABEL;
+}
+
+template <>
+template <>
+inline bool
+is_a_helper <gresx *>::test (gimple gs)
{
return gs->code == GIMPLE_RESX;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_eh_dispatch *>::test (gimple gs)
+is_a_helper <geh_dispatch *>::test (gimple gs)
{
return gs->code == GIMPLE_EH_DISPATCH;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_eh_else *>::test (gimple gs)
+is_a_helper <geh_else *>::test (gimple gs)
{
return gs->code == GIMPLE_EH_ELSE;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_eh_filter *>::test (gimple gs)
+is_a_helper <geh_filter *>::test (gimple gs)
{
return gs->code == GIMPLE_EH_FILTER;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_eh_mnt *>::test (gimple gs)
+is_a_helper <geh_mnt *>::test (gimple gs)
{
return gs->code == GIMPLE_EH_MUST_NOT_THROW;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_omp_atomic_load *>::test (gimple gs)
+is_a_helper <gomp_atomic_load *>::test (gimple gs)
{
return gs->code == GIMPLE_OMP_ATOMIC_LOAD;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_omp_atomic_store *>::test (gimple gs)
+is_a_helper <gomp_atomic_store *>::test (gimple gs)
{
return gs->code == GIMPLE_OMP_ATOMIC_STORE;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_omp_continue *>::test (gimple gs)
+is_a_helper <gomp_continue *>::test (gimple gs)
{
return gs->code == GIMPLE_OMP_CONTINUE;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_omp_critical *>::test (gimple gs)
+is_a_helper <gomp_critical *>::test (gimple gs)
{
return gs->code == GIMPLE_OMP_CRITICAL;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_omp_for *>::test (gimple gs)
+is_a_helper <gomp_for *>::test (gimple gs)
{
return gs->code == GIMPLE_OMP_FOR;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_omp_parallel *>::test (gimple gs)
+is_a_helper <gomp_parallel *>::test (gimple gs)
{
return gs->code == GIMPLE_OMP_PARALLEL;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_omp_target *>::test (gimple gs)
+is_a_helper <gomp_target *>::test (gimple gs)
{
return gs->code == GIMPLE_OMP_TARGET;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_omp_sections *>::test (gimple gs)
+is_a_helper <gomp_sections *>::test (gimple gs)
{
return gs->code == GIMPLE_OMP_SECTIONS;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_omp_single *>::test (gimple gs)
+is_a_helper <gomp_single *>::test (gimple gs)
{
return gs->code == GIMPLE_OMP_SINGLE;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_omp_teams *>::test (gimple gs)
+is_a_helper <gomp_teams *>::test (gimple gs)
{
return gs->code == GIMPLE_OMP_TEAMS;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_omp_task *>::test (gimple gs)
+is_a_helper <gomp_task *>::test (gimple gs)
{
return gs->code == GIMPLE_OMP_TASK;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_phi *>::test (gimple gs)
+is_a_helper <gphi *>::test (gimple gs)
{
return gs->code == GIMPLE_PHI;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_transaction *>::test (gimple gs)
+is_a_helper <greturn *>::test (gimple gs)
+{
+ return gs->code == GIMPLE_RETURN;
+}
+
+template <>
+template <>
+inline bool
+is_a_helper <gswitch *>::test (gimple gs)
+{
+ return gs->code == GIMPLE_SWITCH;
+}
+
+template <>
+template <>
+inline bool
+is_a_helper <gtransaction *>::test (gimple gs)
{
return gs->code == GIMPLE_TRANSACTION;
}
template <>
template <>
inline bool
-is_a_helper <gimple_statement_try *>::test (gimple gs)
+is_a_helper <gtry *>::test (gimple gs)
{
return gs->code == GIMPLE_TRY;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_asm *>::test (const_gimple gs)
+is_a_helper <const gasm *>::test (const_gimple gs)
{
return gs->code == GIMPLE_ASM;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_bind *>::test (const_gimple gs)
+is_a_helper <const gbind *>::test (const_gimple gs)
{
return gs->code == GIMPLE_BIND;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_call *>::test (const_gimple gs)
+is_a_helper <const gcall *>::test (const_gimple gs)
{
return gs->code == GIMPLE_CALL;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_catch *>::test (const_gimple gs)
+is_a_helper <const gcatch *>::test (const_gimple gs)
{
return gs->code == GIMPLE_CATCH;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_resx *>::test (const_gimple gs)
+is_a_helper <const gresx *>::test (const_gimple gs)
{
return gs->code == GIMPLE_RESX;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_eh_dispatch *>::test (const_gimple gs)
+is_a_helper <const geh_dispatch *>::test (const_gimple gs)
{
return gs->code == GIMPLE_EH_DISPATCH;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_eh_filter *>::test (const_gimple gs)
+is_a_helper <const geh_filter *>::test (const_gimple gs)
{
return gs->code == GIMPLE_EH_FILTER;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_omp_atomic_load *>::test (const_gimple gs)
+is_a_helper <const gomp_atomic_load *>::test (const_gimple gs)
{
return gs->code == GIMPLE_OMP_ATOMIC_LOAD;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_omp_atomic_store *>::test (const_gimple gs)
+is_a_helper <const gomp_atomic_store *>::test (const_gimple gs)
{
return gs->code == GIMPLE_OMP_ATOMIC_STORE;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_omp_continue *>::test (const_gimple gs)
+is_a_helper <const gomp_continue *>::test (const_gimple gs)
{
return gs->code == GIMPLE_OMP_CONTINUE;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_omp_critical *>::test (const_gimple gs)
+is_a_helper <const gomp_critical *>::test (const_gimple gs)
{
return gs->code == GIMPLE_OMP_CRITICAL;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_omp_for *>::test (const_gimple gs)
+is_a_helper <const gomp_for *>::test (const_gimple gs)
{
return gs->code == GIMPLE_OMP_FOR;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_omp_parallel *>::test (const_gimple gs)
+is_a_helper <const gomp_parallel *>::test (const_gimple gs)
{
return gs->code == GIMPLE_OMP_PARALLEL;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_omp_target *>::test (const_gimple gs)
+is_a_helper <const gomp_target *>::test (const_gimple gs)
{
return gs->code == GIMPLE_OMP_TARGET;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_omp_sections *>::test (const_gimple gs)
+is_a_helper <const gomp_sections *>::test (const_gimple gs)
{
return gs->code == GIMPLE_OMP_SECTIONS;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_omp_single *>::test (const_gimple gs)
+is_a_helper <const gomp_single *>::test (const_gimple gs)
{
return gs->code == GIMPLE_OMP_SINGLE;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_omp_teams *>::test (const_gimple gs)
+is_a_helper <const gomp_teams *>::test (const_gimple gs)
{
return gs->code == GIMPLE_OMP_TEAMS;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_omp_task *>::test (const_gimple gs)
+is_a_helper <const gomp_task *>::test (const_gimple gs)
{
return gs->code == GIMPLE_OMP_TASK;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_phi *>::test (const_gimple gs)
+is_a_helper <const gphi *>::test (const_gimple gs)
{
return gs->code == GIMPLE_PHI;
}
template <>
template <>
inline bool
-is_a_helper <const gimple_statement_transaction *>::test (const_gimple gs)
+is_a_helper <const gtransaction *>::test (const_gimple gs)
{
return gs->code == GIMPLE_TRANSACTION;
}
#define gimple_alloc(c, n) gimple_alloc_stat (c, n MEM_STAT_INFO)
gimple gimple_alloc_stat (enum gimple_code, unsigned MEM_STAT_DECL);
-gimple gimple_build_return (tree);
-void gimple_call_reset_alias_info (gimple);
-gimple gimple_build_call_vec (tree, vec<tree> );
-gimple gimple_build_call (tree, unsigned, ...);
-gimple gimple_build_call_valist (tree, unsigned, va_list);
-gimple gimple_build_call_internal (enum internal_fn, unsigned, ...);
-gimple gimple_build_call_internal_vec (enum internal_fn, vec<tree> );
-gimple gimple_build_call_from_tree (tree);
-gimple gimple_build_assign_stat (tree, tree MEM_STAT_DECL);
+greturn *gimple_build_return (tree);
+void gimple_call_reset_alias_info (gcall *);
+gcall *gimple_build_call_vec (tree, vec<tree> );
+gcall *gimple_build_call (tree, unsigned, ...);
+gcall *gimple_build_call_valist (tree, unsigned, va_list);
+gcall *gimple_build_call_internal (enum internal_fn, unsigned, ...);
+gcall *gimple_build_call_internal_vec (enum internal_fn, vec<tree> );
+gcall *gimple_build_call_from_tree (tree);
+gassign *gimple_build_assign_stat (tree, tree MEM_STAT_DECL);
#define gimple_build_assign(l,r) gimple_build_assign_stat (l, r MEM_STAT_INFO)
-gimple gimple_build_assign_with_ops (enum tree_code, tree,
- tree, tree, tree CXX_MEM_STAT_INFO);
-gimple gimple_build_assign_with_ops (enum tree_code, tree,
- tree, tree CXX_MEM_STAT_INFO);
-gimple gimple_build_cond (enum tree_code, tree, tree, tree, tree);
-gimple gimple_build_cond_from_tree (tree, tree, tree);
-void gimple_cond_set_condition_from_tree (gimple, tree);
-gimple gimple_build_label (tree label);
-gimple gimple_build_goto (tree dest);
+gassign *gimple_build_assign_with_ops (enum tree_code, tree,
+ tree, tree, tree CXX_MEM_STAT_INFO);
+gassign *gimple_build_assign_with_ops (enum tree_code, tree,
+ tree, tree CXX_MEM_STAT_INFO);
+gassign *gimple_build_assign_with_ops (enum tree_code, tree,
+ tree CXX_MEM_STAT_INFO);
+gcond *gimple_build_cond (enum tree_code, tree, tree, tree, tree);
+gcond *gimple_build_cond_from_tree (tree, tree, tree);
+void gimple_cond_set_condition_from_tree (gcond *, tree);
+glabel *gimple_build_label (tree label);
+ggoto *gimple_build_goto (tree dest);
gimple gimple_build_nop (void);
-gimple gimple_build_bind (tree, gimple_seq, tree);
-gimple gimple_build_asm_vec (const char *, vec<tree, va_gc> *,
- vec<tree, va_gc> *, vec<tree, va_gc> *,
- vec<tree, va_gc> *);
-gimple gimple_build_catch (tree, gimple_seq);
-gimple gimple_build_eh_filter (tree, gimple_seq);
-gimple gimple_build_eh_must_not_throw (tree);
-gimple gimple_build_eh_else (gimple_seq, gimple_seq);
-gimple_statement_try *gimple_build_try (gimple_seq, gimple_seq,
+gbind *gimple_build_bind (tree, gimple_seq, tree);
+gasm *gimple_build_asm_vec (const char *, vec<tree, va_gc> *,
+ vec<tree, va_gc> *, vec<tree, va_gc> *,
+ vec<tree, va_gc> *);
+gcatch *gimple_build_catch (tree, gimple_seq);
+geh_filter *gimple_build_eh_filter (tree, gimple_seq);
+geh_mnt *gimple_build_eh_must_not_throw (tree);
+geh_else *gimple_build_eh_else (gimple_seq, gimple_seq);
+gtry *gimple_build_try (gimple_seq, gimple_seq,
enum gimple_try_flags);
gimple gimple_build_wce (gimple_seq);
-gimple gimple_build_resx (int);
-gimple gimple_build_switch_nlabels (unsigned, tree, tree);
-gimple gimple_build_switch (tree, tree, vec<tree> );
-gimple gimple_build_eh_dispatch (int);
-gimple gimple_build_debug_bind_stat (tree, tree, gimple MEM_STAT_DECL);
+gresx *gimple_build_resx (int);
+gswitch *gimple_build_switch_nlabels (unsigned, tree, tree);
+gswitch *gimple_build_switch (tree, tree, vec<tree> );
+geh_dispatch *gimple_build_eh_dispatch (int);
+gdebug *gimple_build_debug_bind_stat (tree, tree, gimple MEM_STAT_DECL);
#define gimple_build_debug_bind(var,val,stmt) \
gimple_build_debug_bind_stat ((var), (val), (stmt) MEM_STAT_INFO)
-gimple gimple_build_debug_source_bind_stat (tree, tree, gimple MEM_STAT_DECL);
+gdebug *gimple_build_debug_source_bind_stat (tree, tree, gimple MEM_STAT_DECL);
#define gimple_build_debug_source_bind(var,val,stmt) \
gimple_build_debug_source_bind_stat ((var), (val), (stmt) MEM_STAT_INFO)
-gimple gimple_build_omp_critical (gimple_seq, tree);
-gimple gimple_build_omp_for (gimple_seq, int, tree, size_t, gimple_seq);
-gimple gimple_build_omp_parallel (gimple_seq, tree, tree, tree);
-gimple gimple_build_omp_task (gimple_seq, tree, tree, tree, tree, tree, tree);
+gomp_critical *gimple_build_omp_critical (gimple_seq, tree);
+gomp_for *gimple_build_omp_for (gimple_seq, int, tree, size_t, gimple_seq);
+gomp_parallel *gimple_build_omp_parallel (gimple_seq, tree, tree, tree);
+gomp_task *gimple_build_omp_task (gimple_seq, tree, tree, tree, tree,
+ tree, tree);
gimple gimple_build_omp_section (gimple_seq);
gimple gimple_build_omp_master (gimple_seq);
gimple gimple_build_omp_taskgroup (gimple_seq);
-gimple gimple_build_omp_continue (tree, tree);
+gomp_continue *gimple_build_omp_continue (tree, tree);
gimple gimple_build_omp_ordered (gimple_seq);
gimple gimple_build_omp_return (bool);
-gimple gimple_build_omp_sections (gimple_seq, tree);
+gomp_sections *gimple_build_omp_sections (gimple_seq, tree);
gimple gimple_build_omp_sections_switch (void);
-gimple gimple_build_omp_single (gimple_seq, tree);
-gimple gimple_build_omp_target (gimple_seq, int, tree);
-gimple gimple_build_omp_teams (gimple_seq, tree);
-gimple gimple_build_omp_atomic_load (tree, tree);
-gimple gimple_build_omp_atomic_store (tree);
-gimple gimple_build_transaction (gimple_seq, tree);
+gomp_single *gimple_build_omp_single (gimple_seq, tree);
+gomp_target *gimple_build_omp_target (gimple_seq, int, tree);
+gomp_teams *gimple_build_omp_teams (gimple_seq, tree);
+gomp_atomic_load *gimple_build_omp_atomic_load (tree, tree);
+gomp_atomic_store *gimple_build_omp_atomic_store (tree);
+gtransaction *gimple_build_transaction (gimple_seq, tree);
gimple gimple_build_predict (enum br_predictor, enum prediction);
extern void gimple_seq_add_stmt (gimple_seq *, gimple);
extern void gimple_seq_add_stmt_without_update (gimple_seq *, gimple);
void gimple_seq_add_seq (gimple_seq *, gimple_seq);
+void gimple_seq_add_seq_without_update (gimple_seq *, gimple_seq);
extern void annotate_all_with_location_after (gimple_seq, gimple_stmt_iterator,
location_t);
extern void annotate_all_with_location (gimple_seq, location_t);
gimple_seq gimple_seq_copy (gimple_seq);
bool gimple_call_same_target_p (const_gimple, const_gimple);
int gimple_call_flags (const_gimple);
-int gimple_call_arg_flags (const_gimple, unsigned);
-int gimple_call_return_flags (const_gimple);
+int gimple_call_arg_flags (const gcall *, unsigned);
+int gimple_call_return_flags (const gcall *);
bool gimple_assign_copy_p (gimple);
bool gimple_assign_ssa_name_copy_p (gimple);
bool gimple_assign_unary_nop_p (gimple);
void gimple_set_bb (gimple, basic_block);
void gimple_assign_set_rhs_from_tree (gimple_stmt_iterator *, tree);
-void gimple_assign_set_rhs_with_ops_1 (gimple_stmt_iterator *, enum tree_code,
- tree, tree, tree);
+void gimple_assign_set_rhs_with_ops (gimple_stmt_iterator *, enum tree_code,
+ tree, tree, tree);
tree gimple_get_lhs (const_gimple);
void gimple_set_lhs (gimple, tree);
gimple gimple_copy (gimple);
extern void dump_gimple_statistics (void);
unsigned get_gimple_rhs_num_ops (enum tree_code);
extern tree canonicalize_cond_expr_cond (tree);
-gimple gimple_call_copy_skip_args (gimple, bitmap);
+gcall *gimple_call_copy_skip_args (gcall *, bitmap);
extern bool gimple_compare_field_offset (tree, tree);
extern tree gimple_unsigned_type (tree);
extern tree gimple_signed_type (tree);
extern bool gimple_call_builtin_p (const_gimple);
extern bool gimple_call_builtin_p (const_gimple, enum built_in_class);
extern bool gimple_call_builtin_p (const_gimple, enum built_in_function);
-extern bool gimple_asm_clobbers_memory_p (const_gimple);
+extern bool gimple_asm_clobbers_memory_p (const gasm *);
extern void dump_decl_set (FILE *, bitmap);
extern bool nonfreeing_call_p (gimple);
extern bool infer_nonnull_range (gimple, tree, bool, bool);
-extern void sort_case_labels (vec<tree> );
-extern void preprocess_case_label_vec_for_gimple (vec<tree> , tree, tree *);
-extern void gimple_seq_set_location (gimple_seq , location_t);
+extern void sort_case_labels (vec<tree>);
+extern void preprocess_case_label_vec_for_gimple (vec<tree>, tree, tree *);
+extern void gimple_seq_set_location (gimple_seq, location_t);
+extern void gimple_seq_discard (gimple_seq);
/* Formal (expression) temporary table handling: multiple occurrences of
the same scalar expression are evaluated into the same temporary. */
return n;
}
+/* Return the first statement in GIMPLE sequence S as a gbind *,
+ verifying that it has code GIMPLE_BIND in a checked build. */
+
+static inline gbind *
+gimple_seq_first_stmt_as_a_bind (gimple_seq s)
+{
+ gimple_seq_node n = gimple_seq_first (s);
+ return as_a <gbind *> (n);
+}
+
/* Return the last node in GIMPLE sequence S. */
return g->location;
}
+/* Return location information for statement G if g is not NULL.
+ Otherwise, UNKNOWN_LOCATION is returned. */
+
+static inline location_t
+gimple_location_safe (const_gimple g)
+{
+ return g ? gimple_location (g) : UNKNOWN_LOCATION;
+}
+
/* Return pointer to location information for statement G. */
static inline const location_t *
stmt->no_warning = (unsigned) no_warning;
}
-/* Set the visited status on statement STMT to VISITED_P. */
+/* Set the visited status on statement STMT to VISITED_P.
+
+ Please note that this 'visited' property of the gimple statement is
+ supposed to be undefined at pass boundaries. This means that a
+ given pass should not assume it contains any useful value when the
+ pass starts and thus can set it to any value it sees fit.
+
+ You can learn more about the visited property of the gimple
+ statement by reading the comments of the 'visited' data member of
+ struct gimple statement_base.
+ */
static inline void
gimple_set_visited (gimple stmt, bool visited_p)
}
-/* Return the visited status for statement STMT. */
+/* Return the visited status for statement STMT.
+
+ Please note that this 'visited' property of the gimple statement is
+ supposed to be undefined at pass boundaries. This means that a
+ given pass should not assume it contains any useful value when the
+ pass starts and thus can set it to any value it sees fit.
+
+ You can learn more about the visited property of the gimple
+ statement by reading the comments of the 'visited' data member of
+ struct gimple statement_base. */
static inline bool
gimple_visited_p (gimple stmt)
}
-/* Set pass local flag PLF on statement STMT to VAL_P. */
+/* Set pass local flag PLF on statement STMT to VAL_P.
+
+ Please note that this PLF property of the gimple statement is
+ supposed to be undefined at pass boundaries. This means that a
+ given pass should not assume it contains any useful value when the
+ pass starts and thus can set it to any value it sees fit.
+
+ You can learn more about the PLF property by reading the comment of
+ the 'plf' data member of struct gimple_statement_structure. */
static inline void
gimple_set_plf (gimple stmt, enum plf_mask plf, bool val_p)
}
-/* Return the value of pass local flag PLF on statement STMT. */
+/* Return the value of pass local flag PLF on statement STMT.
+
+ Please note that this 'plf' property of the gimple statement is
+ supposed to be undefined at pass boundaries. This means that a
+ given pass should not assume it contains any useful value when the
+ pass starts and thus can set it to any value it sees fit.
+
+ You can learn more about the plf property by reading the comment of
+ the 'plf' data member of struct gimple_statement_structure. */
static inline unsigned int
gimple_plf (gimple stmt, enum plf_mask plf)
}
-/* Set the UID of statement. */
+/* Set the UID of statement.
+
+ Please note that this UID property is supposed to be undefined at
+ pass boundaries. This means that a given pass should not assume it
+ contains any useful value when the pass starts and thus can set it
+ to any value it sees fit. */
static inline void
gimple_set_uid (gimple g, unsigned uid)
}
-/* Return the UID of statement. */
+/* Return the UID of statement.
+
+ Please note that this UID property is supposed to be undefined at
+ pass boundaries. This means that a given pass should not assume it
+ contains any useful value when the pass starts and thus can set it
+ to any value it sees fit. */
static inline unsigned
gimple_uid (const_gimple g)
gimple_set_op (gs, 3, rhs);
}
-/* A wrapper around gimple_assign_set_rhs_with_ops_1, for callers which expect
- to see only a maximum of two operands. */
+/* A wrapper around 3 operand gimple_assign_set_rhs_with_ops, for callers
+ which expect to see only two operands. */
static inline void
gimple_assign_set_rhs_with_ops (gimple_stmt_iterator *gsi, enum tree_code code,
tree op1, tree op2)
{
- gimple_assign_set_rhs_with_ops_1 (gsi, code, op1, op2, NULL);
+ gimple_assign_set_rhs_with_ops (gsi, code, op1, op2, NULL);
+}
+
+/* A wrapper around 3 operand gimple_assign_set_rhs_with_ops, for callers
+ which expect to see only one operands. */
+
+static inline void
+gimple_assign_set_rhs_with_ops (gimple_stmt_iterator *gsi, enum tree_code code,
+ tree op1)
+{
+ gimple_assign_set_rhs_with_ops (gsi, code, op1, NULL, NULL);
}
/* Returns true if GS is a nontemporal move. */
static inline bool
-gimple_assign_nontemporal_move_p (const_gimple gs)
+gimple_assign_nontemporal_move_p (const gassign *gs)
{
- GIMPLE_CHECK (gs, GIMPLE_ASSIGN);
return gs->nontemporal_move;
}
}
+/* Return true if call GS is marked as instrumented by
+ Pointer Bounds Checker. */
+
+static inline bool
+gimple_call_with_bounds_p (const_gimple gs)
+{
+ GIMPLE_CHECK (gs, GIMPLE_CALL);
+ return (gs->subcode & GF_CALL_WITH_BOUNDS) != 0;
+}
+
+
+/* If INSTRUMENTED_P is true, marm statement GS as instrumented by
+ Pointer Bounds Checker. */
+
+static inline void
+gimple_call_set_with_bounds (gimple gs, bool with_bounds)
+{
+ GIMPLE_CHECK (gs, GIMPLE_CALL);
+ if (with_bounds)
+ gs->subcode |= GF_CALL_WITH_BOUNDS;
+ else
+ gs->subcode &= ~GF_CALL_WITH_BOUNDS;
+}
+
+
/* Return the target of internal call GS. */
static inline enum internal_fn
gimple_call_internal_fn (const_gimple gs)
{
gcc_gimple_checking_assert (gimple_call_internal_p (gs));
- return static_cast <const gimple_statement_call *> (gs)->u.internal_fn;
+ return static_cast <const gcall *> (gs)->u.internal_fn;
+}
+
+/* If CTRL_ALTERING_P is true, mark GIMPLE_CALL S to be a stmt
+ that could alter control flow. */
+
+static inline void
+gimple_call_set_ctrl_altering (gimple s, bool ctrl_altering_p)
+{
+ GIMPLE_CHECK (s, GIMPLE_CALL);
+ if (ctrl_altering_p)
+ s->subcode |= GF_CALL_CTRL_ALTERING;
+ else
+ s->subcode &= ~GF_CALL_CTRL_ALTERING;
+}
+
+/* Return true if call GS calls an func whose GF_CALL_CTRL_ALTERING
+ flag is set. Such call could not be a stmt in the middle of a bb. */
+
+static inline bool
+gimple_call_ctrl_altering_p (const_gimple gs)
+{
+ GIMPLE_CHECK (gs, GIMPLE_CALL);
+ return (gs->subcode & GF_CALL_CTRL_ALTERING) != 0;
}
static inline tree
gimple_call_fntype (const_gimple gs)
{
- const gimple_statement_call *call_stmt =
- as_a <const gimple_statement_call *> (gs);
+ const gcall *call_stmt = as_a <const gcall *> (gs);
if (gimple_call_internal_p (gs))
return NULL_TREE;
return call_stmt->u.fntype;
}
-/* Set the type of the function called by GS to FNTYPE. */
+/* Set the type of the function called by CALL_STMT to FNTYPE. */
static inline void
-gimple_call_set_fntype (gimple gs, tree fntype)
+gimple_call_set_fntype (gcall *call_stmt, tree fntype)
{
- gimple_statement_call *call_stmt = as_a <gimple_statement_call *> (gs);
- gcc_gimple_checking_assert (!gimple_call_internal_p (gs));
+ gcc_gimple_checking_assert (!gimple_call_internal_p (call_stmt));
call_stmt->u.fntype = fntype;
}
/* Set FN to be the function called by call statement GS. */
static inline void
-gimple_call_set_fn (gimple gs, tree fn)
+gimple_call_set_fn (gcall *gs, tree fn)
{
- GIMPLE_CHECK (gs, GIMPLE_CALL);
gcc_gimple_checking_assert (!gimple_call_internal_p (gs));
gimple_set_op (gs, 1, fn);
}
}
-/* Set internal function FN to be the function called by call statement GS. */
+/* Set internal function FN to be the function called by call statement CALL_STMT. */
static inline void
-gimple_call_set_internal_fn (gimple gs, enum internal_fn fn)
+gimple_call_set_internal_fn (gcall *call_stmt, enum internal_fn fn)
{
- gimple_statement_call *call_stmt = as_a <gimple_statement_call *> (gs);
- gcc_gimple_checking_assert (gimple_call_internal_p (gs));
+ gcc_gimple_checking_assert (gimple_call_internal_p (call_stmt));
call_stmt->u.internal_fn = fn;
}
/* Return the type returned by call statement GS. */
static inline tree
-gimple_call_return_type (const_gimple gs)
+gimple_call_return_type (const gcall *gs)
{
tree type = gimple_call_fntype (gs);
}
-/* Return a pointer to the static chain for call statement GS. */
+/* Return a pointer to the static chain for call statement CALL_STMT. */
static inline tree *
-gimple_call_chain_ptr (const_gimple gs)
+gimple_call_chain_ptr (const gcall *call_stmt)
{
- GIMPLE_CHECK (gs, GIMPLE_CALL);
- return gimple_op_ptr (gs, 2);
+ return gimple_op_ptr (call_stmt, 2);
}
-/* Set CHAIN to be the static chain for call statement GS. */
+/* Set CHAIN to be the static chain for call statement CALL_STMT. */
static inline void
-gimple_call_set_chain (gimple gs, tree chain)
+gimple_call_set_chain (gcall *call_stmt, tree chain)
{
- GIMPLE_CHECK (gs, GIMPLE_CALL);
-
- gimple_set_op (gs, 2, chain);
+ gimple_set_op (call_stmt, 2, chain);
}
candidate for tail call optimization. */
static inline void
-gimple_call_set_tail (gimple s, bool tail_p)
+gimple_call_set_tail (gcall *s, bool tail_p)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
if (tail_p)
s->subcode |= GF_CALL_TAILCALL;
else
/* Return true if GIMPLE_CALL S is marked as a tail call. */
static inline bool
-gimple_call_tail_p (gimple s)
+gimple_call_tail_p (gcall *s)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
return (s->subcode & GF_CALL_TAILCALL) != 0;
}
expansion as the return slot for calls that return in memory. */
static inline void
-gimple_call_set_return_slot_opt (gimple s, bool return_slot_opt_p)
+gimple_call_set_return_slot_opt (gcall *s, bool return_slot_opt_p)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
if (return_slot_opt_p)
s->subcode |= GF_CALL_RETURN_SLOT_OPT;
else
/* Return true if S is marked for return slot optimization. */
static inline bool
-gimple_call_return_slot_opt_p (gimple s)
+gimple_call_return_slot_opt_p (gcall *s)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
return (s->subcode & GF_CALL_RETURN_SLOT_OPT) != 0;
}
thunk to the thunked-to function. */
static inline void
-gimple_call_set_from_thunk (gimple s, bool from_thunk_p)
+gimple_call_set_from_thunk (gcall *s, bool from_thunk_p)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
if (from_thunk_p)
s->subcode |= GF_CALL_FROM_THUNK;
else
/* Return true if GIMPLE_CALL S is a jump from a thunk. */
static inline bool
-gimple_call_from_thunk_p (gimple s)
+gimple_call_from_thunk_p (gcall *s)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
return (s->subcode & GF_CALL_FROM_THUNK) != 0;
}
argument pack in its argument list. */
static inline void
-gimple_call_set_va_arg_pack (gimple s, bool pass_arg_pack_p)
+gimple_call_set_va_arg_pack (gcall *s, bool pass_arg_pack_p)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
if (pass_arg_pack_p)
s->subcode |= GF_CALL_VA_ARG_PACK;
else
argument pack in its argument list. */
static inline bool
-gimple_call_va_arg_pack_p (gimple s)
+gimple_call_va_arg_pack_p (gcall *s)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
return (s->subcode & GF_CALL_VA_ARG_PACK) != 0;
}
even if the called function can throw in other cases. */
static inline void
-gimple_call_set_nothrow (gimple s, bool nothrow_p)
+gimple_call_set_nothrow (gcall *s, bool nothrow_p)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
if (nothrow_p)
s->subcode |= GF_CALL_NOTHROW;
else
/* Return true if S is a nothrow call. */
static inline bool
-gimple_call_nothrow_p (gimple s)
+gimple_call_nothrow_p (gcall *s)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
return (gimple_call_flags (s) & ECF_NOTHROW) != 0;
}
stack growth even when they occur in loops. */
static inline void
-gimple_call_set_alloca_for_var (gimple s, bool for_var)
+gimple_call_set_alloca_for_var (gcall *s, bool for_var)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
if (for_var)
s->subcode |= GF_CALL_ALLOCA_FOR_VAR;
else
/* Return true of S is a call to builtin_alloca emitted for VLA objects. */
static inline bool
-gimple_call_alloca_for_var_p (gimple s)
+gimple_call_alloca_for_var_p (gcall *s)
{
- GIMPLE_CHECK (s, GIMPLE_CALL);
return (s->subcode & GF_CALL_ALLOCA_FOR_VAR) != 0;
}
/* Copy all the GF_CALL_* flags from ORIG_CALL to DEST_CALL. */
static inline void
-gimple_call_copy_flags (gimple dest_call, gimple orig_call)
+gimple_call_copy_flags (gcall *dest_call, gcall *orig_call)
{
- GIMPLE_CHECK (dest_call, GIMPLE_CALL);
- GIMPLE_CHECK (orig_call, GIMPLE_CALL);
dest_call->subcode = orig_call->subcode;
}
/* Return a pointer to the points-to solution for the set of call-used
- variables of the call CALL. */
+ variables of the call CALL_STMT. */
static inline struct pt_solution *
-gimple_call_use_set (gimple call)
+gimple_call_use_set (gcall *call_stmt)
{
- gimple_statement_call *call_stmt = as_a <gimple_statement_call *> (call);
return &call_stmt->call_used;
}
/* Return a pointer to the points-to solution for the set of call-used
- variables of the call CALL. */
+ variables of the call CALL_STMT. */
static inline struct pt_solution *
-gimple_call_clobber_set (gimple call)
+gimple_call_clobber_set (gcall *call_stmt)
{
- gimple_statement_call *call_stmt = as_a <gimple_statement_call *> (call);
return &call_stmt->call_clobbered;
}
/* Set CODE to be the predicate code for the conditional statement GS. */
static inline void
-gimple_cond_set_code (gimple gs, enum tree_code code)
+gimple_cond_set_code (gcond *gs, enum tree_code code)
{
- GIMPLE_CHECK (gs, GIMPLE_COND);
gs->subcode = code;
}
statement GS. */
static inline tree *
-gimple_cond_lhs_ptr (const_gimple gs)
+gimple_cond_lhs_ptr (const gcond *gs)
{
- GIMPLE_CHECK (gs, GIMPLE_COND);
return gimple_op_ptr (gs, 0);
}
conditional statement GS. */
static inline void
-gimple_cond_set_lhs (gimple gs, tree lhs)
+gimple_cond_set_lhs (gcond *gs, tree lhs)
{
- GIMPLE_CHECK (gs, GIMPLE_COND);
gimple_set_op (gs, 0, lhs);
}
conditional GS. */
static inline tree *
-gimple_cond_rhs_ptr (const_gimple gs)
+gimple_cond_rhs_ptr (const gcond *gs)
{
- GIMPLE_CHECK (gs, GIMPLE_COND);
return gimple_op_ptr (gs, 1);
}
conditional statement GS. */
static inline void
-gimple_cond_set_rhs (gimple gs, tree rhs)
+gimple_cond_set_rhs (gcond *gs, tree rhs)
{
- GIMPLE_CHECK (gs, GIMPLE_COND);
gimple_set_op (gs, 1, rhs);
}
predicate evaluates to true. */
static inline tree
-gimple_cond_true_label (const_gimple gs)
+gimple_cond_true_label (const gcond *gs)
{
- GIMPLE_CHECK (gs, GIMPLE_COND);
return gimple_op (gs, 2);
}
predicate evaluates to true. */
static inline void
-gimple_cond_set_true_label (gimple gs, tree label)
+gimple_cond_set_true_label (gcond *gs, tree label)
{
- GIMPLE_CHECK (gs, GIMPLE_COND);
gimple_set_op (gs, 2, label);
}
predicate evaluates to false. */
static inline void
-gimple_cond_set_false_label (gimple gs, tree label)
+gimple_cond_set_false_label (gcond *gs, tree label)
{
- GIMPLE_CHECK (gs, GIMPLE_COND);
gimple_set_op (gs, 3, label);
}
predicate evaluates to false. */
static inline tree
-gimple_cond_false_label (const_gimple gs)
+gimple_cond_false_label (const gcond *gs)
{
- GIMPLE_CHECK (gs, GIMPLE_COND);
+
return gimple_op (gs, 3);
}
/* Set the conditional COND_STMT to be of the form 'if (1 == 0)'. */
static inline void
-gimple_cond_make_false (gimple gs)
+gimple_cond_make_false (gcond *gs)
{
gimple_cond_set_lhs (gs, boolean_true_node);
gimple_cond_set_rhs (gs, boolean_false_node);
/* Set the conditional COND_STMT to be of the form 'if (1 == 1)'. */
static inline void
-gimple_cond_make_true (gimple gs)
+gimple_cond_make_true (gcond *gs)
{
gimple_cond_set_lhs (gs, boolean_true_node);
gimple_cond_set_rhs (gs, boolean_true_node);
'if (0 == 0)', 'if (1 != 0)' or 'if (0 != 1)' */
static inline bool
-gimple_cond_true_p (const_gimple gs)
+gimple_cond_true_p (const gcond *gs)
{
tree lhs = gimple_cond_lhs (gs);
tree rhs = gimple_cond_rhs (gs);
'if (0 != 0)', 'if (1 == 0)' or 'if (0 == 1)' */
static inline bool
-gimple_cond_false_p (const_gimple gs)
+gimple_cond_false_p (const gcond *gs)
{
tree lhs = gimple_cond_lhs (gs);
tree rhs = gimple_cond_rhs (gs);
/* Set the code, LHS and RHS of GIMPLE_COND STMT from CODE, LHS and RHS. */
static inline void
-gimple_cond_set_condition (gimple stmt, enum tree_code code, tree lhs, tree rhs)
+gimple_cond_set_condition (gcond *stmt, enum tree_code code, tree lhs,
+ tree rhs)
{
gimple_cond_set_code (stmt, code);
gimple_cond_set_lhs (stmt, lhs);
/* Return the LABEL_DECL node used by GIMPLE_LABEL statement GS. */
static inline tree
-gimple_label_label (const_gimple gs)
+gimple_label_label (const glabel *gs)
{
- GIMPLE_CHECK (gs, GIMPLE_LABEL);
return gimple_op (gs, 0);
}
GS. */
static inline void
-gimple_label_set_label (gimple gs, tree label)
+gimple_label_set_label (glabel *gs, tree label)
{
- GIMPLE_CHECK (gs, GIMPLE_LABEL);
gimple_set_op (gs, 0, label);
}
/* Set DEST to be the destination of the unconditonal jump GS. */
static inline void
-gimple_goto_set_dest (gimple gs, tree dest)
+gimple_goto_set_dest (ggoto *gs, tree dest)
{
- GIMPLE_CHECK (gs, GIMPLE_GOTO);
gimple_set_op (gs, 0, dest);
}
/* Return the variables declared in the GIMPLE_BIND statement GS. */
static inline tree
-gimple_bind_vars (const_gimple gs)
+gimple_bind_vars (const gbind *bind_stmt)
{
- const gimple_statement_bind *bind_stmt =
- as_a <const gimple_statement_bind *> (gs);
return bind_stmt->vars;
}
statement GS. */
static inline void
-gimple_bind_set_vars (gimple gs, tree vars)
+gimple_bind_set_vars (gbind *bind_stmt, tree vars)
{
- gimple_statement_bind *bind_stmt = as_a <gimple_statement_bind *> (gs);
bind_stmt->vars = vars;
}
statement GS. */
static inline void
-gimple_bind_append_vars (gimple gs, tree vars)
+gimple_bind_append_vars (gbind *bind_stmt, tree vars)
{
- gimple_statement_bind *bind_stmt = as_a <gimple_statement_bind *> (gs);
bind_stmt->vars = chainon (bind_stmt->vars, vars);
}
static inline gimple_seq *
-gimple_bind_body_ptr (gimple gs)
+gimple_bind_body_ptr (gbind *bind_stmt)
{
- gimple_statement_bind *bind_stmt = as_a <gimple_statement_bind *> (gs);
return &bind_stmt->body;
}
/* Return the GIMPLE sequence contained in the GIMPLE_BIND statement GS. */
static inline gimple_seq
-gimple_bind_body (gimple gs)
+gimple_bind_body (gbind *gs)
{
return *gimple_bind_body_ptr (gs);
}
statement GS. */
static inline void
-gimple_bind_set_body (gimple gs, gimple_seq seq)
+gimple_bind_set_body (gbind *bind_stmt, gimple_seq seq)
{
- gimple_statement_bind *bind_stmt = as_a <gimple_statement_bind *> (gs);
bind_stmt->body = seq;
}
/* Append a statement to the end of a GIMPLE_BIND's body. */
static inline void
-gimple_bind_add_stmt (gimple gs, gimple stmt)
+gimple_bind_add_stmt (gbind *bind_stmt, gimple stmt)
{
- gimple_statement_bind *bind_stmt = as_a <gimple_statement_bind *> (gs);
gimple_seq_add_stmt (&bind_stmt->body, stmt);
}
/* Append a sequence of statements to the end of a GIMPLE_BIND's body. */
static inline void
-gimple_bind_add_seq (gimple gs, gimple_seq seq)
+gimple_bind_add_seq (gbind *bind_stmt, gimple_seq seq)
{
- gimple_statement_bind *bind_stmt = as_a <gimple_statement_bind *> (gs);
gimple_seq_add_seq (&bind_stmt->body, seq);
}
GS. This is analogous to the BIND_EXPR_BLOCK field in trees. */
static inline tree
-gimple_bind_block (const_gimple gs)
+gimple_bind_block (const gbind *bind_stmt)
{
- const gimple_statement_bind *bind_stmt =
- as_a <const gimple_statement_bind *> (gs);
return bind_stmt->block;
}
statement GS. */
static inline void
-gimple_bind_set_block (gimple gs, tree block)
+gimple_bind_set_block (gbind *bind_stmt, tree block)
{
- gimple_statement_bind *bind_stmt = as_a <gimple_statement_bind *> (gs);
gcc_gimple_checking_assert (block == NULL_TREE
|| TREE_CODE (block) == BLOCK);
bind_stmt->block = block;
}
-/* Return the number of input operands for GIMPLE_ASM GS. */
+/* Return the number of input operands for GIMPLE_ASM ASM_STMT. */
static inline unsigned
-gimple_asm_ninputs (const_gimple gs)
+gimple_asm_ninputs (const gasm *asm_stmt)
{
- const gimple_statement_asm *asm_stmt =
- as_a <const gimple_statement_asm *> (gs);
return asm_stmt->ni;
}
-/* Return the number of output operands for GIMPLE_ASM GS. */
+/* Return the number of output operands for GIMPLE_ASM ASM_STMT. */
static inline unsigned
-gimple_asm_noutputs (const_gimple gs)
+gimple_asm_noutputs (const gasm *asm_stmt)
{
- const gimple_statement_asm *asm_stmt =
- as_a <const gimple_statement_asm *> (gs);
return asm_stmt->no;
}
-/* Return the number of clobber operands for GIMPLE_ASM GS. */
+/* Return the number of clobber operands for GIMPLE_ASM ASM_STMT. */
static inline unsigned
-gimple_asm_nclobbers (const_gimple gs)
+gimple_asm_nclobbers (const gasm *asm_stmt)
{
- const gimple_statement_asm *asm_stmt =
- as_a <const gimple_statement_asm *> (gs);
return asm_stmt->nc;
}
-/* Return the number of label operands for GIMPLE_ASM GS. */
+/* Return the number of label operands for GIMPLE_ASM ASM_STMT. */
static inline unsigned
-gimple_asm_nlabels (const_gimple gs)
+gimple_asm_nlabels (const gasm *asm_stmt)
{
- const gimple_statement_asm *asm_stmt =
- as_a <const gimple_statement_asm *> (gs);
return asm_stmt->nl;
}
-/* Return input operand INDEX of GIMPLE_ASM GS. */
+/* Return input operand INDEX of GIMPLE_ASM ASM_STMT. */
static inline tree
-gimple_asm_input_op (const_gimple gs, unsigned index)
+gimple_asm_input_op (const gasm *asm_stmt, unsigned index)
{
- const gimple_statement_asm *asm_stmt =
- as_a <const gimple_statement_asm *> (gs);
gcc_gimple_checking_assert (index < asm_stmt->ni);
- return gimple_op (gs, index + asm_stmt->no);
+ return gimple_op (asm_stmt, index + asm_stmt->no);
}
-/* Return a pointer to input operand INDEX of GIMPLE_ASM GS. */
+/* Return a pointer to input operand INDEX of GIMPLE_ASM ASM_STMT. */
static inline tree *
-gimple_asm_input_op_ptr (const_gimple gs, unsigned index)
+gimple_asm_input_op_ptr (const gasm *asm_stmt, unsigned index)
{
- const gimple_statement_asm *asm_stmt =
- as_a <const gimple_statement_asm *> (gs);
gcc_gimple_checking_assert (index < asm_stmt->ni);
- return gimple_op_ptr (gs, index + asm_stmt->no);
+ return gimple_op_ptr (asm_stmt, index + asm_stmt->no);
}
-/* Set IN_OP to be input operand INDEX in GIMPLE_ASM GS. */
+/* Set IN_OP to be input operand INDEX in GIMPLE_ASM ASM_STMT. */
static inline void
-gimple_asm_set_input_op (gimple gs, unsigned index, tree in_op)
+gimple_asm_set_input_op (gasm *asm_stmt, unsigned index, tree in_op)
{
- gimple_statement_asm *asm_stmt = as_a <gimple_statement_asm *> (gs);
gcc_gimple_checking_assert (index < asm_stmt->ni
&& TREE_CODE (in_op) == TREE_LIST);
- gimple_set_op (gs, index + asm_stmt->no, in_op);
+ gimple_set_op (asm_stmt, index + asm_stmt->no, in_op);
}
-/* Return output operand INDEX of GIMPLE_ASM GS. */
+/* Return output operand INDEX of GIMPLE_ASM ASM_STMT. */
static inline tree
-gimple_asm_output_op (const_gimple gs, unsigned index)
+gimple_asm_output_op (const gasm *asm_stmt, unsigned index)
{
- const gimple_statement_asm *asm_stmt =
- as_a <const gimple_statement_asm *> (gs);
gcc_gimple_checking_assert (index < asm_stmt->no);
- return gimple_op (gs, index);
+ return gimple_op (asm_stmt, index);
}
-/* Return a pointer to output operand INDEX of GIMPLE_ASM GS. */
+/* Return a pointer to output operand INDEX of GIMPLE_ASM ASM_STMT. */
static inline tree *
-gimple_asm_output_op_ptr (const_gimple gs, unsigned index)
+gimple_asm_output_op_ptr (const gasm *asm_stmt, unsigned index)
{
- const gimple_statement_asm *asm_stmt =
- as_a <const gimple_statement_asm *> (gs);
gcc_gimple_checking_assert (index < asm_stmt->no);
- return gimple_op_ptr (gs, index);
+ return gimple_op_ptr (asm_stmt, index);
}
-/* Set OUT_OP to be output operand INDEX in GIMPLE_ASM GS. */
+/* Set OUT_OP to be output operand INDEX in GIMPLE_ASM ASM_STMT. */
static inline void
-gimple_asm_set_output_op (gimple gs, unsigned index, tree out_op)
+gimple_asm_set_output_op (gasm *asm_stmt, unsigned index, tree out_op)
{
- gimple_statement_asm *asm_stmt = as_a <gimple_statement_asm *> (gs);
gcc_gimple_checking_assert (index < asm_stmt->no
&& TREE_CODE (out_op) == TREE_LIST);
- gimple_set_op (gs, index, out_op);
+ gimple_set_op (asm_stmt, index, out_op);
}
-/* Return clobber operand INDEX of GIMPLE_ASM GS. */
+/* Return clobber operand INDEX of GIMPLE_ASM ASM_STMT. */
static inline tree
-gimple_asm_clobber_op (const_gimple gs, unsigned index)
+gimple_asm_clobber_op (const gasm *asm_stmt, unsigned index)
{
- const gimple_statement_asm *asm_stmt =
- as_a <const gimple_statement_asm *> (gs);
gcc_gimple_checking_assert (index < asm_stmt->nc);
- return gimple_op (gs, index + asm_stmt->ni + asm_stmt->no);
+ return gimple_op (asm_stmt, index + asm_stmt->ni + asm_stmt->no);
}
-/* Set CLOBBER_OP to be clobber operand INDEX in GIMPLE_ASM GS. */
+/* Set CLOBBER_OP to be clobber operand INDEX in GIMPLE_ASM ASM_STMT. */
static inline void
-gimple_asm_set_clobber_op (gimple gs, unsigned index, tree clobber_op)
+gimple_asm_set_clobber_op (gasm *asm_stmt, unsigned index, tree clobber_op)
{
- gimple_statement_asm *asm_stmt = as_a <gimple_statement_asm *> (gs);
gcc_gimple_checking_assert (index < asm_stmt->nc
&& TREE_CODE (clobber_op) == TREE_LIST);
- gimple_set_op (gs, index + asm_stmt->ni + asm_stmt->no, clobber_op);
+ gimple_set_op (asm_stmt, index + asm_stmt->ni + asm_stmt->no, clobber_op);
}
-/* Return label operand INDEX of GIMPLE_ASM GS. */
+/* Return label operand INDEX of GIMPLE_ASM ASM_STMT. */
static inline tree
-gimple_asm_label_op (const_gimple gs, unsigned index)
+gimple_asm_label_op (const gasm *asm_stmt, unsigned index)
{
- const gimple_statement_asm *asm_stmt =
- as_a <const gimple_statement_asm *> (gs);
gcc_gimple_checking_assert (index < asm_stmt->nl);
- return gimple_op (gs, index + asm_stmt->ni + asm_stmt->nc);
+ return gimple_op (asm_stmt, index + asm_stmt->ni + asm_stmt->nc);
}
-/* Set LABEL_OP to be label operand INDEX in GIMPLE_ASM GS. */
+/* Set LABEL_OP to be label operand INDEX in GIMPLE_ASM ASM_STMT. */
static inline void
-gimple_asm_set_label_op (gimple gs, unsigned index, tree label_op)
+gimple_asm_set_label_op (gasm *asm_stmt, unsigned index, tree label_op)
{
- gimple_statement_asm *asm_stmt = as_a <gimple_statement_asm *> (gs);
gcc_gimple_checking_assert (index < asm_stmt->nl
&& TREE_CODE (label_op) == TREE_LIST);
- gimple_set_op (gs, index + asm_stmt->ni + asm_stmt->nc, label_op);
+ gimple_set_op (asm_stmt, index + asm_stmt->ni + asm_stmt->nc, label_op);
}
/* Return the string representing the assembly instruction in
- GIMPLE_ASM GS. */
+ GIMPLE_ASM ASM_STMT. */
static inline const char *
-gimple_asm_string (const_gimple gs)
+gimple_asm_string (const gasm *asm_stmt)
{
- const gimple_statement_asm *asm_stmt =
- as_a <const gimple_statement_asm *> (gs);
return asm_stmt->string;
}
-/* Return true if GS is an asm statement marked volatile. */
+/* Return true ASM_STMT ASM_STMT is an asm statement marked volatile. */
static inline bool
-gimple_asm_volatile_p (const_gimple gs)
+gimple_asm_volatile_p (const gasm *asm_stmt)
{
- GIMPLE_CHECK (gs, GIMPLE_ASM);
- return (gs->subcode & GF_ASM_VOLATILE) != 0;
+ return (asm_stmt->subcode & GF_ASM_VOLATILE) != 0;
}
-/* If VOLATLE_P is true, mark asm statement GS as volatile. */
+/* If VOLATLE_P is true, mark asm statement ASM_STMT as volatile. */
static inline void
-gimple_asm_set_volatile (gimple gs, bool volatile_p)
+gimple_asm_set_volatile (gasm *asm_stmt, bool volatile_p)
{
- GIMPLE_CHECK (gs, GIMPLE_ASM);
if (volatile_p)
- gs->subcode |= GF_ASM_VOLATILE;
+ asm_stmt->subcode |= GF_ASM_VOLATILE;
else
- gs->subcode &= ~GF_ASM_VOLATILE;
+ asm_stmt->subcode &= ~GF_ASM_VOLATILE;
}
-/* If INPUT_P is true, mark asm GS as an ASM_INPUT. */
+/* If INPUT_P is true, mark asm ASM_STMT as an ASM_INPUT. */
static inline void
-gimple_asm_set_input (gimple gs, bool input_p)
+gimple_asm_set_input (gasm *asm_stmt, bool input_p)
{
- GIMPLE_CHECK (gs, GIMPLE_ASM);
if (input_p)
- gs->subcode |= GF_ASM_INPUT;
+ asm_stmt->subcode |= GF_ASM_INPUT;
else
- gs->subcode &= ~GF_ASM_INPUT;
+ asm_stmt->subcode &= ~GF_ASM_INPUT;
}
-/* Return true if asm GS is an ASM_INPUT. */
+/* Return true if asm ASM_STMT is an ASM_INPUT. */
static inline bool
-gimple_asm_input_p (const_gimple gs)
+gimple_asm_input_p (const gasm *asm_stmt)
{
- GIMPLE_CHECK (gs, GIMPLE_ASM);
- return (gs->subcode & GF_ASM_INPUT) != 0;
+ return (asm_stmt->subcode & GF_ASM_INPUT) != 0;
}
-/* Return the types handled by GIMPLE_CATCH statement GS. */
+/* Return the types handled by GIMPLE_CATCH statement CATCH_STMT. */
static inline tree
-gimple_catch_types (const_gimple gs)
+gimple_catch_types (const gcatch *catch_stmt)
{
- const gimple_statement_catch *catch_stmt =
- as_a <const gimple_statement_catch *> (gs);
return catch_stmt->types;
}
-/* Return a pointer to the types handled by GIMPLE_CATCH statement GS. */
+/* Return a pointer to the types handled by GIMPLE_CATCH statement CATCH_STMT. */
static inline tree *
-gimple_catch_types_ptr (gimple gs)
+gimple_catch_types_ptr (gcatch *catch_stmt)
{
- gimple_statement_catch *catch_stmt = as_a <gimple_statement_catch *> (gs);
return &catch_stmt->types;
}
/* Return a pointer to the GIMPLE sequence representing the body of
- the handler of GIMPLE_CATCH statement GS. */
+ the handler of GIMPLE_CATCH statement CATCH_STMT. */
static inline gimple_seq *
-gimple_catch_handler_ptr (gimple gs)
+gimple_catch_handler_ptr (gcatch *catch_stmt)
{
- gimple_statement_catch *catch_stmt = as_a <gimple_statement_catch *> (gs);
return &catch_stmt->handler;
}
/* Return the GIMPLE sequence representing the body of the handler of
- GIMPLE_CATCH statement GS. */
+ GIMPLE_CATCH statement CATCH_STMT. */
static inline gimple_seq
-gimple_catch_handler (gimple gs)
+gimple_catch_handler (gcatch *catch_stmt)
{
- return *gimple_catch_handler_ptr (gs);
+ return *gimple_catch_handler_ptr (catch_stmt);
}
-/* Set T to be the set of types handled by GIMPLE_CATCH GS. */
+/* Set T to be the set of types handled by GIMPLE_CATCH CATCH_STMT. */
static inline void
-gimple_catch_set_types (gimple gs, tree t)
+gimple_catch_set_types (gcatch *catch_stmt, tree t)
{
- gimple_statement_catch *catch_stmt = as_a <gimple_statement_catch *> (gs);
catch_stmt->types = t;
}
-/* Set HANDLER to be the body of GIMPLE_CATCH GS. */
+/* Set HANDLER to be the body of GIMPLE_CATCH CATCH_STMT. */
static inline void
-gimple_catch_set_handler (gimple gs, gimple_seq handler)
+gimple_catch_set_handler (gcatch *catch_stmt, gimple_seq handler)
{
- gimple_statement_catch *catch_stmt = as_a <gimple_statement_catch *> (gs);
catch_stmt->handler = handler;
}
static inline tree
gimple_eh_filter_types (const_gimple gs)
{
- const gimple_statement_eh_filter *eh_filter_stmt =
- as_a <const gimple_statement_eh_filter *> (gs);
+ const geh_filter *eh_filter_stmt = as_a <const geh_filter *> (gs);
return eh_filter_stmt->types;
}
static inline tree *
gimple_eh_filter_types_ptr (gimple gs)
{
- gimple_statement_eh_filter *eh_filter_stmt =
- as_a <gimple_statement_eh_filter *> (gs);
+ geh_filter *eh_filter_stmt = as_a <geh_filter *> (gs);
return &eh_filter_stmt->types;
}
static inline gimple_seq *
gimple_eh_filter_failure_ptr (gimple gs)
{
- gimple_statement_eh_filter *eh_filter_stmt =
- as_a <gimple_statement_eh_filter *> (gs);
+ geh_filter *eh_filter_stmt = as_a <geh_filter *> (gs);
return &eh_filter_stmt->failure;
}
}
-/* Set TYPES to be the set of types handled by GIMPLE_EH_FILTER GS. */
+/* Set TYPES to be the set of types handled by GIMPLE_EH_FILTER
+ EH_FILTER_STMT. */
static inline void
-gimple_eh_filter_set_types (gimple gs, tree types)
+gimple_eh_filter_set_types (geh_filter *eh_filter_stmt, tree types)
{
- gimple_statement_eh_filter *eh_filter_stmt =
- as_a <gimple_statement_eh_filter *> (gs);
eh_filter_stmt->types = types;
}
/* Set FAILURE to be the sequence of statements to execute on failure
- for GIMPLE_EH_FILTER GS. */
+ for GIMPLE_EH_FILTER EH_FILTER_STMT. */
static inline void
-gimple_eh_filter_set_failure (gimple gs, gimple_seq failure)
+gimple_eh_filter_set_failure (geh_filter *eh_filter_stmt,
+ gimple_seq failure)
{
- gimple_statement_eh_filter *eh_filter_stmt =
- as_a <gimple_statement_eh_filter *> (gs);
eh_filter_stmt->failure = failure;
}
/* Get the function decl to be called by the MUST_NOT_THROW region. */
static inline tree
-gimple_eh_must_not_throw_fndecl (gimple gs)
+gimple_eh_must_not_throw_fndecl (geh_mnt *eh_mnt_stmt)
{
- gimple_statement_eh_mnt *eh_mnt_stmt = as_a <gimple_statement_eh_mnt *> (gs);
return eh_mnt_stmt->fndecl;
}
/* Set the function decl to be called by GS to DECL. */
static inline void
-gimple_eh_must_not_throw_set_fndecl (gimple gs, tree decl)
+gimple_eh_must_not_throw_set_fndecl (geh_mnt *eh_mnt_stmt,
+ tree decl)
{
- gimple_statement_eh_mnt *eh_mnt_stmt = as_a <gimple_statement_eh_mnt *> (gs);
eh_mnt_stmt->fndecl = decl;
}
/* GIMPLE_EH_ELSE accessors. */
static inline gimple_seq *
-gimple_eh_else_n_body_ptr (gimple gs)
+gimple_eh_else_n_body_ptr (geh_else *eh_else_stmt)
{
- gimple_statement_eh_else *eh_else_stmt =
- as_a <gimple_statement_eh_else *> (gs);
return &eh_else_stmt->n_body;
}
static inline gimple_seq
-gimple_eh_else_n_body (gimple gs)
+gimple_eh_else_n_body (geh_else *eh_else_stmt)
{
- return *gimple_eh_else_n_body_ptr (gs);
+ return *gimple_eh_else_n_body_ptr (eh_else_stmt);
}
static inline gimple_seq *
-gimple_eh_else_e_body_ptr (gimple gs)
+gimple_eh_else_e_body_ptr (geh_else *eh_else_stmt)
{
- gimple_statement_eh_else *eh_else_stmt =
- as_a <gimple_statement_eh_else *> (gs);
return &eh_else_stmt->e_body;
}
static inline gimple_seq
-gimple_eh_else_e_body (gimple gs)
+gimple_eh_else_e_body (geh_else *eh_else_stmt)
{
- return *gimple_eh_else_e_body_ptr (gs);
+ return *gimple_eh_else_e_body_ptr (eh_else_stmt);
}
static inline void
-gimple_eh_else_set_n_body (gimple gs, gimple_seq seq)
+gimple_eh_else_set_n_body (geh_else *eh_else_stmt, gimple_seq seq)
{
- gimple_statement_eh_else *eh_else_stmt =
- as_a <gimple_statement_eh_else *> (gs);
eh_else_stmt->n_body = seq;
}
static inline void
-gimple_eh_else_set_e_body (gimple gs, gimple_seq seq)
+gimple_eh_else_set_e_body (geh_else *eh_else_stmt, gimple_seq seq)
{
- gimple_statement_eh_else *eh_else_stmt =
- as_a <gimple_statement_eh_else *> (gs);
eh_else_stmt->e_body = seq;
}
/* Set the kind of try block represented by GIMPLE_TRY GS. */
static inline void
-gimple_try_set_kind (gimple gs, enum gimple_try_flags kind)
+gimple_try_set_kind (gtry *gs, enum gimple_try_flags kind)
{
- GIMPLE_CHECK (gs, GIMPLE_TRY);
gcc_gimple_checking_assert (kind == GIMPLE_TRY_CATCH
|| kind == GIMPLE_TRY_FINALLY);
if (gimple_try_kind (gs) != kind)
static inline gimple_seq *
gimple_try_eval_ptr (gimple gs)
{
- gimple_statement_try *try_stmt = as_a <gimple_statement_try *> (gs);
+ gtry *try_stmt = as_a <gtry *> (gs);
return &try_stmt->eval;
}
static inline gimple_seq *
gimple_try_cleanup_ptr (gimple gs)
{
- gimple_statement_try *try_stmt = as_a <gimple_statement_try *> (gs);
+ gtry *try_stmt = as_a <gtry *> (gs);
return &try_stmt->cleanup;
}
/* Set the GIMPLE_TRY_CATCH_IS_CLEANUP flag. */
static inline void
-gimple_try_set_catch_is_cleanup (gimple g, bool catch_is_cleanup)
+gimple_try_set_catch_is_cleanup (gtry *g, bool catch_is_cleanup)
{
gcc_gimple_checking_assert (gimple_try_kind (g) == GIMPLE_TRY_CATCH);
if (catch_is_cleanup)
/* Set EVAL to be the sequence of statements to use as the body for
- GIMPLE_TRY GS. */
+ GIMPLE_TRY TRY_STMT. */
static inline void
-gimple_try_set_eval (gimple gs, gimple_seq eval)
+gimple_try_set_eval (gtry *try_stmt, gimple_seq eval)
{
- gimple_statement_try *try_stmt = as_a <gimple_statement_try *> (gs);
try_stmt->eval = eval;
}
/* Set CLEANUP to be the sequence of statements to use as the cleanup
- body for GIMPLE_TRY GS. */
+ body for GIMPLE_TRY TRY_STMT. */
static inline void
-gimple_try_set_cleanup (gimple gs, gimple_seq cleanup)
+gimple_try_set_cleanup (gtry *try_stmt, gimple_seq cleanup)
{
- gimple_statement_try *try_stmt = as_a <gimple_statement_try *> (gs);
try_stmt->cleanup = cleanup;
}
static inline unsigned
gimple_phi_capacity (const_gimple gs)
{
- const gimple_statement_phi *phi_stmt =
- as_a <const gimple_statement_phi *> (gs);
+ const gphi *phi_stmt = as_a <const gphi *> (gs);
return phi_stmt->capacity;
}
static inline unsigned
gimple_phi_num_args (const_gimple gs)
{
- const gimple_statement_phi *phi_stmt =
- as_a <const gimple_statement_phi *> (gs);
+ const gphi *phi_stmt = as_a <const gphi *> (gs);
return phi_stmt->nargs;
}
static inline tree
gimple_phi_result (const_gimple gs)
{
- const gimple_statement_phi *phi_stmt =
- as_a <const gimple_statement_phi *> (gs);
+ const gphi *phi_stmt = as_a <const gphi *> (gs);
return phi_stmt->result;
}
static inline tree *
gimple_phi_result_ptr (gimple gs)
{
- gimple_statement_phi *phi_stmt = as_a <gimple_statement_phi *> (gs);
+ gphi *phi_stmt = as_a <gphi *> (gs);
return &phi_stmt->result;
}
-/* Set RESULT to be the SSA name created by GIMPLE_PHI GS. */
+/* Set RESULT to be the SSA name created by GIMPLE_PHI PHI. */
static inline void
-gimple_phi_set_result (gimple gs, tree result)
+gimple_phi_set_result (gphi *phi, tree result)
{
- gimple_statement_phi *phi_stmt = as_a <gimple_statement_phi *> (gs);
- phi_stmt->result = result;
+ phi->result = result;
if (result && TREE_CODE (result) == SSA_NAME)
- SSA_NAME_DEF_STMT (result) = gs;
+ SSA_NAME_DEF_STMT (result) = phi;
}
static inline struct phi_arg_d *
gimple_phi_arg (gimple gs, unsigned index)
{
- gimple_statement_phi *phi_stmt = as_a <gimple_statement_phi *> (gs);
+ gphi *phi_stmt = as_a <gphi *> (gs);
gcc_gimple_checking_assert (index <= phi_stmt->capacity);
return &(phi_stmt->args[index]);
}
/* Set PHIARG to be the argument corresponding to incoming edge INDEX
- for GIMPLE_PHI GS. */
+ for GIMPLE_PHI PHI. */
static inline void
-gimple_phi_set_arg (gimple gs, unsigned index, struct phi_arg_d * phiarg)
+gimple_phi_set_arg (gphi *phi, unsigned index, struct phi_arg_d * phiarg)
{
- gimple_statement_phi *phi_stmt = as_a <gimple_statement_phi *> (gs);
- gcc_gimple_checking_assert (index <= phi_stmt->nargs);
- phi_stmt->args[index] = *phiarg;
+ gcc_gimple_checking_assert (index <= phi->nargs);
+ phi->args[index] = *phiarg;
}
/* Return the PHI nodes for basic block BB, or NULL if there are no
}
-/* Return a pointer to the tree operand for argument I of PHI node GS. */
+/* Return a pointer to the tree operand for argument I of phi node PHI. */
static inline tree *
-gimple_phi_arg_def_ptr (gimple gs, size_t index)
+gimple_phi_arg_def_ptr (gphi *phi, size_t index)
{
- return &gimple_phi_arg (gs, index)->def;
+ return &gimple_phi_arg (phi, index)->def;
}
-/* Return the edge associated with argument I of phi node GS. */
+/* Return the edge associated with argument I of phi node PHI. */
static inline edge
-gimple_phi_arg_edge (gimple gs, size_t i)
+gimple_phi_arg_edge (gphi *phi, size_t i)
{
- return EDGE_PRED (gimple_bb (gs), i);
+ return EDGE_PRED (gimple_bb (phi), i);
}
-/* Return the source location of gimple argument I of phi node GS. */
+/* Return the source location of gimple argument I of phi node PHI. */
static inline source_location
-gimple_phi_arg_location (gimple gs, size_t i)
+gimple_phi_arg_location (gphi *phi, size_t i)
{
- return gimple_phi_arg (gs, i)->locus;
+ return gimple_phi_arg (phi, i)->locus;
}
-/* Return the source location of the argument on edge E of phi node GS. */
+/* Return the source location of the argument on edge E of phi node PHI. */
static inline source_location
-gimple_phi_arg_location_from_edge (gimple gs, edge e)
+gimple_phi_arg_location_from_edge (gphi *phi, edge e)
{
- return gimple_phi_arg (gs, e->dest_idx)->locus;
+ return gimple_phi_arg (phi, e->dest_idx)->locus;
}
-/* Set the source location of gimple argument I of phi node GS to LOC. */
+/* Set the source location of gimple argument I of phi node PHI to LOC. */
static inline void
-gimple_phi_arg_set_location (gimple gs, size_t i, source_location loc)
+gimple_phi_arg_set_location (gphi *phi, size_t i, source_location loc)
{
- gimple_phi_arg (gs, i)->locus = loc;
+ gimple_phi_arg (phi, i)->locus = loc;
}
-/* Return TRUE if argument I of phi node GS has a location record. */
+/* Return TRUE if argument I of phi node PHI has a location record. */
static inline bool
-gimple_phi_arg_has_location (gimple gs, size_t i)
+gimple_phi_arg_has_location (gphi *phi, size_t i)
{
- return gimple_phi_arg_location (gs, i) != UNKNOWN_LOCATION;
+ return gimple_phi_arg_location (phi, i) != UNKNOWN_LOCATION;
}
-/* Return the region number for GIMPLE_RESX GS. */
+/* Return the region number for GIMPLE_RESX RESX_STMT. */
static inline int
-gimple_resx_region (const_gimple gs)
+gimple_resx_region (const gresx *resx_stmt)
{
- const gimple_statement_resx *resx_stmt =
- as_a <const gimple_statement_resx *> (gs);
return resx_stmt->region;
}
-/* Set REGION to be the region number for GIMPLE_RESX GS. */
+/* Set REGION to be the region number for GIMPLE_RESX RESX_STMT. */
static inline void
-gimple_resx_set_region (gimple gs, int region)
+gimple_resx_set_region (gresx *resx_stmt, int region)
{
- gimple_statement_resx *resx_stmt = as_a <gimple_statement_resx *> (gs);
resx_stmt->region = region;
}
-/* Return the region number for GIMPLE_EH_DISPATCH GS. */
+/* Return the region number for GIMPLE_EH_DISPATCH EH_DISPATCH_STMT. */
static inline int
-gimple_eh_dispatch_region (const_gimple gs)
+gimple_eh_dispatch_region (const geh_dispatch *eh_dispatch_stmt)
{
- const gimple_statement_eh_dispatch *eh_dispatch_stmt =
- as_a <const gimple_statement_eh_dispatch *> (gs);
return eh_dispatch_stmt->region;
}
-/* Set REGION to be the region number for GIMPLE_EH_DISPATCH GS. */
+/* Set REGION to be the region number for GIMPLE_EH_DISPATCH
+ EH_DISPATCH_STMT. */
static inline void
-gimple_eh_dispatch_set_region (gimple gs, int region)
+gimple_eh_dispatch_set_region (geh_dispatch *eh_dispatch_stmt, int region)
{
- gimple_statement_eh_dispatch *eh_dispatch_stmt =
- as_a <gimple_statement_eh_dispatch *> (gs);
eh_dispatch_stmt->region = region;
}
/* Return the number of labels associated with the switch statement GS. */
static inline unsigned
-gimple_switch_num_labels (const_gimple gs)
+gimple_switch_num_labels (const gswitch *gs)
{
unsigned num_ops;
GIMPLE_CHECK (gs, GIMPLE_SWITCH);
/* Set NLABELS to be the number of labels for the switch statement GS. */
static inline void
-gimple_switch_set_num_labels (gimple g, unsigned nlabels)
+gimple_switch_set_num_labels (gswitch *g, unsigned nlabels)
{
GIMPLE_CHECK (g, GIMPLE_SWITCH);
gimple_set_num_ops (g, nlabels + 1);
/* Return the index variable used by the switch statement GS. */
static inline tree
-gimple_switch_index (const_gimple gs)
+gimple_switch_index (const gswitch *gs)
{
- GIMPLE_CHECK (gs, GIMPLE_SWITCH);
return gimple_op (gs, 0);
}
/* Return a pointer to the index variable for the switch statement GS. */
static inline tree *
-gimple_switch_index_ptr (const_gimple gs)
+gimple_switch_index_ptr (const gswitch *gs)
{
- GIMPLE_CHECK (gs, GIMPLE_SWITCH);
return gimple_op_ptr (gs, 0);
}
/* Set INDEX to be the index variable for switch statement GS. */
static inline void
-gimple_switch_set_index (gimple gs, tree index)
+gimple_switch_set_index (gswitch *gs, tree index)
{
GIMPLE_CHECK (gs, GIMPLE_SWITCH);
gcc_gimple_checking_assert (SSA_VAR_P (index) || CONSTANT_CLASS_P (index));
labels in a switch statement. */
static inline tree
-gimple_switch_label (const_gimple gs, unsigned index)
+gimple_switch_label (const gswitch *gs, unsigned index)
{
GIMPLE_CHECK (gs, GIMPLE_SWITCH);
gcc_gimple_checking_assert (gimple_num_ops (gs) > index + 1);
/* Set the label number INDEX to LABEL. 0 is always the default label. */
static inline void
-gimple_switch_set_label (gimple gs, unsigned index, tree label)
+gimple_switch_set_label (gswitch *gs, unsigned index, tree label)
{
GIMPLE_CHECK (gs, GIMPLE_SWITCH);
gcc_gimple_checking_assert (gimple_num_ops (gs) > index + 1
/* Return the default label for a switch statement. */
static inline tree
-gimple_switch_default_label (const_gimple gs)
+gimple_switch_default_label (const gswitch *gs)
{
tree label = gimple_switch_label (gs, 0);
gcc_checking_assert (!CASE_LOW (label) && !CASE_HIGH (label));
/* Set the default label for a switch statement. */
static inline void
-gimple_switch_set_default_label (gimple gs, tree label)
+gimple_switch_set_default_label (gswitch *gs, tree label)
{
gcc_checking_assert (!CASE_LOW (label) && !CASE_HIGH (label));
gimple_switch_set_label (gs, 0, label);
}
-/* Return the name associated with OMP_CRITICAL statement GS. */
+/* Return the name associated with OMP_CRITICAL statement CRIT_STMT. */
static inline tree
-gimple_omp_critical_name (const_gimple gs)
+gimple_omp_critical_name (const gomp_critical *crit_stmt)
{
- const gimple_statement_omp_critical *omp_critical_stmt =
- as_a <const gimple_statement_omp_critical *> (gs);
- return omp_critical_stmt->name;
+ return crit_stmt->name;
}
/* Return a pointer to the name associated with OMP critical statement GS. */
static inline tree *
-gimple_omp_critical_name_ptr (gimple gs)
+gimple_omp_critical_name_ptr (gomp_critical *crit_stmt)
{
- gimple_statement_omp_critical *omp_critical_stmt =
- as_a <gimple_statement_omp_critical *> (gs);
- return &omp_critical_stmt->name;
+ return &crit_stmt->name;
}
/* Set NAME to be the name associated with OMP critical statement GS. */
static inline void
-gimple_omp_critical_set_name (gimple gs, tree name)
+gimple_omp_critical_set_name (gomp_critical *crit_stmt, tree name)
{
- gimple_statement_omp_critical *omp_critical_stmt =
- as_a <gimple_statement_omp_critical *> (gs);
- omp_critical_stmt->name = name;
+ crit_stmt->name = name;
}
/* Set the OMP for kind. */
static inline void
-gimple_omp_for_set_kind (gimple g, int kind)
+gimple_omp_for_set_kind (gomp_for *g, int kind)
{
- GIMPLE_CHECK (g, GIMPLE_OMP_FOR);
g->subcode = (g->subcode & ~GF_OMP_FOR_KIND_MASK)
| (kind & GF_OMP_FOR_KIND_MASK);
}
value of COMBINED_P. */
static inline void
-gimple_omp_for_set_combined_p (gimple g, bool combined_p)
+gimple_omp_for_set_combined_p (gomp_for *g, bool combined_p)
{
- GIMPLE_CHECK (g, GIMPLE_OMP_FOR);
if (combined_p)
g->subcode |= GF_OMP_FOR_COMBINED;
else
value of COMBINED_P. */
static inline void
-gimple_omp_for_set_combined_into_p (gimple g, bool combined_p)
+gimple_omp_for_set_combined_into_p (gomp_for *g, bool combined_p)
{
- GIMPLE_CHECK (g, GIMPLE_OMP_FOR);
if (combined_p)
g->subcode |= GF_OMP_FOR_COMBINED_INTO;
else
static inline tree
gimple_omp_for_clauses (const_gimple gs)
{
- const gimple_statement_omp_for *omp_for_stmt =
- as_a <const gimple_statement_omp_for *> (gs);
+ const gomp_for *omp_for_stmt = as_a <const gomp_for *> (gs);
return omp_for_stmt->clauses;
}
static inline tree *
gimple_omp_for_clauses_ptr (gimple gs)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
return &omp_for_stmt->clauses;
}
static inline void
gimple_omp_for_set_clauses (gimple gs, tree clauses)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
omp_for_stmt->clauses = clauses;
}
static inline size_t
gimple_omp_for_collapse (gimple gs)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
return omp_for_stmt->collapse;
}
static inline tree
gimple_omp_for_index (const_gimple gs, size_t i)
{
- const gimple_statement_omp_for *omp_for_stmt =
- as_a <const gimple_statement_omp_for *> (gs);
+ const gomp_for *omp_for_stmt = as_a <const gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
return omp_for_stmt->iter[i].index;
}
static inline tree *
gimple_omp_for_index_ptr (gimple gs, size_t i)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
return &omp_for_stmt->iter[i].index;
}
static inline void
gimple_omp_for_set_index (gimple gs, size_t i, tree index)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
omp_for_stmt->iter[i].index = index;
}
static inline tree
gimple_omp_for_initial (const_gimple gs, size_t i)
{
- const gimple_statement_omp_for *omp_for_stmt =
- as_a <const gimple_statement_omp_for *> (gs);
+ const gomp_for *omp_for_stmt = as_a <const gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
return omp_for_stmt->iter[i].initial;
}
static inline tree *
gimple_omp_for_initial_ptr (gimple gs, size_t i)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
return &omp_for_stmt->iter[i].initial;
}
static inline void
gimple_omp_for_set_initial (gimple gs, size_t i, tree initial)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
omp_for_stmt->iter[i].initial = initial;
}
static inline tree
gimple_omp_for_final (const_gimple gs, size_t i)
{
- const gimple_statement_omp_for *omp_for_stmt =
- as_a <const gimple_statement_omp_for *> (gs);
+ const gomp_for *omp_for_stmt = as_a <const gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
return omp_for_stmt->iter[i].final;
}
static inline tree *
gimple_omp_for_final_ptr (gimple gs, size_t i)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
return &omp_for_stmt->iter[i].final;
}
static inline void
gimple_omp_for_set_final (gimple gs, size_t i, tree final)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
omp_for_stmt->iter[i].final = final;
}
static inline tree
gimple_omp_for_incr (const_gimple gs, size_t i)
{
- const gimple_statement_omp_for *omp_for_stmt =
- as_a <const gimple_statement_omp_for *> (gs);
+ const gomp_for *omp_for_stmt = as_a <const gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
return omp_for_stmt->iter[i].incr;
}
static inline tree *
gimple_omp_for_incr_ptr (gimple gs, size_t i)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
return &omp_for_stmt->iter[i].incr;
}
static inline void
gimple_omp_for_set_incr (gimple gs, size_t i, tree incr)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
omp_for_stmt->iter[i].incr = incr;
}
static inline gimple_seq *
gimple_omp_for_pre_body_ptr (gimple gs)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
return &omp_for_stmt->pre_body;
}
static inline void
gimple_omp_for_set_pre_body (gimple gs, gimple_seq pre_body)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
omp_for_stmt->pre_body = pre_body;
}
static inline tree
gimple_omp_parallel_clauses (const_gimple gs)
{
- const gimple_statement_omp_parallel *omp_parallel_stmt =
- as_a <const gimple_statement_omp_parallel *> (gs);
+ const gomp_parallel *omp_parallel_stmt = as_a <const gomp_parallel *> (gs);
return omp_parallel_stmt->clauses;
}
-/* Return a pointer to the clauses associated with OMP_PARALLEL GS. */
+/* Return a pointer to the clauses associated with OMP_PARALLEL_STMT. */
static inline tree *
-gimple_omp_parallel_clauses_ptr (gimple gs)
+gimple_omp_parallel_clauses_ptr (gomp_parallel *omp_parallel_stmt)
{
- gimple_statement_omp_parallel *omp_parallel_stmt =
- as_a <gimple_statement_omp_parallel *> (gs);
return &omp_parallel_stmt->clauses;
}
-/* Set CLAUSES to be the list of clauses associated with OMP_PARALLEL
- GS. */
+/* Set CLAUSES to be the list of clauses associated with OMP_PARALLEL_STMT. */
static inline void
-gimple_omp_parallel_set_clauses (gimple gs, tree clauses)
+gimple_omp_parallel_set_clauses (gomp_parallel *omp_parallel_stmt,
+ tree clauses)
{
- gimple_statement_omp_parallel *omp_parallel_stmt =
- as_a <gimple_statement_omp_parallel *> (gs);
omp_parallel_stmt->clauses = clauses;
}
-/* Return the child function used to hold the body of OMP_PARALLEL GS. */
+/* Return the child function used to hold the body of OMP_PARALLEL_STMT. */
static inline tree
-gimple_omp_parallel_child_fn (const_gimple gs)
+gimple_omp_parallel_child_fn (const gomp_parallel *omp_parallel_stmt)
{
- const gimple_statement_omp_parallel *omp_parallel_stmt =
- as_a <const gimple_statement_omp_parallel *> (gs);
return omp_parallel_stmt->child_fn;
}
/* Return a pointer to the child function used to hold the body of
- OMP_PARALLEL GS. */
+ OMP_PARALLEL_STMT. */
static inline tree *
-gimple_omp_parallel_child_fn_ptr (gimple gs)
+gimple_omp_parallel_child_fn_ptr (gomp_parallel *omp_parallel_stmt)
{
- gimple_statement_omp_parallel *omp_parallel_stmt =
- as_a <gimple_statement_omp_parallel *> (gs);
return &omp_parallel_stmt->child_fn;
}
-/* Set CHILD_FN to be the child function for OMP_PARALLEL GS. */
+/* Set CHILD_FN to be the child function for OMP_PARALLEL_STMT. */
static inline void
-gimple_omp_parallel_set_child_fn (gimple gs, tree child_fn)
+gimple_omp_parallel_set_child_fn (gomp_parallel *omp_parallel_stmt,
+ tree child_fn)
{
- gimple_statement_omp_parallel *omp_parallel_stmt =
- as_a <gimple_statement_omp_parallel *> (gs);
omp_parallel_stmt->child_fn = child_fn;
}
/* Return the artificial argument used to send variables and values
- from the parent to the children threads in OMP_PARALLEL GS. */
+ from the parent to the children threads in OMP_PARALLEL_STMT. */
static inline tree
-gimple_omp_parallel_data_arg (const_gimple gs)
+gimple_omp_parallel_data_arg (const gomp_parallel *omp_parallel_stmt)
{
- const gimple_statement_omp_parallel *omp_parallel_stmt =
- as_a <const gimple_statement_omp_parallel *> (gs);
return omp_parallel_stmt->data_arg;
}
-/* Return a pointer to the data argument for OMP_PARALLEL GS. */
+/* Return a pointer to the data argument for OMP_PARALLEL_STMT. */
static inline tree *
-gimple_omp_parallel_data_arg_ptr (gimple gs)
+gimple_omp_parallel_data_arg_ptr (gomp_parallel *omp_parallel_stmt)
{
- gimple_statement_omp_parallel *omp_parallel_stmt =
- as_a <gimple_statement_omp_parallel *> (gs);
return &omp_parallel_stmt->data_arg;
}
-/* Set DATA_ARG to be the data argument for OMP_PARALLEL GS. */
+/* Set DATA_ARG to be the data argument for OMP_PARALLEL_STMT. */
static inline void
-gimple_omp_parallel_set_data_arg (gimple gs, tree data_arg)
+gimple_omp_parallel_set_data_arg (gomp_parallel *omp_parallel_stmt,
+ tree data_arg)
{
- gimple_statement_omp_parallel *omp_parallel_stmt =
- as_a <gimple_statement_omp_parallel *> (gs);
omp_parallel_stmt->data_arg = data_arg;
}
static inline tree
gimple_omp_task_clauses (const_gimple gs)
{
- const gimple_statement_omp_task *omp_task_stmt =
- as_a <const gimple_statement_omp_task *> (gs);
+ const gomp_task *omp_task_stmt = as_a <const gomp_task *> (gs);
return omp_task_stmt->clauses;
}
static inline tree *
gimple_omp_task_clauses_ptr (gimple gs)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
return &omp_task_stmt->clauses;
}
static inline void
gimple_omp_task_set_clauses (gimple gs, tree clauses)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
omp_task_stmt->clauses = clauses;
}
static inline tree
gimple_omp_task_child_fn (const_gimple gs)
{
- const gimple_statement_omp_task *omp_task_stmt =
- as_a <const gimple_statement_omp_task *> (gs);
+ const gomp_task *omp_task_stmt = as_a <const gomp_task *> (gs);
return omp_task_stmt->child_fn;
}
static inline tree *
gimple_omp_task_child_fn_ptr (gimple gs)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
return &omp_task_stmt->child_fn;
}
static inline void
gimple_omp_task_set_child_fn (gimple gs, tree child_fn)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
omp_task_stmt->child_fn = child_fn;
}
static inline tree
gimple_omp_task_data_arg (const_gimple gs)
{
- const gimple_statement_omp_task *omp_task_stmt =
- as_a <const gimple_statement_omp_task *> (gs);
+ const gomp_task *omp_task_stmt = as_a <const gomp_task *> (gs);
return omp_task_stmt->data_arg;
}
static inline tree *
gimple_omp_task_data_arg_ptr (gimple gs)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
return &omp_task_stmt->data_arg;
}
static inline void
gimple_omp_task_set_data_arg (gimple gs, tree data_arg)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
omp_task_stmt->data_arg = data_arg;
}
static inline tree
gimple_omp_taskreg_clauses (const_gimple gs)
{
- const gimple_statement_omp_taskreg *omp_taskreg_stmt =
- as_a <const gimple_statement_omp_taskreg *> (gs);
+ const gimple_statement_omp_taskreg *omp_taskreg_stmt
+ = as_a <const gimple_statement_omp_taskreg *> (gs);
return omp_taskreg_stmt->clauses;
}
static inline tree *
gimple_omp_taskreg_clauses_ptr (gimple gs)
{
- gimple_statement_omp_taskreg *omp_taskreg_stmt =
- as_a <gimple_statement_omp_taskreg *> (gs);
+ gimple_statement_omp_taskreg *omp_taskreg_stmt
+ = as_a <gimple_statement_omp_taskreg *> (gs);
return &omp_taskreg_stmt->clauses;
}
static inline void
gimple_omp_taskreg_set_clauses (gimple gs, tree clauses)
{
- gimple_statement_omp_taskreg *omp_taskreg_stmt =
- as_a <gimple_statement_omp_taskreg *> (gs);
+ gimple_statement_omp_taskreg *omp_taskreg_stmt
+ = as_a <gimple_statement_omp_taskreg *> (gs);
omp_taskreg_stmt->clauses = clauses;
}
static inline tree
gimple_omp_taskreg_child_fn (const_gimple gs)
{
- const gimple_statement_omp_taskreg *omp_taskreg_stmt =
- as_a <const gimple_statement_omp_taskreg *> (gs);
+ const gimple_statement_omp_taskreg *omp_taskreg_stmt
+ = as_a <const gimple_statement_omp_taskreg *> (gs);
return omp_taskreg_stmt->child_fn;
}
static inline tree *
gimple_omp_taskreg_child_fn_ptr (gimple gs)
{
- gimple_statement_omp_taskreg *omp_taskreg_stmt =
- as_a <gimple_statement_omp_taskreg *> (gs);
+ gimple_statement_omp_taskreg *omp_taskreg_stmt
+ = as_a <gimple_statement_omp_taskreg *> (gs);
return &omp_taskreg_stmt->child_fn;
}
static inline void
gimple_omp_taskreg_set_child_fn (gimple gs, tree child_fn)
{
- gimple_statement_omp_taskreg *omp_taskreg_stmt =
- as_a <gimple_statement_omp_taskreg *> (gs);
+ gimple_statement_omp_taskreg *omp_taskreg_stmt
+ = as_a <gimple_statement_omp_taskreg *> (gs);
omp_taskreg_stmt->child_fn = child_fn;
}
static inline tree
gimple_omp_taskreg_data_arg (const_gimple gs)
{
- const gimple_statement_omp_taskreg *omp_taskreg_stmt =
- as_a <const gimple_statement_omp_taskreg *> (gs);
+ const gimple_statement_omp_taskreg *omp_taskreg_stmt
+ = as_a <const gimple_statement_omp_taskreg *> (gs);
return omp_taskreg_stmt->data_arg;
}
static inline tree *
gimple_omp_taskreg_data_arg_ptr (gimple gs)
{
- gimple_statement_omp_taskreg *omp_taskreg_stmt =
- as_a <gimple_statement_omp_taskreg *> (gs);
+ gimple_statement_omp_taskreg *omp_taskreg_stmt
+ = as_a <gimple_statement_omp_taskreg *> (gs);
return &omp_taskreg_stmt->data_arg;
}
static inline void
gimple_omp_taskreg_set_data_arg (gimple gs, tree data_arg)
{
- gimple_statement_omp_taskreg *omp_taskreg_stmt =
- as_a <gimple_statement_omp_taskreg *> (gs);
+ gimple_statement_omp_taskreg *omp_taskreg_stmt
+ = as_a <gimple_statement_omp_taskreg *> (gs);
omp_taskreg_stmt->data_arg = data_arg;
}
static inline tree
gimple_omp_task_copy_fn (const_gimple gs)
{
- const gimple_statement_omp_task *omp_task_stmt =
- as_a <const gimple_statement_omp_task *> (gs);
+ const gomp_task *omp_task_stmt = as_a <const gomp_task *> (gs);
return omp_task_stmt->copy_fn;
}
static inline tree *
gimple_omp_task_copy_fn_ptr (gimple gs)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
return &omp_task_stmt->copy_fn;
}
static inline void
gimple_omp_task_set_copy_fn (gimple gs, tree copy_fn)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
omp_task_stmt->copy_fn = copy_fn;
}
static inline tree
gimple_omp_task_arg_size (const_gimple gs)
{
- const gimple_statement_omp_task *omp_task_stmt =
- as_a <const gimple_statement_omp_task *> (gs);
+ const gomp_task *omp_task_stmt = as_a <const gomp_task *> (gs);
return omp_task_stmt->arg_size;
}
static inline tree *
gimple_omp_task_arg_size_ptr (gimple gs)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
return &omp_task_stmt->arg_size;
}
static inline void
gimple_omp_task_set_arg_size (gimple gs, tree arg_size)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
omp_task_stmt->arg_size = arg_size;
}
static inline tree
gimple_omp_task_arg_align (const_gimple gs)
{
- const gimple_statement_omp_task *omp_task_stmt =
- as_a <const gimple_statement_omp_task *> (gs);
+ const gomp_task *omp_task_stmt = as_a <const gomp_task *> (gs);
return omp_task_stmt->arg_align;
}
static inline tree *
gimple_omp_task_arg_align_ptr (gimple gs)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
return &omp_task_stmt->arg_align;
}
static inline void
gimple_omp_task_set_arg_align (gimple gs, tree arg_align)
{
- gimple_statement_omp_task *omp_task_stmt =
- as_a <gimple_statement_omp_task *> (gs);
+ gomp_task *omp_task_stmt = as_a <gomp_task *> (gs);
omp_task_stmt->arg_align = arg_align;
}
static inline tree
gimple_omp_single_clauses (const_gimple gs)
{
- const gimple_statement_omp_single *omp_single_stmt =
- as_a <const gimple_statement_omp_single *> (gs);
+ const gomp_single *omp_single_stmt = as_a <const gomp_single *> (gs);
return omp_single_stmt->clauses;
}
static inline tree *
gimple_omp_single_clauses_ptr (gimple gs)
{
- gimple_statement_omp_single *omp_single_stmt =
- as_a <gimple_statement_omp_single *> (gs);
+ gomp_single *omp_single_stmt = as_a <gomp_single *> (gs);
return &omp_single_stmt->clauses;
}
-/* Set CLAUSES to be the clauses associated with OMP_SINGLE GS. */
+/* Set CLAUSES to be the clauses associated with OMP_SINGLE_STMT. */
static inline void
-gimple_omp_single_set_clauses (gimple gs, tree clauses)
+gimple_omp_single_set_clauses (gomp_single *omp_single_stmt, tree clauses)
{
- gimple_statement_omp_single *omp_single_stmt =
- as_a <gimple_statement_omp_single *> (gs);
omp_single_stmt->clauses = clauses;
}
static inline tree
gimple_omp_target_clauses (const_gimple gs)
{
- const gimple_statement_omp_target *omp_target_stmt =
- as_a <const gimple_statement_omp_target *> (gs);
+ const gomp_target *omp_target_stmt = as_a <const gomp_target *> (gs);
return omp_target_stmt->clauses;
}
static inline tree *
gimple_omp_target_clauses_ptr (gimple gs)
{
- gimple_statement_omp_target *omp_target_stmt =
- as_a <gimple_statement_omp_target *> (gs);
+ gomp_target *omp_target_stmt = as_a <gomp_target *> (gs);
return &omp_target_stmt->clauses;
}
-/* Set CLAUSES to be the clauses associated with OMP_TARGET GS. */
+/* Set CLAUSES to be the clauses associated with OMP_TARGET_STMT. */
static inline void
-gimple_omp_target_set_clauses (gimple gs, tree clauses)
+gimple_omp_target_set_clauses (gomp_target *omp_target_stmt,
+ tree clauses)
{
- gimple_statement_omp_target *omp_target_stmt =
- as_a <gimple_statement_omp_target *> (gs);
omp_target_stmt->clauses = clauses;
}
/* Set the OMP target kind. */
static inline void
-gimple_omp_target_set_kind (gimple g, int kind)
+gimple_omp_target_set_kind (gomp_target *g, int kind)
{
- GIMPLE_CHECK (g, GIMPLE_OMP_TARGET);
g->subcode = (g->subcode & ~GF_OMP_TARGET_KIND_MASK)
| (kind & GF_OMP_TARGET_KIND_MASK);
}
-/* Return the child function used to hold the body of OMP_TARGET GS. */
+/* Return the child function used to hold the body of OMP_TARGET_STMT. */
static inline tree
-gimple_omp_target_child_fn (const_gimple gs)
+gimple_omp_target_child_fn (const gomp_target *omp_target_stmt)
{
- const gimple_statement_omp_target *omp_target_stmt =
- as_a <const gimple_statement_omp_target *> (gs);
return omp_target_stmt->child_fn;
}
/* Return a pointer to the child function used to hold the body of
- OMP_TARGET GS. */
+ OMP_TARGET_STMT. */
static inline tree *
-gimple_omp_target_child_fn_ptr (gimple gs)
+gimple_omp_target_child_fn_ptr (gomp_target *omp_target_stmt)
{
- gimple_statement_omp_target *omp_target_stmt =
- as_a <gimple_statement_omp_target *> (gs);
return &omp_target_stmt->child_fn;
}
-/* Set CHILD_FN to be the child function for OMP_TARGET GS. */
+/* Set CHILD_FN to be the child function for OMP_TARGET_STMT. */
static inline void
-gimple_omp_target_set_child_fn (gimple gs, tree child_fn)
+gimple_omp_target_set_child_fn (gomp_target *omp_target_stmt,
+ tree child_fn)
{
- gimple_statement_omp_target *omp_target_stmt =
- as_a <gimple_statement_omp_target *> (gs);
omp_target_stmt->child_fn = child_fn;
}
/* Return the artificial argument used to send variables and values
- from the parent to the children threads in OMP_TARGET GS. */
+ from the parent to the children threads in OMP_TARGET_STMT. */
static inline tree
-gimple_omp_target_data_arg (const_gimple gs)
+gimple_omp_target_data_arg (const gomp_target *omp_target_stmt)
{
- const gimple_statement_omp_target *omp_target_stmt =
- as_a <const gimple_statement_omp_target *> (gs);
return omp_target_stmt->data_arg;
}
/* Return a pointer to the data argument for OMP_TARGET GS. */
static inline tree *
-gimple_omp_target_data_arg_ptr (gimple gs)
+gimple_omp_target_data_arg_ptr (gomp_target *omp_target_stmt)
{
- gimple_statement_omp_target *omp_target_stmt =
- as_a <gimple_statement_omp_target *> (gs);
return &omp_target_stmt->data_arg;
}
-/* Set DATA_ARG to be the data argument for OMP_TARGET GS. */
+/* Set DATA_ARG to be the data argument for OMP_TARGET_STMT. */
static inline void
-gimple_omp_target_set_data_arg (gimple gs, tree data_arg)
+gimple_omp_target_set_data_arg (gomp_target *omp_target_stmt,
+ tree data_arg)
{
- gimple_statement_omp_target *omp_target_stmt =
- as_a <gimple_statement_omp_target *> (gs);
omp_target_stmt->data_arg = data_arg;
}
static inline tree
gimple_omp_teams_clauses (const_gimple gs)
{
- const gimple_statement_omp_teams *omp_teams_stmt =
- as_a <const gimple_statement_omp_teams *> (gs);
+ const gomp_teams *omp_teams_stmt = as_a <const gomp_teams *> (gs);
return omp_teams_stmt->clauses;
}
static inline tree *
gimple_omp_teams_clauses_ptr (gimple gs)
{
- gimple_statement_omp_teams *omp_teams_stmt =
- as_a <gimple_statement_omp_teams *> (gs);
+ gomp_teams *omp_teams_stmt = as_a <gomp_teams *> (gs);
return &omp_teams_stmt->clauses;
}
-/* Set CLAUSES to be the clauses associated with OMP_TEAMS GS. */
+/* Set CLAUSES to be the clauses associated with OMP_TEAMS_STMT. */
static inline void
-gimple_omp_teams_set_clauses (gimple gs, tree clauses)
+gimple_omp_teams_set_clauses (gomp_teams *omp_teams_stmt, tree clauses)
{
- gimple_statement_omp_teams *omp_teams_stmt =
- as_a <gimple_statement_omp_teams *> (gs);
omp_teams_stmt->clauses = clauses;
}
static inline tree
gimple_omp_sections_clauses (const_gimple gs)
{
- const gimple_statement_omp_sections *omp_sections_stmt =
- as_a <const gimple_statement_omp_sections *> (gs);
+ const gomp_sections *omp_sections_stmt = as_a <const gomp_sections *> (gs);
return omp_sections_stmt->clauses;
}
static inline tree *
gimple_omp_sections_clauses_ptr (gimple gs)
{
- gimple_statement_omp_sections *omp_sections_stmt =
- as_a <gimple_statement_omp_sections *> (gs);
+ gomp_sections *omp_sections_stmt = as_a <gomp_sections *> (gs);
return &omp_sections_stmt->clauses;
}
static inline void
gimple_omp_sections_set_clauses (gimple gs, tree clauses)
{
- gimple_statement_omp_sections *omp_sections_stmt =
- as_a <gimple_statement_omp_sections *> (gs);
+ gomp_sections *omp_sections_stmt = as_a <gomp_sections *> (gs);
omp_sections_stmt->clauses = clauses;
}
static inline tree
gimple_omp_sections_control (const_gimple gs)
{
- const gimple_statement_omp_sections *omp_sections_stmt =
- as_a <const gimple_statement_omp_sections *> (gs);
+ const gomp_sections *omp_sections_stmt = as_a <const gomp_sections *> (gs);
return omp_sections_stmt->control;
}
static inline tree *
gimple_omp_sections_control_ptr (gimple gs)
{
- gimple_statement_omp_sections *omp_sections_stmt =
- as_a <gimple_statement_omp_sections *> (gs);
+ gomp_sections *omp_sections_stmt = as_a <gomp_sections *> (gs);
return &omp_sections_stmt->control;
}
static inline void
gimple_omp_sections_set_control (gimple gs, tree control)
{
- gimple_statement_omp_sections *omp_sections_stmt =
- as_a <gimple_statement_omp_sections *> (gs);
+ gomp_sections *omp_sections_stmt = as_a <gomp_sections *> (gs);
omp_sections_stmt->control = control;
}
static inline void
gimple_omp_for_set_cond (gimple gs, size_t i, enum tree_code cond)
{
- gimple_statement_omp_for *omp_for_stmt =
- as_a <gimple_statement_omp_for *> (gs);
+ gomp_for *omp_for_stmt = as_a <gomp_for *> (gs);
gcc_gimple_checking_assert (TREE_CODE_CLASS (cond) == tcc_comparison
&& i < omp_for_stmt->collapse);
omp_for_stmt->iter[i].cond = cond;
static inline enum tree_code
gimple_omp_for_cond (const_gimple gs, size_t i)
{
- const gimple_statement_omp_for *omp_for_stmt =
- as_a <const gimple_statement_omp_for *> (gs);
+ const gomp_for *omp_for_stmt = as_a <const gomp_for *> (gs);
gcc_gimple_checking_assert (i < omp_for_stmt->collapse);
return omp_for_stmt->iter[i].cond;
}
/* Set the value being stored in an atomic store. */
static inline void
-gimple_omp_atomic_store_set_val (gimple g, tree val)
+gimple_omp_atomic_store_set_val (gomp_atomic_store *store_stmt, tree val)
{
- gimple_statement_omp_atomic_store *omp_atomic_store_stmt =
- as_a <gimple_statement_omp_atomic_store *> (g);
- omp_atomic_store_stmt->val = val;
+ store_stmt->val = val;
}
/* Return the value being stored in an atomic store. */
static inline tree
-gimple_omp_atomic_store_val (const_gimple g)
+gimple_omp_atomic_store_val (const gomp_atomic_store *store_stmt)
{
- const gimple_statement_omp_atomic_store *omp_atomic_store_stmt =
- as_a <const gimple_statement_omp_atomic_store *> (g);
- return omp_atomic_store_stmt->val;
+ return store_stmt->val;
}
/* Return a pointer to the value being stored in an atomic store. */
static inline tree *
-gimple_omp_atomic_store_val_ptr (gimple g)
+gimple_omp_atomic_store_val_ptr (gomp_atomic_store *store_stmt)
{
- gimple_statement_omp_atomic_store *omp_atomic_store_stmt =
- as_a <gimple_statement_omp_atomic_store *> (g);
- return &omp_atomic_store_stmt->val;
+ return &store_stmt->val;
}
/* Set the LHS of an atomic load. */
static inline void
-gimple_omp_atomic_load_set_lhs (gimple g, tree lhs)
+gimple_omp_atomic_load_set_lhs (gomp_atomic_load *load_stmt, tree lhs)
{
- gimple_statement_omp_atomic_load *omp_atomic_load_stmt =
- as_a <gimple_statement_omp_atomic_load *> (g);
- omp_atomic_load_stmt->lhs = lhs;
+ load_stmt->lhs = lhs;
}
/* Get the LHS of an atomic load. */
static inline tree
-gimple_omp_atomic_load_lhs (const_gimple g)
+gimple_omp_atomic_load_lhs (const gomp_atomic_load *load_stmt)
{
- const gimple_statement_omp_atomic_load *omp_atomic_load_stmt =
- as_a <const gimple_statement_omp_atomic_load *> (g);
- return omp_atomic_load_stmt->lhs;
+ return load_stmt->lhs;
}
/* Return a pointer to the LHS of an atomic load. */
static inline tree *
-gimple_omp_atomic_load_lhs_ptr (gimple g)
+gimple_omp_atomic_load_lhs_ptr (gomp_atomic_load *load_stmt)
{
- gimple_statement_omp_atomic_load *omp_atomic_load_stmt =
- as_a <gimple_statement_omp_atomic_load *> (g);
- return &omp_atomic_load_stmt->lhs;
+ return &load_stmt->lhs;
}
/* Set the RHS of an atomic load. */
static inline void
-gimple_omp_atomic_load_set_rhs (gimple g, tree rhs)
+gimple_omp_atomic_load_set_rhs (gomp_atomic_load *load_stmt, tree rhs)
{
- gimple_statement_omp_atomic_load *omp_atomic_load_stmt =
- as_a <gimple_statement_omp_atomic_load *> (g);
- omp_atomic_load_stmt->rhs = rhs;
+ load_stmt->rhs = rhs;
}
/* Get the RHS of an atomic load. */
static inline tree
-gimple_omp_atomic_load_rhs (const_gimple g)
+gimple_omp_atomic_load_rhs (const gomp_atomic_load *load_stmt)
{
- const gimple_statement_omp_atomic_load *omp_atomic_load_stmt =
- as_a <const gimple_statement_omp_atomic_load *> (g);
- return omp_atomic_load_stmt->rhs;
+ return load_stmt->rhs;
}
/* Return a pointer to the RHS of an atomic load. */
static inline tree *
-gimple_omp_atomic_load_rhs_ptr (gimple g)
+gimple_omp_atomic_load_rhs_ptr (gomp_atomic_load *load_stmt)
{
- gimple_statement_omp_atomic_load *omp_atomic_load_stmt =
- as_a <gimple_statement_omp_atomic_load *> (g);
- return &omp_atomic_load_stmt->rhs;
+ return &load_stmt->rhs;
}
/* Get the definition of the control variable in a GIMPLE_OMP_CONTINUE. */
static inline tree
-gimple_omp_continue_control_def (const_gimple g)
+gimple_omp_continue_control_def (const gomp_continue *cont_stmt)
{
- const gimple_statement_omp_continue *omp_continue_stmt =
- as_a <const gimple_statement_omp_continue *> (g);
- return omp_continue_stmt->control_def;
+ return cont_stmt->control_def;
}
/* The same as above, but return the address. */
static inline tree *
-gimple_omp_continue_control_def_ptr (gimple g)
+gimple_omp_continue_control_def_ptr (gomp_continue *cont_stmt)
{
- gimple_statement_omp_continue *omp_continue_stmt =
- as_a <gimple_statement_omp_continue *> (g);
- return &omp_continue_stmt->control_def;
+ return &cont_stmt->control_def;
}
/* Set the definition of the control variable in a GIMPLE_OMP_CONTINUE. */
static inline void
-gimple_omp_continue_set_control_def (gimple g, tree def)
+gimple_omp_continue_set_control_def (gomp_continue *cont_stmt, tree def)
{
- gimple_statement_omp_continue *omp_continue_stmt =
- as_a <gimple_statement_omp_continue *> (g);
- omp_continue_stmt->control_def = def;
+ cont_stmt->control_def = def;
}
/* Get the use of the control variable in a GIMPLE_OMP_CONTINUE. */
static inline tree
-gimple_omp_continue_control_use (const_gimple g)
+gimple_omp_continue_control_use (const gomp_continue *cont_stmt)
{
- const gimple_statement_omp_continue *omp_continue_stmt =
- as_a <const gimple_statement_omp_continue *> (g);
- return omp_continue_stmt->control_use;
+ return cont_stmt->control_use;
}
/* The same as above, but return the address. */
static inline tree *
-gimple_omp_continue_control_use_ptr (gimple g)
+gimple_omp_continue_control_use_ptr (gomp_continue *cont_stmt)
{
- gimple_statement_omp_continue *omp_continue_stmt =
- as_a <gimple_statement_omp_continue *> (g);
- return &omp_continue_stmt->control_use;
+ return &cont_stmt->control_use;
}
/* Set the use of the control variable in a GIMPLE_OMP_CONTINUE. */
static inline void
-gimple_omp_continue_set_control_use (gimple g, tree use)
+gimple_omp_continue_set_control_use (gomp_continue *cont_stmt, tree use)
{
- gimple_statement_omp_continue *omp_continue_stmt =
- as_a <gimple_statement_omp_continue *> (g);
- omp_continue_stmt->control_use = use;
+ cont_stmt->control_use = use;
}
-/* Return a pointer to the body for the GIMPLE_TRANSACTION statement GS. */
+/* Return a pointer to the body for the GIMPLE_TRANSACTION statement
+ TRANSACTION_STMT. */
static inline gimple_seq *
-gimple_transaction_body_ptr (gimple gs)
+gimple_transaction_body_ptr (gtransaction *transaction_stmt)
{
- gimple_statement_transaction *transaction_stmt =
- as_a <gimple_statement_transaction *> (gs);
return &transaction_stmt->body;
}
-/* Return the body for the GIMPLE_TRANSACTION statement GS. */
+/* Return the body for the GIMPLE_TRANSACTION statement TRANSACTION_STMT. */
static inline gimple_seq
-gimple_transaction_body (gimple gs)
+gimple_transaction_body (gtransaction *transaction_stmt)
{
- return *gimple_transaction_body_ptr (gs);
+ return *gimple_transaction_body_ptr (transaction_stmt);
}
/* Return the label associated with a GIMPLE_TRANSACTION. */
static inline tree
-gimple_transaction_label (const_gimple gs)
+gimple_transaction_label (const gtransaction *transaction_stmt)
{
- const gimple_statement_transaction *transaction_stmt =
- as_a <const gimple_statement_transaction *> (gs);
return transaction_stmt->label;
}
static inline tree *
-gimple_transaction_label_ptr (gimple gs)
+gimple_transaction_label_ptr (gtransaction *transaction_stmt)
{
- gimple_statement_transaction *transaction_stmt =
- as_a <gimple_statement_transaction *> (gs);
return &transaction_stmt->label;
}
/* Return the subcode associated with a GIMPLE_TRANSACTION. */
static inline unsigned int
-gimple_transaction_subcode (const_gimple gs)
+gimple_transaction_subcode (const gtransaction *transaction_stmt)
{
- GIMPLE_CHECK (gs, GIMPLE_TRANSACTION);
- return gs->subcode;
+ return transaction_stmt->subcode;
}
-/* Set BODY to be the body for the GIMPLE_TRANSACTION statement GS. */
+/* Set BODY to be the body for the GIMPLE_TRANSACTION statement
+ TRANSACTION_STMT. */
static inline void
-gimple_transaction_set_body (gimple gs, gimple_seq body)
+gimple_transaction_set_body (gtransaction *transaction_stmt,
+ gimple_seq body)
{
- gimple_statement_transaction *transaction_stmt =
- as_a <gimple_statement_transaction *> (gs);
transaction_stmt->body = body;
}
/* Set the label associated with a GIMPLE_TRANSACTION. */
static inline void
-gimple_transaction_set_label (gimple gs, tree label)
+gimple_transaction_set_label (gtransaction *transaction_stmt, tree label)
{
- gimple_statement_transaction *transaction_stmt =
- as_a <gimple_statement_transaction *> (gs);
transaction_stmt->label = label;
}
/* Set the subcode associated with a GIMPLE_TRANSACTION. */
static inline void
-gimple_transaction_set_subcode (gimple gs, unsigned int subcode)
+gimple_transaction_set_subcode (gtransaction *transaction_stmt,
+ unsigned int subcode)
{
- GIMPLE_CHECK (gs, GIMPLE_TRANSACTION);
- gs->subcode = subcode;
+ transaction_stmt->subcode = subcode;
}
/* Return a pointer to the return value for GIMPLE_RETURN GS. */
static inline tree *
-gimple_return_retval_ptr (const_gimple gs)
+gimple_return_retval_ptr (const greturn *gs)
{
- GIMPLE_CHECK (gs, GIMPLE_RETURN);
return gimple_op_ptr (gs, 0);
}
/* Return the return value for GIMPLE_RETURN GS. */
static inline tree
-gimple_return_retval (const_gimple gs)
+gimple_return_retval (const greturn *gs)
{
- GIMPLE_CHECK (gs, GIMPLE_RETURN);
return gimple_op (gs, 0);
}
/* Set RETVAL to be the return value for GIMPLE_RETURN GS. */
static inline void
-gimple_return_set_retval (gimple gs, tree retval)
+gimple_return_set_retval (greturn *gs, tree retval)
{
- GIMPLE_CHECK (gs, GIMPLE_RETURN);
gimple_set_op (gs, 0, retval);
}
+/* Return the return bounds for GIMPLE_RETURN GS. */
+
+static inline tree
+gimple_return_retbnd (const_gimple gs)
+{
+ GIMPLE_CHECK (gs, GIMPLE_RETURN);
+ return gimple_op (gs, 1);
+}
+
+
+/* Set RETVAL to be the return bounds for GIMPLE_RETURN GS. */
+
+static inline void
+gimple_return_set_retbnd (gimple gs, tree retval)
+{
+ GIMPLE_CHECK (gs, GIMPLE_RETURN);
+ gimple_set_op (gs, 1, retval);
+}
+
+
/* Returns true when the gimple statement STMT is any of the OpenMP types. */
#define CASE_GIMPLE_OMP \
original RHS type as far as we can reconstruct it. */
if (code == GIMPLE_CALL)
{
- if (gimple_call_internal_p (stmt)
- && gimple_call_internal_fn (stmt) == IFN_MASK_STORE)
- type = TREE_TYPE (gimple_call_arg (stmt, 3));
+ const gcall *call_stmt = as_a <const gcall *> (stmt);
+ if (gimple_call_internal_p (call_stmt)
+ && gimple_call_internal_fn (call_stmt) == IFN_MASK_STORE)
+ type = TREE_TYPE (gimple_call_arg (call_stmt, 3));
else
- type = gimple_call_return_type (stmt);
+ type = gimple_call_return_type (call_stmt);
}
else
switch (gimple_assign_rhs_code (stmt))