From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16911 invoked by alias); 28 Jan 2002 20:15:12 -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 16847 invoked from network); 28 Jan 2002 20:15:08 -0000 Received: from unknown (HELO cygnus.com) (205.180.230.5) by sources.redhat.com with SMTP; 28 Jan 2002 20:15:08 -0000 Received: from porcupine.cygnus.com (cse.sfbay.redhat.com [205.180.230.236]) by runyon.cygnus.com (8.8.7-cygnus/8.8.7) with ESMTP id MAA18437 for ; Mon, 28 Jan 2002 12:15:06 -0800 (PST) Received: from porcupine.cygnus.com (law@localhost) by porcupine.cygnus.com (8.11.6/8.11.6) with ESMTP id g0SKCeB16982; Mon, 28 Jan 2002 13:12:40 -0700 X-Mailer: exmh version 2.4 06/23/2000 with nmh-1.0.4 To: kenner@vlsi1.ultra.nyu.edu (Richard Kenner) cc: gcc@gcc.gnu.org Subject: Re: paradoxical subreg problem Reply-To: law@redhat.com From: law@redhat.com In-reply-to: Your message of Mon, 28 Jan 2002 14:59:15 EST. <10201281959.AA25855@vlsi1.ultra.nyu.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Mon, 28 Jan 2002 13:10:00 -0000 Message-ID: <16981.1012248759@porcupine.cygnus.com> X-SW-Source: 2002-01/txt/msg01826.txt.bz2 In message <10201281959.AA25855@vlsi1.ultra.nyu.edu>, Richard Kenner writes: > I think the code issue here is that if the bits are undefined, why is > this being generated? Err, if the bits were undefined, then we can't make any assumptions about their value. Contrast that to how the compiler treats those bits -- it treats them as "don't care, assume any useful value". If the bits are undefined in the traditional sense, then this expression is not a compile-time constant: (eq (subreg:SI (mem/s:QI (plus:SI (reg:SI 3 %r3) (const_int 15 [0xf])) 1) 0) (mem/s:SI (plus:SI (reg:SI 3 %r3) (const_int 12 [0xc])) 1)) If the bits are undefined in the traditional sense, then these two expressions are _NOT_ equivalent: (and:SI (subreg:SI (mem:QI) 0) (const_int 255)) (subreg:SI (mem:QI X) 0) jeff jeff