From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20524 invoked by alias); 23 Mar 2004 20:12:57 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 20514 invoked by uid 48); 23 Mar 2004 20:12:57 -0000 Date: Tue, 23 Mar 2004 20:12:00 -0000 Message-ID: <20040323201257.20513.qmail@sources.redhat.com> From: "pinskia at gcc dot gnu dot org" To: gcc-bugs@gcc.gnu.org In-Reply-To: <20040318034843.14627.dann@godzilla.ics.uci.edu> References: <20040318034843.14627.dann@godzilla.ics.uci.edu> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug optimization/14627] [tree-ssa] extra assignment inserted on the tree level X-Bugzilla-Reason: CC X-SW-Source: 2004-03/txt/msg02796.txt.bz2 List-Id: ------- Additional Comments From pinskia at gcc dot gnu dot org 2004-03-23 20:12 ------- The reason for the changing *a to a gets rid of the assignenment is because DOM does not work through &&. Here is a testcase without the && (and is reproducable with a): int foo (int a, int b) { int i; _Bool c = 0; for (i = 0; i < 10; i++) { if (a) if (b) goto done; if (!c){ if (a) c = 1; } /*else c = 0;*/ //Basically DOM is adding this statement as it knows that c == 0 at this point // so it added it to the PHI as 0. } done: return c; } -- What |Removed |Added ---------------------------------------------------------------------------- CC| |pinskia at gcc dot gnu dot | |org Severity|normal |enhancement Keywords| |pessimizes-code Summary|[tree-ssa] extra assignment |[tree-ssa] extra assignment |inserted |inserted on the tree level http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14627