This is the mail archive of the
mailing list for the GCC project.
Re: [ping][PATCH][1 of 2] Add value range info to SSA_NAME for zero sign extension elimination in RTL
- From: Jan Hubicka <hubicka at ucw dot cz>
- To: Jakub Jelinek <jakub at redhat dot com>
- Cc: Richard Biener <rguenther at suse dot de>, Richard Earnshaw <rearnsha at arm dot com>, Kugan <kugan dot vivekanandarajah at linaro dot org>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, Eric Botcazou <ebotcazou at adacore dot com>, Ramana Radhakrishnan <Ramana dot Radhakrishnan at arm dot com>
- Date: Wed, 18 Sep 2013 11:12:57 +0200
- Subject: Re: [ping][PATCH][1 of 2] Add value range info to SSA_NAME for zero sign extension elimination in RTL
- Authentication-results: sourceware.org; auth=none
- References: <52300715 dot 4080307 at linaro dot org> <alpine dot LNX dot 2 dot 00 dot 1309111101220 dot 3150 at zhemvz dot fhfr dot qr> <20130911090837 dot GM1817 at tucnak dot redhat dot com> <alpine dot LNX dot 2 dot 00 dot 1309111110400 dot 3150 at zhemvz dot fhfr dot qr> <52329E95 dot 1080501 at linaro dot org> <52368DAB dot 1040103 at linaro dot org> <alpine dot LNX dot 2 dot 00 dot 1309161552480 dot 29729 at zhemvz dot fhfr dot qr> <52396AA0 dot 5010006 at arm dot com> <alpine dot LNX dot 2 dot 00 dot 1309181057210 dot 29729 at zhemvz dot fhfr dot qr> <20130918090658 dot GG1817 at tucnak dot redhat dot com>
> On Wed, Sep 18, 2013 at 10:57:57AM +0200, Richard Biener wrote:
> > On Wed, 18 Sep 2013, Richard Earnshaw wrote:
> > > On 16/09/13 15:13, Richard Biener wrote:
> > > > +void
> > > > +get_range_info (tree name, double_int &min, double_int &max,
> > > > + enum value_range_type &range_type)
> > > >
> > > > I'm not sure we want to use references. Well - first time.
> > >
> > > Personally, I don't think we should ever allow non-const references.
> > > Use of references means you can't tell from the source code that an
> > > argument to a function can be modified. It leads to confusion and makes
> > > things harder to debug.
I use non-const references in ipa-devirt code and speculative indirect call removal.
I am not thrilled by them, just it seems common in C++ source bases. If we don't want
them, i will remove these (they are used on two or three places, so it is easy)
> > That's a good argument, so please make get_range_info take pointers
> > to min/max/range_type.
> Or return range_type and just take min/max pointers?