From patchwork Wed Jun 19 08:15:04 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Biener X-Patchwork-Id: 252516 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]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "localhost", Issuer "www.qmailtoaster.com" (not verified)) by ozlabs.org (Postfix) with ESMTPS id 2763F2C0350 for ; Wed, 19 Jun 2013 18:15:14 +1000 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:subject:message-id:mime-version:content-type; q=dns; s= default; b=JTqnRIqko0jK8ldtcfWESCTJYElYwAgqSGonRoCeBO8huD2YmF94y +I8SMqULr2u3xGW6FOSk3eXZlDiTxUNos0ePnbl1XH3NcKNigMbZtmB+DBtFC0GM uJIOioaYmlEJPPAx2zQ70aE1lb//CN8D63PLkiP++ZQ+VbBpStcTvM= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:subject:message-id:mime-version:content-type; s= default; bh=v49b0jeLFjlhWdTCaopX1UhJFMg=; b=lsvLQVUB6FDWFRfPlxzS MWX+CJQrJEl03t+stIwGjnp2IWjgp6Pqj8LC0XwP5mgD7/9z1XohmgPhLwMfG/fq NdIeDlavxDWnJV46uO74S/9LDwyv/+mOipNFKvkMbfo4XjGIlDpnIMe9ohAOnLIR RWaE3FNVoyaJUY3LcaWIj5w= Received: (qmail 6631 invoked by alias); 19 Jun 2013 08:15:08 -0000 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 Received: (qmail 6620 invoked by uid 89); 19 Jun 2013 08:15:07 -0000 X-Spam-SWARE-Status: No, score=-5.7 required=5.0 tests=AWL, BAYES_00, KHOP_RCVD_UNTRUST, RCVD_IN_HOSTKARMA_W, RCVD_IN_HOSTKARMA_WL, RP_MATCHES_RCVD autolearn=ham version=3.3.1 Received: from cantor2.suse.de (HELO mx2.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Wed, 19 Jun 2013 08:15:07 +0000 Received: from relay1.suse.de (unknown [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id DB5C9A4EB7 for ; Wed, 19 Jun 2013 10:15:04 +0200 (CEST) Date: Wed, 19 Jun 2013 10:15:04 +0200 (CEST) From: Richard Biener To: gcc-patches@gcc.gnu.org Subject: [PATCH] Fix LTO kernel build ICE Message-ID: User-Agent: Alpine 2.00 (LNX 1167 2008-08-23) MIME-Version: 1.0 As reported by Andi the following trivial fix fixes the ICE. Committed as obvious. Richard. 2013-06-19 Richard Biener * expr.c (expand_expr_real_1): Use SCOPE_FILE_SCOPE_P to check for global context. Index: gcc/expr.c =================================================================== --- gcc/expr.c (revision 200189) +++ gcc/expr.c (working copy) @@ -9353,7 +9353,7 @@ expand_expr_real_1 (tree exp, rtx target /* Variables inherited from containing functions should have been lowered by this point. */ context = decl_function_context (exp); - gcc_assert (!context + gcc_assert (SCOPE_FILE_SCOPE_P (context) || context == current_function_decl || TREE_STATIC (exp) || DECL_EXTERNAL (exp)