From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5420 invoked by alias); 29 Sep 2004 19:39:47 -0000 Mailing-List: contact java-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: java-prs-owner@gcc.gnu.org Received: (qmail 5402 invoked by uid 48); 29 Sep 2004 19:39:47 -0000 Date: Wed, 29 Sep 2004 19:39:00 -0000 Message-ID: <20040929193947.5399.qmail@sourceware.org> From: "rth at gcc dot gnu dot org" To: java-prs@gcc.gnu.org In-Reply-To: <20040929175802.17731.tromey@gcc.gnu.org> References: <20040929175802.17731.tromey@gcc.gnu.org> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug rtl-optimization/17731] sub-optimal code generated for left shift X-Bugzilla-Reason: CC X-SW-Source: 2004-q3/txt/msg00734.txt.bz2 List-Id: ------- Additional Comments From rth at gcc dot gnu dot org 2004-09-29 19:39 ------- This will be done properly if SHIFT_COUNT_TRUNCATED is true. The problem is that SHIFT_COUNT_TRUNCATED applies to *all* shifts and at the given mode size. Which is not true for x86, since HImode shifts are still masked to 31, not 15. Ideally we'd extend Richard Sandiford's new target.shift_truncation_mask such that it can replace SHIFT_COUNT_TRUNCATED. In the short term, Java could examine shift_truncation_mask and avoid creating the AND at the tree level in the first place. Not sure whether "middle-end" or "rtl-opt" is a better category, but this is definitely not target-specific and thus "target" doesn't apply. -- What |Removed |Added ---------------------------------------------------------------------------- Component|target |rtl-optimization http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17731