diff options
author | Michael Matz <matz@suse.de> | 2009-08-19 14:29:52 +0000 |
---|---|---|
committer | Michael Matz <matz@gcc.gnu.org> | 2009-08-19 14:29:52 +0000 |
commit | 9600efe1a6c42b8acf7449561760c36968155f83 (patch) | |
tree | 8489ea3ed78727eeb377ad35611c3a1779e5bb14 /gcc/gimplify.c | |
parent | 10174ddf5d0e0e2293e54ebc14f9c49a9983de98 (diff) | |
download | gcc-9600efe1a6c42b8acf7449561760c36968155f83.zip gcc-9600efe1a6c42b8acf7449561760c36968155f83.tar.gz gcc-9600efe1a6c42b8acf7449561760c36968155f83.tar.bz2 |
omp-low.c (optimize_omp_library_calls): Use types_compatible_p instead of comparing TYPE_MAIN_VARIANT for equality.
* omp-low.c (optimize_omp_library_calls): Use types_compatible_p
instead of comparing TYPE_MAIN_VARIANT for equality.
* tree-vect-patterns.c (vect_recog_dot_prod_pattern,
vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern): Ditto.
* tree-vect-loop.c (vect_is_simple_reduction): Ditto.
* gimplify.c (goa_lhs_expr_p): Ditto and use
STRIP_USELESS_TYPE_CONVERSION.
From-SVN: r150936
Diffstat (limited to 'gcc/gimplify.c')
-rw-r--r-- | gcc/gimplify.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/gcc/gimplify.c b/gcc/gimplify.c index 7de2a7e..3ba40a8 100644 --- a/gcc/gimplify.c +++ b/gcc/gimplify.c @@ -6152,12 +6152,7 @@ goa_lhs_expr_p (tree expr, tree addr) /* Also include casts to other type variants. The C front end is fond of adding these for e.g. volatile variables. This is like STRIP_TYPE_NOPS but includes the main variant lookup. */ - while ((CONVERT_EXPR_P (expr) - || TREE_CODE (expr) == NON_LVALUE_EXPR) - && TREE_OPERAND (expr, 0) != error_mark_node - && (TYPE_MAIN_VARIANT (TREE_TYPE (expr)) - == TYPE_MAIN_VARIANT (TREE_TYPE (TREE_OPERAND (expr, 0))))) - expr = TREE_OPERAND (expr, 0); + STRIP_USELESS_TYPE_CONVERSION (expr); if (TREE_CODE (expr) == INDIRECT_REF) { @@ -6166,8 +6161,7 @@ goa_lhs_expr_p (tree expr, tree addr) && (CONVERT_EXPR_P (expr) || TREE_CODE (expr) == NON_LVALUE_EXPR) && TREE_CODE (expr) == TREE_CODE (addr) - && TYPE_MAIN_VARIANT (TREE_TYPE (expr)) - == TYPE_MAIN_VARIANT (TREE_TYPE (addr))) + && types_compatible_p (TREE_TYPE (expr), TREE_TYPE (addr))) { expr = TREE_OPERAND (expr, 0); addr = TREE_OPERAND (addr, 0); |