From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5959 invoked by alias); 9 Oct 2006 12:52:36 -0000 Received: (qmail 5942 invoked by uid 48); 9 Oct 2006 12:52:29 -0000 Date: Mon, 09 Oct 2006 12:52:00 -0000 Subject: [Bug target/29401] New: [regression] missed-optimization (in unneeded code elimination) X-Bugzilla-Reason: CC Message-ID: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "Petr dot Salinger at seznam dot cz" 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 X-SW-Source: 2006-10/txt/msg00700.txt.bz2 List-Id: Hi. There is a regression on i386 platforms. int f(int a, int b) {return (((long long) a) * b) >> 15;} The gcc 4.0/4.1 generates with "-O3 -fomit-frame-pointer" movl 8(%esp), %eax imull 4(%esp) shrdl $15, %edx, %eax sarl $15, %edx ret While gcc-3.3/3.4 generates equal and faster movl 8(%esp), %eax imull 4(%esp) shrdl $15, %edx, %eax ret -- Summary: [regression] missed-optimization (in unneeded code elimination) Product: gcc Version: 4.1.1 Status: UNCONFIRMED Severity: enhancement Priority: P3 Component: target AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: Petr dot Salinger at seznam dot cz GCC host triplet: i486 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29401