Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp2779516yba; Sat, 18 May 2019 02:48:41 -0700 (PDT) X-Google-Smtp-Source: APXvYqyoRe/uNaA2MVkLv0LR9mMFPU9ytjOEG3EN5ucX30nivcL2kWh6Xb9Ste7UlaA75nlW3poZ X-Received: by 2002:a17:902:b095:: with SMTP id p21mr11005019plr.270.1558172921270; Sat, 18 May 2019 02:48:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1558172921; cv=none; d=google.com; s=arc-20160816; b=xwpVZMPMA37SJ/ZwpSNsKef6yar1mvdWwysmjuY/S8Inr52vPJadoSzHZnCkx4Gn1G oYBIrEdV+1IkdJpz+lG+3FR6ou4eOqjIGvI52PyRhOqFzOaVvwSr+5ClQd3PeFUR4dlQ 3ntBKXMmZQPxOsDSb3ey6e3eoJVSCi0eRBnze8gUJUuaY8mZE3o+Pl8WE0GCu+keO6i+ Nj6q1wwlfUb8qGSLzavHbkcWD+7731RhmyWcMipakMBD76mQaaztz9UzOILF3io7jpBS 4lNb3fDzoGAwiy+y5aexqMIiGoK76zMJg6sVqom6/pRT/dgTUH07FEhx7WQAxVHhCwkT vr9Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-disposition :content-transfer-encoding:mime-version:robot-unsubscribe:robot-id :git-commit-id:subject:to:references:in-reply-to:reply-to:cc :message-id:from:date:dkim-signature:dkim-filter; bh=p8hGlLyY5wcMoY8I+WtQuDpq4NxU2FyKw+//UsXP2uk=; b=CDxezxH9a9PX2C95aUItsOwSkIMw6NInnuEgE4PKnbMaycNVqWvZsmoFmjLtk22tSo m2BT016pjuN9KzugzjkAf2N+1rwSW8NPVT06wSd5s1Ndx07T/Xb9ZbAcPFtM2bG7xqnc fKdaKc9gO8G0O2GqEuMn18m68fuCdoOLK2vXTf1FuCbUYzlqUp11lFUDZjqEDEtuVwSg DAIJHptiyxTkPeeaV8pfYqkrchbYDd9uolwIAs1qQSSFCBSIY1YAOJiwNMao36IzmGQb OENEJRFl9Ty+YlPIV5MCXBPltnS952zU5z7zITtJJ/6KGHsVsHyAkkC1GkH5agBHorBP 4KrA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@zytor.com header.s=2019041745 header.b=IFM4m5wN; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=zytor.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f3si11069514pgs.135.2019.05.18.02.48.26; Sat, 18 May 2019 02:48:41 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@zytor.com header.s=2019041745 header.b=IFM4m5wN; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=zytor.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729921AbfERJ0G (ORCPT + 99 others); Sat, 18 May 2019 05:26:06 -0400 Received: from terminus.zytor.com ([198.137.202.136]:42335 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725268AbfERJ0F (ORCPT ); Sat, 18 May 2019 05:26:05 -0400 Received: from terminus.zytor.com (localhost [127.0.0.1]) by terminus.zytor.com (8.15.2/8.15.2) with ESMTPS id x4I9PsAQ1741268 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Sat, 18 May 2019 02:25:54 -0700 DKIM-Filter: OpenDKIM Filter v2.11.0 terminus.zytor.com x4I9PsAQ1741268 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zytor.com; s=2019041745; t=1558171555; bh=p8hGlLyY5wcMoY8I+WtQuDpq4NxU2FyKw+//UsXP2uk=; h=Date:From:Cc:Reply-To:In-Reply-To:References:To:Subject:From; b=IFM4m5wNRTNLZEB49wLcBOBO125af0unSP8WpCrTCRLNL8geFLBoIcUAQtBAB975D tYdwEhYb4cm94VhsmReUSahQjJ13ZZvGbdwNWPFSPpk3W+zSz+ejwQdHz/tEfqF0jN f+dSjqzc7ZhAubP1h8FK/I0LWbs33iksDaIIyhSV7wr2N04ldIBiTnT/dsOH395/W1 08TeFLh0NHaQFYtEk83ZnNf2GP8vddYACHetlT9ByjC6xVcqt/IkqoP1GDGlZccx96 KLq1U50nkG81rdlgacPAf81kO5+bRspSJoET3QzMlnkUNChBcLB2dCSjfjS4fVx26o zidQSS6b+CArQ== Received: (from tipbot@localhost) by terminus.zytor.com (8.15.2/8.15.2/Submit) id x4I9Pr2T1741265; Sat, 18 May 2019 02:25:53 -0700 Date: Sat, 18 May 2019 02:25:53 -0700 X-Authentication-Warning: terminus.zytor.com: tipbot set sender to tipbot@zytor.com using -f From: tip-bot for Alexey Budankov Message-ID: Cc: jolsa@kernel.org, peterz@infradead.org, acme@redhat.com, hpa@zytor.com, ak@linux.intel.com, mingo@kernel.org, alexander.shishkin@linux.intel.com, linux-kernel@vger.kernel.org, alexey.budankov@linux.intel.com, tglx@linutronix.de, namhyung@kernel.org Reply-To: namhyung@kernel.org, linux-kernel@vger.kernel.org, alexander.shishkin@linux.intel.com, mingo@kernel.org, alexey.budankov@linux.intel.com, tglx@linutronix.de, ak@linux.intel.com, peterz@infradead.org, jolsa@kernel.org, hpa@zytor.com, acme@redhat.com In-Reply-To: References: To: linux-tip-commits@vger.kernel.org Subject: [tip:perf/core] perf inject: Enable COMPRESSED record decompression Git-Commit-ID: 371a3378d83a755add84b2dca730a3a641002f3a X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline X-Spam-Status: No, score=-3.1 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, T_DATE_IN_FUTURE_96_Q autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on terminus.zytor.com Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: 371a3378d83a755add84b2dca730a3a641002f3a Gitweb: https://git.kernel.org/tip/371a3378d83a755add84b2dca730a3a641002f3a Author: Alexey Budankov AuthorDate: Mon, 18 Mar 2019 20:45:44 +0300 Committer: Arnaldo Carvalho de Melo CommitDate: Wed, 15 May 2019 16:36:49 -0300 perf inject: Enable COMPRESSED record decompression Initialized decompression part of Zstd based API so COMPRESSED records would be decompressed into the resulting output data file. Signed-off-by: Alexey Budankov Reviewed-by: Jiri Olsa Cc: Alexander Shishkin Cc: Andi Kleen Cc: Namhyung Kim Cc: Peter Zijlstra Link: http://lkml.kernel.org/r/c27d7500-ecdd-3569-cab5-8f70bbed5ea4@linux.intel.com Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/builtin-inject.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/perf/builtin-inject.c b/tools/perf/builtin-inject.c index 24086b7f1b14..8e0e06d3edfc 100644 --- a/tools/perf/builtin-inject.c +++ b/tools/perf/builtin-inject.c @@ -837,6 +837,9 @@ int cmd_inject(int argc, const char **argv) if (inject.session == NULL) return -1; + if (zstd_init(&(inject.session->zstd_data), 0) < 0) + pr_warning("Decompression initialization failed.\n"); + if (inject.build_ids) { /* * to make sure the mmap records are ordered correctly @@ -867,6 +870,7 @@ int cmd_inject(int argc, const char **argv) ret = __cmd_inject(&inject); out_delete: + zstd_fini(&(inject.session->zstd_data)); perf_session__delete(inject.session); return ret; }