Commit fb2c2b16 by Ira Rosen Committed by Ira Rosen

re PR tree-optimization/50039 (Segfault in vect_operation_fits_smaller_type())


        PR tree-optimization/50039
        * tree-vect-patterns.c (vect_operation_fits_smaller_type): Check
        that DEF_STMT has a stmt_vec_info.

From-SVN: r177647
parent 7746e0a1
2011-08-11 Ira Rosen <ira.rosen@linaro.org>
PR tree-optimization/50039
* tree-vect-patterns.c (vect_operation_fits_smaller_type): Check
that DEF_STMT has a stmt_vec_info.
2011-08-10 Richard Guenther <rguenther@suse.de> 2011-08-10 Richard Guenther <rguenther@suse.de>
* tree.h (can_trust_pointer_alignment): Remove. * tree.h (can_trust_pointer_alignment): Remove.
......
2011-08-11 Ira Rosen <ira.rosen@linaro.org>
PR tree-optimization/50039
* gcc.dg/vect/vect.exp: Run no-tree-fre-* tests with -fno-tree-fre.
* gcc.dg/vect/no-tree-fre-pr50039.c: New test.
2011-08-10 H.J. Lu <hongjiu.lu@intel.com> 2011-08-10 H.J. Lu <hongjiu.lu@intel.com>
* gcc.target/i386/sse4_1-blendps-2.c: Include <stdlib.h>. * gcc.target/i386/sse4_1-blendps-2.c: Include <stdlib.h>.
......
/* { dg-do compile } */
extern unsigned char g_5;
extern int g_31, g_76;
int main(void) {
int i, j;
for (j=0; j < 2; ++j) {
g_31 = -3;
for (i=0; i < 2; ++i)
g_76 = (g_31 ? g_31+1 : 0) ^ g_5;
}
}
/* { dg-final { cleanup-tree-dump "vect" } } */
...@@ -257,6 +257,12 @@ lappend VECT_SLP_CFLAGS "-fno-tree-reassoc" ...@@ -257,6 +257,12 @@ lappend VECT_SLP_CFLAGS "-fno-tree-reassoc"
dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/no-tree-reassoc-bb-slp-*.\[cS\]]] \ dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/no-tree-reassoc-bb-slp-*.\[cS\]]] \
"" $VECT_SLP_CFLAGS "" $VECT_SLP_CFLAGS
# -fno-tree-fre
set DEFAULT_VECTCFLAGS $SAVED_DEFAULT_VECTCFLAGS
lappend DEFAULT_VECTCFLAGS "-fno-tree-fre"
dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/no-tree-fre-*.\[cS\]]] \
"" $DEFAULT_VECTCFLAGS
# Clean up. # Clean up.
set dg-do-what-default ${save-dg-do-what-default} set dg-do-what-default ${save-dg-do-what-default}
......
...@@ -897,7 +897,8 @@ vect_operation_fits_smaller_type (gimple stmt, tree def, tree *new_type, ...@@ -897,7 +897,8 @@ vect_operation_fits_smaller_type (gimple stmt, tree def, tree *new_type,
else else
{ {
first = true; first = true;
if (!widened_name_p (oprnd, stmt, &half_type, &def_stmt, false)) if (!widened_name_p (oprnd, stmt, &half_type, &def_stmt, false)
|| !vinfo_for_stmt (def_stmt))
return false; return false;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment