re PR middle-end/43390 (ICE: integral result type precision does not match field size of BIT_FIELD_REF)
2010-03-22 Richard Guenther <rguenther@suse.de> PR tree-optimization/43390 * tree-vect-stmts.c (get_vectype_for_scalar_type): Make sure vector extracts are type correct. * gfortran.fortran-torture/execute/pr43390.f90: New testcase. From-SVN: r157624
This commit is contained in:
parent
6af84c851d
commit
6d7971b832
@ -1,3 +1,9 @@
|
||||
2010-03-22 Richard Guenther <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/43390
|
||||
* tree-vect-stmts.c (get_vectype_for_scalar_type): Make
|
||||
sure vector extracts are type correct.
|
||||
|
||||
2010-03-22 Richard Guenther <rguenther@suse.de>
|
||||
|
||||
PR middle-end/40106
|
||||
|
@ -1,3 +1,8 @@
|
||||
2010-03-22 Richard Guenther <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/43390
|
||||
* gfortran.fortran-torture/execute/pr43390.f90: New testcase.
|
||||
|
||||
2010-03-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
|
||||
|
||||
* gcc.target/powerpc/ppc-sdata-1.c: Require nonpic.
|
||||
|
@ -0,0 +1,9 @@
|
||||
logical :: l1(4)
|
||||
logical :: l2(4)
|
||||
l1 = (/.TRUE.,.FALSE.,.TRUE.,.FALSE./)
|
||||
l2 = (/.FALSE.,.TRUE.,.FALSE.,.TRUE./)
|
||||
if (dot_product (l1, l2)) call abort ()
|
||||
l2 = .TRUE.
|
||||
if (.not.dot_product (l1, l2)) call abort ()
|
||||
end
|
||||
|
@ -4417,6 +4417,14 @@ get_vectype_for_scalar_type (tree scalar_type)
|
||||
if (nbytes < TYPE_ALIGN_UNIT (scalar_type))
|
||||
return NULL_TREE;
|
||||
|
||||
/* If we'd build a vector type of elements whose mode precision doesn't
|
||||
match their types precision we'll get mismatched types on vector
|
||||
extracts via BIT_FIELD_REFs. This effectively means we disable
|
||||
vectorization of bool and/or enum types in some languages. */
|
||||
if (INTEGRAL_TYPE_P (scalar_type)
|
||||
&& GET_MODE_BITSIZE (inner_mode) != TYPE_PRECISION (scalar_type))
|
||||
return NULL_TREE;
|
||||
|
||||
/* FORNOW: Only a single vector size per mode (UNITS_PER_SIMD_WORD)
|
||||
is expected. */
|
||||
nunits = UNITS_PER_SIMD_WORD (inner_mode) / nbytes;
|
||||
|
Loading…
x
Reference in New Issue
Block a user