From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13107 invoked by alias); 9 Aug 2011 07:41:02 -0000 Received: (qmail 13093 invoked by uid 22791); 9 Aug 2011 07:41:01 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,TW_ZJ X-Spam-Check-By: sourceware.org Received: from mail-pz0-f49.google.com (HELO mail-pz0-f49.google.com) (209.85.210.49) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 09 Aug 2011 07:40:47 +0000 Received: by pzk6 with SMTP id 6so12563465pzk.8 for ; Tue, 09 Aug 2011 00:40:46 -0700 (PDT) MIME-Version: 1.0 Received: by 10.142.151.27 with SMTP id y27mr5637880wfd.229.1312875646427; Tue, 09 Aug 2011 00:40:46 -0700 (PDT) Received: by 10.142.118.41 with HTTP; Tue, 9 Aug 2011 00:40:46 -0700 (PDT) In-Reply-To: References: <201108081530.p78FUAgM029764@d06av02.portsmouth.uk.ibm.com> Date: Tue, 09 Aug 2011 07:41:00 -0000 Message-ID: Subject: Re: [RFC PATCH, i386]: Allow zero_extended addresses (+ problems with reload and offsetable address, "o" constraint) From: Uros Bizjak To: Ulrich Weigand Cc: gcc-patches@gcc.gnu.org, GCC Development , "H.J. Lu" Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2011-08/txt/msg00178.txt.bz2 On Mon, Aug 8, 2011 at 7:11 PM, Uros Bizjak wrote: >> Moves are special as far as reload is concerned. =A0If there is already >> a move instruction present *before* reload, it will get fixed up >> according to its constraints as any other instruction. >> >> However, reload will *introduce* new moves as part of its operation, >> and those will *not* themselves get reloaded. =A0Instead, reload simply >> assumes that every plain move will just succeed without requiring >> any reload; if this is not true, the target *must* provide a >> secondary reload for this move. >> >> (Note that the secondary reload could also work by reloading the >> target address into a temporary; that's up to the target to >> implement.) > > Whoa, indeed. > > Using attached patch that reloads memory address instead of going > through XMM register, the code for the testcase improves from: Committed to mainline with following ChangeLog entry: 2011-08-09 Uros Bizjak PR target/49781 * config/i386/i386.md (reload_noff_load): New. (reload_noff_store): Ditto. * config/i386/i386.c (ix86_secondary_reload): Use CODE_FOR_reload_noff_load and CODE_FOR_reload_noff_store to handle double-word moves from/to non-offsetable addresses instead of generating XMM temporary. Re-bootstrapped and re-tested on x86_64-pc-linux-gnu {,-m32}. Uros.