From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17642 invoked by alias); 14 Mar 2002 07:56:01 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 17606 invoked by uid 71); 14 Mar 2002 07:56:01 -0000 Resent-Date: 14 Mar 2002 07:56:01 -0000 Resent-Message-ID: <20020314075601.17605.qmail@sources.redhat.com> Resent-From: gcc-gnats@gcc.gnu.org (GNATS Filer) Resent-To: nobody@gcc.gnu.org Resent-Cc: gcc-prs@gcc.gnu.org, gcc-bugs@gcc.gnu.org Resent-Reply-To: gcc-gnats@gcc.gnu.org, Zoltan Hidvegi Received:(qmail 7512 invoked from network); 14 Mar 2002 07:50:44 -0000 Received: from unknown (HELO mg03.austin.ibm.com) (192.35.232.20) by sources.redhat.com with SMTP; 14 Mar 2002 07:50:44 -0000 Received: from austin.ibm.com (netmail1.austin.ibm.com [9.3.7.138]) by mg03.austin.ibm.com (AIX4.3/8.9.3/8.9.3) with ESMTP id BAA15806 for ; Thu, 14 Mar 2002 01:47:08 -0600 Received: from vlad.austin.ibm.com (vlad.austin.ibm.com [9.53.60.118]) by austin.ibm.com (AIX4.3/8.9.3/8.9.3) with ESMTP id BAA37714 for ; Thu, 14 Mar 2002 01:50:42 -0600 Received: (from hzoli@localhost) by vlad.austin.ibm.com (AIX4.3/8.9.3/8.9.3-client1.01) id BAA39836; Thu, 14 Mar 2002 01:50:42 -0600 Message-Id:<200203140750.BAA39836@vlad.austin.ibm.com> Date: Wed, 13 Mar 2002 23:56:00 -0000 From: Zoltan Hidvegi To: gcc-gnats@gcc.gnu.org X-Send-Pr-Version:3.113 Subject: optimization/5959: __attribute__((pure)) ignored on PowerPC AIX X-SW-Source: 2002-03/txt/msg00470.txt.bz2 List-Id: >Number: 5959 >Category: optimization >Synopsis: __attribute__((pure)) ignored on PowerPC AIX >Confidential: no >Severity: serious >Priority: medium >Responsible: unassigned >State: open >Class: pessimizes-code >Submitter-Id: net >Arrival-Date: Wed Mar 13 23:56:01 PST 2002 >Closed-Date: >Last-Modified: >Originator: Zoltan Hidvegi >Release: 3.0.3 20011211 (prerelease) >Organization: >Environment: System: AIX vlad 3 4 0005BA2F4C00 host: powerpc-ibm-aix4.3.3.0 build: powerpc-ibm-aix4.3.3.0 target: powerpc-ibm-aix4.3.3.0 configured with: ../gcc/configure --prefix= --with-local-prefix= --enable-languages=c,c++,java --enable-version-specific-runtime-libs --disable-nls --disable-shared >Description: Looking at the assembly listing generated by gcc it seems that __attributed__((pure)) is ignored on PowerPC AIX, while the same code works on Intel Linux. The sample code below calls foo twice on AIX but only once on Linux. >How-To-Repeat: int foo(int) __attribute__((pure)); int twice_foo(int i) { return foo(i) + foo(i); } >Fix: >Release-Note: >Audit-Trail: >Unformatted: