This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: When not optimizing do not compute RTX memory attributes
- From: Jan Hubicka <hubicka at ucw dot cz>
- To: Richard Biener <rguenther at suse dot de>
- Cc: Jan Hubicka <hubicka at ucw dot cz>, gcc-patches at gcc dot gnu dot org
- Date: Tue, 1 Dec 2015 19:39:05 +0100
- Subject: Re: When not optimizing do not compute RTX memory attributes
- Authentication-results: sourceware.org; auth=none
- References: <20151201070737 dot GA51402 at kam dot mff dot cuni dot cz> <alpine dot LSU dot 2 dot 11 dot 1512011140320 dot 4884 at t29 dot fhfr dot qr>
> On Tue, 1 Dec 2015, Jan Hubicka wrote:
>
> > Hi,
> > memory attributes are currently optimized and attached to RTL even when not
> > optimizing. This is obviously just a wasted effort.
>
> Huh, are you sure? What about globals used from different optimize
> contexts?
Hmm, you are right - we will get worse code quality. The code won't ICE
because MEM_ATTRS can legally be NULL - get_mem_attrs will then supply default
one for given mode, but we will miss code quality. I will look into disabling
mem attrs for non-globals only.
It would be nice to get rid of those global persistent RTLs (and make DECL_RTL
to be function local hash)
Honza