From patchwork Tue Oct 30 21:01:28 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steven Bosscher X-Patchwork-Id: 195624 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 F136F2C0097 for ; Wed, 31 Oct 2012 08:02:15 +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=1352235736; h=Comment: DomainKey-Signature:Received:Received:Received:Received:Received: MIME-Version:Received:From:Date:Message-ID:Subject:To: Content-Type:Mailing-List:Precedence:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:Sender:Delivered-To; bh=i0ZDqYG FfpEZO//rmnpMZG4WO+k=; b=aOwFe92Peg7nSbgmDOxcFG2FcjLeZ7+mAoHKsqz HcN2vsUeqEK0H3I3HA/8tKg5SvWqKb9cQmJhH0Y3pGhy9hvovCxIH/jnRfLA58i4 8Ol3eHhBInD6ax6pBT4To+U2EzIvenFfu8d0lKnygHTvuxaQSLsV7cq6Cu1VhM5A UedU= 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:Received:MIME-Version:Received:From:Date:Message-ID:Subject:To:Content-Type:X-IsSubscribed:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=byDy5EY6ocmXj500mOqrQDD+8H1raaigjNBuFcLwuBhZ6V2v3QPWl9tcok6eVI dhpWlEMemLwQmo2eOGvqXUou2GBA0vQQxbVK2TW6bwUFAxbADVp93wY3Et8zHSQ6 kwhhLXIVDGEtKay7QpzusSWUuXLXhExZXfF7r/PkPuotc=; Received: (qmail 22741 invoked by alias); 30 Oct 2012 21:02:02 -0000 Received: (qmail 22709 invoked by uid 22791); 30 Oct 2012 21:01:57 -0000 X-SWARE-Spam-Status: No, hits=-4.4 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, KHOP_RCVD_TRUST, RCVD_IN_DNSWL_LOW, RCVD_IN_HOSTKARMA_YE X-Spam-Check-By: sourceware.org Received: from mail-lb0-f175.google.com (HELO mail-lb0-f175.google.com) (209.85.217.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 30 Oct 2012 21:01:50 +0000 Received: by mail-lb0-f175.google.com with SMTP id y2so585175lbk.20 for ; Tue, 30 Oct 2012 14:01:48 -0700 (PDT) Received: by 10.152.103.100 with SMTP id fv4mr31183938lab.39.1351630908867; Tue, 30 Oct 2012 14:01:48 -0700 (PDT) MIME-Version: 1.0 Received: by 10.112.88.99 with HTTP; Tue, 30 Oct 2012 14:01:28 -0700 (PDT) From: Steven Bosscher Date: Tue, 30 Oct 2012 22:01:28 +0100 Message-ID: Subject: [patch] Handle NULL in slim RTL dumps of patterns To: GCC Patches 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 Hello, NULL patterns happen in some REG_NOTEs. Will commit as obvious in a bit... Ciao! Steven * sched-vis.c (print_pattern): Handle NULL patterns. Index: gcc/sched-vis.c =================================================================== --- gcc/sched-vis.c (revision 192992) +++ gcc/sched-vis.c (working copy) @@ -568,6 +568,11 @@ print_pattern (char *buf, const_rtx x, int verbose { char t1[BUF_LEN], t2[BUF_LEN], t3[BUF_LEN]; + if (! x) + { + sprintf (buf, "(nil)"); + return; + } switch (GET_CODE (x)) { case SET: