From patchwork Wed Jan 25 18:44:50 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kai Tietz X-Patchwork-Id: 137822 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 1D006B6F6F for ; Thu, 26 Jan 2012 05:45:10 +1100 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1328121911; h=Comment: DomainKey-Signature:Received:Received:Received:Received: MIME-Version:Received:Received:Date:Message-ID:Subject:From:To: Cc:Content-Type:Mailing-List:Precedence:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:Sender:Delivered-To; bh=Ucr0nnK 9qsL4c+3hb577Ri12MTA=; b=vkBuWEiUblMPf0D9FjHGj26pnjUL7O7f94M4lIc mwgDQ/zMOHVzJWvoMMXHrfBL7qkeIa1Fa00/cVaQcBF0VGrufFSPcjNFv3rewRxR vUMeSbo8P10l8K8xvwchevXqNCqV7VpN9eBNCYmIbVO9y0FnQM7E3vi7uw0G4IZz Q/VU= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:MIME-Version:Received:Received:Date:Message-ID:Subject:From:To:Cc:Content-Type:X-IsSubscribed:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=CrDKzeqfEgUpHvDMa0Rmofc5G8hZAJhGjNxAPXACHO+Zp0Lk7dvPy/wG44zvsG EOXMdY94rYI+WlIfwfOhJHuRY+8Ji+hNL6GlZ8PDSyS2FQUU7y1DoLY6kGjqTdh2 LKqTPpn4Gu11NEDA0MvkcRgddOtcHSr4QYcHVVY8lX41g=; Received: (qmail 19060 invoked by alias); 25 Jan 2012 18:45:05 -0000 Received: (qmail 19050 invoked by uid 22791); 25 Jan 2012 18:45:04 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, TW_IB X-Spam-Check-By: sourceware.org Received: from mail-tul01m020-f175.google.com (HELO mail-tul01m020-f175.google.com) (209.85.214.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 25 Jan 2012 18:44:51 +0000 Received: by obbuo9 with SMTP id uo9so6683201obb.20 for ; Wed, 25 Jan 2012 10:44:50 -0800 (PST) MIME-Version: 1.0 Received: by 10.182.59.13 with SMTP id v13mr16673909obq.74.1327517090443; Wed, 25 Jan 2012 10:44:50 -0800 (PST) Received: by 10.182.60.232 with HTTP; Wed, 25 Jan 2012 10:44:50 -0800 (PST) Date: Wed, 25 Jan 2012 19:44:50 +0100 Message-ID: Subject: [patch tree-eh]: Fix bootstrap issue for libjava for 32-bit mingw target From: Kai Tietz To: GCC Patches Cc: Richard Guenther X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Hi, the following patch fixes a bootstrap issue for libjava (compile of verify.cc ICEs). It is caused by the assumption that a GIMPLE_COND lhs side has always a type. This isn't necessarily true, but it has by default boolean_type_node as type. ChangeLog 2012-01-25 Kai Tietz * tree-eh.c (stmt_could_throw_1_p): If type of lhs for a GIMPLE_COND isn't set, use boolean_type_node. Bootstrapped for x86_64-unknown-linux-gnu, and i686-w64-mingw32. Ok for apply? Regards, Kai Index: tree-eh.c =================================================================== --- tree-eh.c (revision 183524) +++ tree-eh.c (working copy) @@ -2583,9 +2583,14 @@ && TREE_CODE_CLASS (code) == tcc_comparison) t = TREE_TYPE (gimple_assign_rhs1 (stmt)); else if (gimple_code (stmt) == GIMPLE_COND) - t = TREE_TYPE (gimple_cond_lhs (stmt)); + { + t = TREE_TYPE (gimple_cond_lhs (stmt)); + if (t == NULL_TREE) + t = boolean_type_node; + } else - t = gimple_expr_type (stmt); + t = gimple_expr_type (stmt); + fp_operation = FLOAT_TYPE_P (t); if (fp_operation) {