This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Fix PR53501
- From: Eric Botcazou <ebotcazou at adacore dot com>
- To: "H.J. Lu" <hjl dot tools at gmail dot com>
- Cc: gcc-patches at gcc dot gnu dot org, Richard Guenther <rguenther at suse dot de>
- Date: Thu, 01 Nov 2012 09:41:56 +0100
- Subject: Re: [PATCH] Fix PR53501
- References: <Pine.LNX.4.64.1205301241021.5860@jbgna.fhfr.qr> <2264722.DYetclvNFg@polaris> <CAMe9rOqj6g9=z1svVpxCi4_NLNU9RCWJGJNLLo=KJ7u_2wJr1Q@mail.gmail.com>
> It was OK until revision 187042:
>
> 2012-05-02 Richard Guenther <rguenther@suse.de>
>
> * tree.c (valid_constant_size_p): New function.
> * tree.h (valid_constant_size_p): Declare.
> * cfgexpand.c (expand_one_var): Adjust check for too large
> variables by using valid_constant_size_p.
> * varasm.c (assemble_variable): Likewise.
>
> c/
> * c-decl.c (grokdeclarator): Properly check for sizes that
> cover more than half of the address-space.
>
> cp/
> * decl.c (grokdeclarator): Properly check for sizes that
> cover more than half of the address-space.
>
> 2012-05-02 Richard Guenther <rguenther@suse.de>
>
> * fold-const.c (div_if_zero_remainder): sizetypes no longer
> sign-extend.
> (int_const_binop_1): New worker for int_const_binop with
> overflowable parameter. Pass it through
> to force_fit_type_double.
> (int_const_binop): Wrap around int_const_binop_1 with overflowable
> equal to one.
> (size_binop_loc): Call int_const_binop_1 with overflowable equal
> to minus one, forcing overflow detection for even unsigned types.
> (extract_muldiv_1): Remove bogus TYPE_IS_SIZETYPE special-casing.
> (fold_binary_loc): Call try_move_mult_to_index with signed offset.
> * stor-layout.c (initialize_sizetypes): sizetypes no longer
> sign-extend.
> (layout_type): For zero-sized arrays ignore overflow on the
> size calculations.
> * tree-ssa-ccp.c (bit_value_unop_1): Likewise.
> (bit_value_binop_1): Likewise.
> * tree.c (double_int_to_tree): Likewise.
> (double_int_fits_to_tree_p): Likewise.
> (force_fit_type_double): Likewise.
> (host_integerp): Likewise.
> (int_fits_type_p): Likewise.
> * varasm.c (output_constructor_regular_field): Sign-extend the field
> offset to cater for negative offsets produced by the Ada frontend.
> * omp-low.c (extract_omp_for_data): Convert the loop step to
> signed for pointer adjustments.
OK, thanks for digging. I'll have a look.
--
Eric Botcazou