From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10879 invoked by alias); 9 Apr 2003 18:41:22 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 10833 invoked from network); 9 Apr 2003 18:41:20 -0000 Received: from unknown (HELO nikam.ms.mff.cuni.cz) (195.113.18.106) by sources.redhat.com with SMTP; 9 Apr 2003 18:41:20 -0000 Received: from camelot.ms.mff.cuni.cz (kampanus.ms.mff.cuni.cz [195.113.18.107]) by nikam.ms.mff.cuni.cz (Postfix) with SMTP id 930E54DF08; Wed, 9 Apr 2003 20:41:19 +0200 (CEST) Received: by camelot.ms.mff.cuni.cz (sSMTP sendmail emulation); Wed, 9 Apr 2003 20:41:21 +0200 Date: Wed, 09 Apr 2003 19:15:00 -0000 From: Jan Hubicka To: Eric Botcazou Cc: Jan Hubicka , gcc@gcc.gnu.org Subject: Re: Reload bug Message-ID: <20030409184121.GF23694@kam.mff.cuni.cz> References: <200304081937.16859.ebotcazou@libertysurf.fr> <200304091105.24896.ebotcazou@libertysurf.fr> <20030409112544.GA12755@kam.mff.cuni.cz> <200304091847.23040.ebotcazou@libertysurf.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200304091847.23040.ebotcazou@libertysurf.fr> User-Agent: Mutt/1.3.28i X-SW-Source: 2003-04/txt/msg00383.txt.bz2 > > Concerning this testcase, the reload used to manage to get around this > > problem. It didn't get around intentionally and just because the > > instruction contrain does not accept SSE register so reload is needed > > anyway. The idea of reloading whole SSE register into integer is no-go > > as can be see from the other testcases. There are two cases when the > > reload is really needed: > > 1) we are not able to access the SUBREG_BYTE part because of > > the problem above because SUBREG_BYTE is not divisible by size of the > > register (there is no way to get the size of the register, but I guess > > we can use GET_MODE_SIZE / HARD_REGNO_NREGS) and we will also need to > > compensate the lowparts, > > > > This is the problem we are seeing. It is IMO questionable whether it > > is valid to see such scenario and whether local alloc can produce > > such a subregs that has no representation. My CANNOT_CHANGE_MODE_P > > patch avoids that as it causes the problem described above. > > > > 2) We are outputing into the register and the HARD_REGNO_NREGS is > > decreasing so we may convert subreg rewriting just part of the > > register to the subreg rewriting the lower part and clobbering upper > > part. This is what I beleive the conditional was originally invented > > for. > > > > Are we in the sync now? > > I don't fully understand the second point. Could you give an example? It would be something like (subreg:SI (reg:TI) 8)) that is "set 8-12th byte of TIregister) when HARD_REGNO_NREGS is 4, but "set 8-12th byte and clobber 12th-16th byte) when HARD_REGNO_NREGS is 2. Not sure if it happens in real code... Honza > > > It seems to be that the conditional is still overconservative for 2) as > > it is still possible that the subreg is large enought to fit into > > HARD_REGNO_NREGS of the destination and it now ignores 1). It is > > question whether 1) can legaly happen at all but I see it does for 3.2 > > (and does not for 3.3). > > Are you sure of that for 3.3? Because we will silently miscompile too if > there are a few leaks. > > -- > Eric Botcazou