From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1910 invoked by alias); 30 Apr 2010 20:31:11 -0000 Received: (qmail 1230 invoked by uid 48); 30 Apr 2010 20:30:31 -0000 Date: Fri, 30 Apr 2010 20:31:00 -0000 Message-ID: <20100430203031.1229.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug middle-end/43883] missed optimization of constant __int128_t modulus In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "svfuerst at gmail dot com" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2010-04/txt/msg03397.txt.bz2 ------- Comment #6 from svfuerst at gmail dot com 2010-04-30 20:30 ------- For posterity, I might as well note that with the sbb added on the end we don't need the initial mov instruction if we do some register renaming. This leaves the, hopefully optimal this time, five-instruction fragment as the goal: shr $0x3f,%rsi lea (%rdi,%rsi,1),%rax and $0x1,%eax sub %rsi,%rax sbb %rdx,%rdx -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43883