From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23938 invoked by alias); 24 May 2003 01:32:29 -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 23925 invoked from network); 24 May 2003 01:32:29 -0000 Received: from unknown (HELO monty-python.gnu.org) (199.232.76.173) by sources.redhat.com with SMTP; 24 May 2003 01:32:29 -0000 Received: from to-telus.redhat.com ([207.219.125.105] helo=touchme.toronto.redhat.com) by monty-python.gnu.org with esmtp (Exim 4.20) id 19JNet-0006FJ-K5 for gcc@gcc.gnu.org; Fri, 23 May 2003 21:17:15 -0400 Received: from localhost (tornado.toronto.redhat.com [172.16.14.228]) by touchme.toronto.redhat.com (Postfix) with ESMTP id 2A8FB8000E5; Fri, 23 May 2003 21:14:00 -0400 (EDT) Subject: [tree-ssa] FE dropping volatile qualifier? From: Diego Novillo To: "gcc@gcc.gnu.org" Cc: Jason Merrill Content-Type: text/plain Organization: Red Hat Canada Message-Id: <1053738824.6937.165.camel@frodo.toronto.redhat.com> Mime-Version: 1.0 Date: Sat, 24 May 2003 01:36:00 -0000 Content-Transfer-Encoding: 7bit X-SW-Source: 2003-05/txt/msg02163.txt.bz2 The patch for removing INDIRECT_REF nodes is causing several mudflap failures. The problem is that these tests tend to have trivially dead code. For instance, testsuite/libmudflap.c/fail13-frag.c: int main () { (*((struct a*) &k)).z = 'q'; return 0; } A few days ago, I "fixed" these cases by adding volatile, but we seem to be removing that qualifier at some point in the parser. If I change the line above to "(*((volatile struct a*) &k)).z = 'q'", we get the following out of the parser (before gimplification): int main () { ((struct a *)&k)->z = 113; return 0; } Notice that volatile is now gone. I'm not very proficient with language issues, but shouldn't the volatile bit be kept? The SSA optimizers honor the volatile qualifier, but the FE is apparently removing it. Thanks. Diego.