summaryrefslogtreecommitdiff
path: root/gcc/tree-vectorizer.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/tree-vectorizer.c')
-rw-r--r--gcc/tree-vectorizer.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/gcc/tree-vectorizer.c b/gcc/tree-vectorizer.c
index 47a25f8fe5e..396146d803a 100644
--- a/gcc/tree-vectorizer.c
+++ b/gcc/tree-vectorizer.c
@@ -111,7 +111,7 @@ along with GCC; see the file COPYING3. If not see
Since we only vectorize operations which vector form can be
expressed using existing tree codes, to verify that an operation is
supported, the vectorizer checks the relevant optab at the relevant
- machine_mode (e.g, add_optab->handlers[(int) V8HImode].insn_code). If
+ machine_mode (e.g, optab_handler (add_optab, V8HImode)->insn_code). If
the value found is CODE_FOR_nothing, then there's no target support, and
we can't vectorize the stmt.
@@ -1596,12 +1596,12 @@ vect_supportable_dr_alignment (struct data_reference *dr)
if (DR_IS_READ (dr))
{
- if (vec_realign_load_optab->handlers[mode].insn_code != CODE_FOR_nothing
+ if (optab_handler (vec_realign_load_optab, mode)->insn_code != CODE_FOR_nothing
&& (!targetm.vectorize.builtin_mask_for_load
|| targetm.vectorize.builtin_mask_for_load ()))
return dr_unaligned_software_pipeline;
- if (movmisalign_optab->handlers[mode].insn_code != CODE_FOR_nothing)
+ if (optab_handler (movmisalign_optab, mode)->insn_code != CODE_FOR_nothing)
/* Can't software pipeline the loads, but can at least do them. */
return dr_unaligned_supported;
}
@@ -1869,9 +1869,9 @@ supportable_widening_operation (enum tree_code code, tree stmt, tree vectype,
return false;
vec_mode = TYPE_MODE (vectype);
- if ((icode1 = optab1->handlers[(int) vec_mode].insn_code) == CODE_FOR_nothing
+ if ((icode1 = optab_handler (optab1, vec_mode)->insn_code) == CODE_FOR_nothing
|| insn_data[icode1].operand[0].mode != TYPE_MODE (wide_vectype)
- || (icode2 = optab2->handlers[(int) vec_mode].insn_code)
+ || (icode2 = optab_handler (optab2, vec_mode)->insn_code)
== CODE_FOR_nothing
|| insn_data[icode2].operand[0].mode != TYPE_MODE (wide_vectype))
return false;
@@ -1939,7 +1939,7 @@ supportable_narrowing_operation (enum tree_code code,
return false;
vec_mode = TYPE_MODE (vectype);
- if ((icode1 = optab1->handlers[(int) vec_mode].insn_code) == CODE_FOR_nothing
+ if ((icode1 = optab_handler (optab1, vec_mode)->insn_code) == CODE_FOR_nothing
|| insn_data[icode1].operand[0].mode != TYPE_MODE (narrow_vectype))
return false;