This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PR middle-end/36902 Array bound warning with dead code after optimization
- From: Richard Guenther <richard dot guenther at gmail dot com>
- To: Manuel López-Ibáñez <lopezibanez at gmail dot com>
- Cc: Gcc Patch List <gcc-patches at gcc dot gnu dot org>, Richard Guenther <rguenther at suse dot de>, Diego Novillo <dnovillo at google dot com>, Ian Lance Taylor <iant at google dot com>
- Date: Fri, 17 Apr 2009 17:52:25 +0200
- Subject: Re: PR middle-end/36902 Array bound warning with dead code after optimization
- References: <6c33472e0810260516q4e1747a8lf96fe559fba8e1df@mail.gmail.com> <6c33472e0904090443h5954b588v94cff03415d86dae@mail.gmail.com> <6c33472e0904170842p67d1ea6l5b536ff6813d20ad@mail.gmail.com>
On Fri, Apr 17, 2009 at 5:42 PM, Manuel López-Ibáñez
<lopezibanez@gmail.com> wrote:
> PING2: http://gcc.gnu.org/ml/gcc-patches/2009-04/msg00689.html
Ok with
-search_for_addr_array (tree t, const location_t *location)
+search_for_addr_array(tree t, location_t location)
{
this whitespace change removed.
Thanks,
Richard.
> 2009/4/9 Manuel López-Ibáñez <lopezibanez@gmail.com>:
>> Updated to a recent revision, bootstrapped and regression tested on
>> x86_64-unknown-linux-gnu with
>> --enable-languages=all,obj-c++ --enable-decimal-float.
>>
>> 2009-04-09 ?Manuel López-Ibáñez ?<manu@gcc.gnu.org>
>>
>> ? ? ? ?PR middle-end/36902
>> ? ? ? ?* tree-vrp.c (check_array_ref): Pass a location_t instead of a
>> ? ? ? ?pointer. Use warning_at instead of warning.
>> ? ? ? ?(search_for_addr_array): Likewise.
>> ? ? ? ?(check_array_bounds): Likewise.
>> ? ? ? ?(check_all_array_refs): Check that the incoming edge is not in the
>> ? ? ? ?list of edges to be removed.
>> ? ? ? ?(check_all_array_refs): Avoid the temporal pointer.
>> ? ? ? ?(vrp_visit_cond_stmt): Fix typo.
>> ? ? ? ?(simplify_switch_using_ranges): Handle the case where the switch
>> ? ? ? ?index is an integer constant.
>> testsuite/
>> ? ? ? ?* gcc.dg/pr36902.c: New.
>>
>>
>> OK for trunk?
>>
>> Manuel.
>>
>> 2008/10/26 Manuel López-Ibáñez <lopezibanez@gmail.com>:
>>> Bootstrapped and regression tested on x86_64-unknown-linux-gnu with
>>> --enable-languages=all,obj-c++ --enable-decimal-float.
>>>
>>> This could be improved further by:
>>>
>>> * Marking the edges to be removed in some way, so we don't have to
>>> search in the list to_remove_edges.
>>> * Considering BBs that have more than one incoming edge.
>>> * Augmenting get_value_range to handle integer constants (or constants
>>> in general).
>>> * Augmenting find_case_label_range to handle more efficiently the case
>>> where i == j.
>>>
>>> Nonetheless, the current patch is enough to fix the PR. I could
>>> include the above proposals in the comments.
>>>
>>
>