From patchwork Mon Mar 27 17:33:51 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luc Van Oostenryck X-Patchwork-Id: 9647241 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 5627460328 for ; Mon, 27 Mar 2017 17:38:30 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 48BB7283FF for ; Mon, 27 Mar 2017 17:38:30 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3D92028414; Mon, 27 Mar 2017 17:38:30 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E912128418 for ; Mon, 27 Mar 2017 17:38:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751367AbdC0Rhb (ORCPT ); Mon, 27 Mar 2017 13:37:31 -0400 Received: from mail-wr0-f193.google.com ([209.85.128.193]:34541 "EHLO mail-wr0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751353AbdC0RhM (ORCPT ); Mon, 27 Mar 2017 13:37:12 -0400 Received: by mail-wr0-f193.google.com with SMTP id w43so12461847wrb.1 for ; Mon, 27 Mar 2017 10:36:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=rrQmQ84Vyy1+91fmpTpeLoa1M3o1hZp9Se5OSADzJqM=; b=ZknetmnmgnbQgqWYNMAsRifmlGO3EI9GuuZ9n37h4W4tZ+JcuQj2Gm2bQt/asGhK/P y1T7sRC0q/vcrtVmc6IqC3NSmLi4A0k/HDTOSSut4l8i8yVNh2hyowIgtvDjFWeYGAxR RRQmPe75FJ+Rr9SMTg/6UZTdgCJ/ZSWhts5yciWeQr4eJkSVuVfMsxqnEk2Op6ySs0Ow sHjzUrbRG5xZWSOjbxNQHv0L/bv2cKCwEyRNgPF9ZsAPo+ThNIzdngmaJ3D8c2HROFec REjIN9HOkSlg1QEF9ZuaxrC3MmyQJItvudY3wmyQZg3Dhz6HzW/0O7WutDUlTkneAs3c qX6A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=rrQmQ84Vyy1+91fmpTpeLoa1M3o1hZp9Se5OSADzJqM=; b=GJ2TMLJsi/LSQ5EO4mNVUvbtRCDrB0fRHZa9294BAvxgtaWCBG35rLYnpgVP9MXULz OJpwXkvU2yG+sms2EVFOnC48PciA2CMheVs99Enpl+u7BiGCiOrs4mZV4xWxDMTb+G7s V9oACItLq/GpiypG+F40HDOMdh2vJ4wRYOVndHrge0ymVuwc65CFBK8QG69xDC7IBU5o mRcd1YwVCIpKWugrGrGICbKHY4b0cB3dn9zIzzgSwOBBwQYnswVr1ycAQOnFwyiVfNyc Cu4xGyqShahBTEmgDw6T/lbMMQm/wvcPKZ0KzAk+MnOxLYm+68MaQGwfHYHwPtkRA+9w LUsg== X-Gm-Message-State: AFeK/H0BhDwOmaGIpHxnVy06JXcSSQnBQrfqkxqW9T85k9BXLEvjVcUMFZSIW4D/mu+bZA== X-Received: by 10.223.168.77 with SMTP id l71mr19449985wrc.185.1490636174020; Mon, 27 Mar 2017 10:36:14 -0700 (PDT) Received: from localhost.localdomain ([2a02:a03f:802:b00:496:ae63:aebb:a034]) by smtp.gmail.com with ESMTPSA id e72sm304116wma.5.2017.03.27.10.36.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 27 Mar 2017 10:36:13 -0700 (PDT) From: Luc Van Oostenryck To: linux-sparse@vger.kernel.org Cc: Christopher Li , Luc Van Oostenryck Subject: [PATCH v6 01/15] don't output value of anonymous symbol's pointer Date: Mon, 27 Mar 2017 19:33:51 +0200 Message-Id: <20170327173405.11405-2-luc.vanoostenryck@gmail.com> X-Mailer: git-send-email 2.12.0 In-Reply-To: <20170327173405.11405-1-luc.vanoostenryck@gmail.com> References: <20170327173405.11405-1-luc.vanoostenryck@gmail.com> Sender: linux-sparse-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sparse@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The value of this pointer is of no use unless you're using a debugger (or just to see if two things are identical or not) and it's presence produces noise when comparing the output of two runs for testing. Change this by issuing it only if 'verbose' is set. Signed-off-by: Luc Van Oostenryck --- linearize.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/linearize.c b/linearize.c index 9c2d48aca..7dccf21d8 100644 --- a/linearize.c +++ b/linearize.c @@ -120,7 +120,7 @@ const char *show_pseudo(pseudo_t pseudo) break; } expr = sym->initializer; - snprintf(buf, 64, "", sym); + snprintf(buf, 64, "", verbose ? sym : NULL); if (expr) { switch (expr->type) { case EXPR_VALUE: @@ -328,7 +328,7 @@ const char *show_instruction(struct instruction *insn) buf += sprintf(buf, "%s", show_ident(sym->ident)); break; } - buf += sprintf(buf, "", sym); + buf += sprintf(buf, "", verbose ? sym : NULL); break; }