Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp967510ybz; Wed, 29 Apr 2020 12:35:13 -0700 (PDT) X-Google-Smtp-Source: APiQypI9J76ARPvTLz/IS3nEHof+aNsrrjAcs5JooMGMyTXyGf8p3eEMD4PQA2HWTUxGpHhfHYdH X-Received: by 2002:aa7:d514:: with SMTP id y20mr4070729edq.28.1588188913403; Wed, 29 Apr 2020 12:35:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588188913; cv=none; d=google.com; s=arc-20160816; b=jalOO/AF6D3SzChrECNr/xmU89mi03zydgMfxkJui1VsLIx8Zbc4WYA5qGox/1j6yR xNqEsLBSQqNI7hWMzYF/WXZYu2f0Wp+CQ6uU9ECSpNLpG41loUmXDao/rrG37ZeBjxXH xu4KbBNfbdO9pB8ksmozo40WYD1a7m3yEtJMClIxMATKk69dSkebsAVUD7byEGMoAp0Y glkOYKDjn32wVpN5x+vrPvetxsrxEvg7b5Os6uK8a7mNqcdSh0tht6Rc4StCHJi7vJky PFPUYOfBp1UmSwLRlGWzL6giu2NLQGcaaZvYqoE490V0KpPlvWLppyBZl0TAA9/Y+hWk j8gg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=vrgxe9ifjEnyPmXmvPhvUyY/XI0D3egtea2Iq4Vnzx8=; b=MHvzfLYUWAHasbM5+0QjWzByS65mRQVWUXIXjrEEnZtH8GcnZdg9ns66zk8/af0wsW TGQNNAs7akeowUWH6TEI6JT2pwcwDZZebF0Ml0qpJGSD7vWJYkHlg+/SCzMKTh7Wq+dM hVsV5DDnUhrliY+6z15kvnT6mG2Z+b7oR78CbpWBLi8jUwKEpF6fRQZRgqFdHDzT5d7y +AWSgTBVVj2Fs+69lInJmN8+Iz/vp5gtS3D7A2ELUU9Cwpop21zaKRhP5jyx+Gfy57jb zVvylg1zuq/im+4WOxtjmAQJEcnV5pX0VZW7n2CqOZtc3p+s6u8gal6UIArv5YBIm0Us iTPw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=dI1whMTa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c3si4160784eja.251.2020.04.29.12.34.48; Wed, 29 Apr 2020 12:35:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=dI1whMTa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726822AbgD2Tcv (ORCPT + 99 others); Wed, 29 Apr 2020 15:32:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52676 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1726554AbgD2Tcu (ORCPT ); Wed, 29 Apr 2020 15:32:50 -0400 Received: from mail-vs1-xe41.google.com (mail-vs1-xe41.google.com [IPv6:2607:f8b0:4864:20::e41]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B4BCEC03C1AE for ; Wed, 29 Apr 2020 12:32:50 -0700 (PDT) Received: by mail-vs1-xe41.google.com with SMTP id s11so2196042vsm.3 for ; Wed, 29 Apr 2020 12:32:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=vrgxe9ifjEnyPmXmvPhvUyY/XI0D3egtea2Iq4Vnzx8=; b=dI1whMTatmml5O41FPYCNwjpGiABq/GMGOrZM3DUvNHp7OltmJ9mTgz5r2xW9wlUtW gwYSrlEfK3RKwDSjYkvUcOYZIbLmqZcnCY7wT5UKmT7J44EzyFoBGAfkoqpZoXxVIYnC BvFmsLJDRF0nOnK9yACo3R2P8pzqK88vM/vAxx0eeR8tMnGTcpoIKUit129f7zjiatxk IUUz3jqHazCvR+k+CJGxpFzL+uho2N6srSoIzzlEiMlkaCK93VQZP5LtErQHEpuQKGLy QBPgsYpytDwHnDJnkika3fg+74jJoDciriL01Wc/BS0cJ5b8Yv1xiNw9euYmmY5ZlF7+ Fs9g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=vrgxe9ifjEnyPmXmvPhvUyY/XI0D3egtea2Iq4Vnzx8=; b=lkqkiegNJWi/iVSjVdvF+8l32VKd3oGSvCc2T8PsiYgPfFtbFZBnB2WYV54yklO+et caQx0r8q84qY1Q/g1kxn6QM5jahMrHL85mHTwb+Ezzy5EFr6Q21SPhR+n0DIHqID1bD6 A7ug2i5osMxuoXBjeTob5nwh9blpiLqecBoyi+7AKQCOTClfAMDJ++v0VqEaJjwPP7b5 T+cd5aXyH+NhQpZf0Rmv5EXFPoYp3TE+pjrlxTC8zgna4k10pK8JR5QL0J7TGu/zX0QY m85cT/d0FlHa7jMm7fddwSAyETWs0OAqKbZXIr6g7FpZNcTFMBCJOxPvRwGFnaKL/jhL lehQ== X-Gm-Message-State: AGi0PuYqXluov3g+qrDTVaa4nqpIm2QU9w5nLltcQ2wo6YFzO0NG/n1U rq/8EBmtry8cqgLzD7kKDb2IWGLlAOr8b7byP5y/63L0 X-Received: by 2002:a67:ffcf:: with SMTP id w15mr4867058vsq.213.1588188769592; Wed, 29 Apr 2020 12:32:49 -0700 (PDT) MIME-Version: 1.0 References: <20200418231908.152212-1-eranian@google.com> <20200428024744.GA703870@tassilo.jf.intel.com> In-Reply-To: <20200428024744.GA703870@tassilo.jf.intel.com> From: Stephane Eranian Date: Wed, 29 Apr 2020 12:32:38 -0700 Message-ID: Subject: Re: [PATCH] perf/script: remove extraneous newline in perf_sample__fprintf_regs() To: Andi Kleen Cc: LKML , Peter Zijlstra , mingo@elte.hu, Arnaldo Carvalho de Melo , Jiri Olsa , Ian Rogers , "Liang, Kan" Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Apr 27, 2020 at 7:47 PM Andi Kleen wrote: > > On Sat, Apr 18, 2020 at 04:19:08PM -0700, Stephane Eranian wrote: > > When printing iregs, there was a double newline printed because > > perf_sample__fprintf_regs() was printing its own and then at the > > end of all fields, perf script was adding one. > > This was causing blank line in the output: > > I don't think the patch is quite correct because there could be > other fields after it, and they need to be separated by a > new line too. > > e.g. i suspect if someone prints iregs,uregs or iregs,brstack > or something else that is printed in process_event after *regs > you would get garbled output. > I was under the impression that perf script was generating one line per sample. Otherwise, seems hard to parse. Could you give me the cmdline options of perf script that justify the newline. Thanks. > So you have to track if the newline is needed or not. > > -Andi