On Tue, Jul 14, 2015 at 02:41:04PM +0300, Ilya Verbin wrote:
> This caused:
> 
> gcc/tree-vect-stmts.c: In function ‘bool vectorizable_simd_clone_call(gimple, 
> gimple_stmt_iterator*, gimple_statement_base**, slp_tree)’:
> gcc/tree-vect-stmts.c:2810:13: error: enumeration value 
> ‘SIMD_CLONE_ARG_TYPE_LINEAR_REF_CONSTANT_STEP’ not handled in switch 
> [-Werror=switch]
>       switch (n->simdclone->args[i].arg_type)
>              ^
> gcc/tree-vect-stmts.c:2810:13: error: enumeration value 
> ‘SIMD_CLONE_ARG_TYPE_LINEAR_UVAL_CONSTANT_STEP’ not handled in switch 
> [-Werror=switch]
> gcc/tree-vect-stmts.c:2810:13: error: enumeration value 
> ‘SIMD_CLONE_ARG_TYPE_LINEAR_VAL_CONSTANT_STEP’ not handled in switch 
> [-Werror=switch]
> cc1plus: all warnings being treated as errors
> make[4]: *** [tree-vect-stmts.o] Error 1

Oops, missed that warning (and haven't bootstrapped the branch
for a while now).

Fixed thusly, to handle VAL/UVAL better we'll need to find the last
store into the memory and determine if the stored value is linear.
Something deferred for later.

2015-07-14  Jakub Jelinek  <ja...@redhat.com>

        * tree-vect-stmts.c (vectorizable_simd_clone_call): Handle
        SIMD_CLONE_ARG_TYPE_LINEAR_{REF,VAL,UVAL}_CONSTANT_STEP.

--- gcc/tree-vect-stmts.c.jj    2015-07-14 14:30:06.000000000 +0200
+++ gcc/tree-vect-stmts.c       2015-07-14 14:45:08.032376586 +0200
@@ -2825,6 +2825,7 @@ vectorizable_simd_clone_call (gimple stm
                  i = -1;
                break;
              case SIMD_CLONE_ARG_TYPE_LINEAR_CONSTANT_STEP:
+             case SIMD_CLONE_ARG_TYPE_LINEAR_REF_CONSTANT_STEP:
                if (arginfo[i].dt == vect_constant_def
                    || arginfo[i].dt == vect_external_def
                    || (arginfo[i].linear_step
@@ -2832,6 +2833,8 @@ vectorizable_simd_clone_call (gimple stm
                  i = -1;
                break;
              case SIMD_CLONE_ARG_TYPE_LINEAR_VARIABLE_STEP:
+             case SIMD_CLONE_ARG_TYPE_LINEAR_VAL_CONSTANT_STEP:
+             case SIMD_CLONE_ARG_TYPE_LINEAR_UVAL_CONSTANT_STEP:
                /* FORNOW */
                i = -1;
                break;


        Jakub

Reply via email to