Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp5599574ybp; Tue, 8 Oct 2019 05:37:13 -0700 (PDT) X-Google-Smtp-Source: APXvYqyp8LFXpfTYnueyAXZ33Xyjuif1suYb3ZtFIFyJkovXzfulY838pj8cUaxl27/RW6DtCdPh X-Received: by 2002:a50:a41c:: with SMTP id u28mr33640774edb.185.1570538233332; Tue, 08 Oct 2019 05:37:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570538233; cv=none; d=google.com; s=arc-20160816; b=IFBRXNY+AC4Jn8lxeeQJ7g86d5Gmuz/DjyvUHizYh8VRWGzngtZ8jOlyktviz97/0m gd3n6gE/Me5hEsit1AQI2knmXjhvB+361D9vYOICQObDlwtny2FChnV/onv2XRu28C3d E6FsH2sUHFHbmPTtV/40rho3/KT4lGkOlO8t8cVivOC/4Mf/wKHTh6WqmOs5eZ9TJmgr UgvqbH2oqqvD1a2u18WWj/+H9ZvCEdEdc5W/3lLV12yYNEt1M09JYLkjfdZXzhI8MUh3 Jx9RITW+vyQyKLJJOMiEv5wznQV8q+yKh27/tZx7L5/cvH5soCVrrZhPHylAIJsA1hVh G5og== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=Kc2Ivzmz/SqwidGdqpK+CvkXVy5k2Sl1jkfVbY/LHJY=; b=aKpH7MouwtBNKt0JGIRtrYT4+qJJxJHDYf8/IfdEjx7ZEu/ZRe1aXPSSRgl1oKD63W zJzaoq3OXPqPADG5rrb1Iwp2zL9gVkSuUEXDcq5JwFlsh0aCO58R+Ox5ytO7gZKyyuGA 6LMLNWPJ/s52UqUwAd9HtcxZvpjIQR5UKOqFl2tX9c1W7YiZK8rOctRZfpbdvJT6ajgY HZmB8wG9eg6vEHfNk03izJOELf8WGmGvW87f1HFWYlU1GiE+Yfvgpq69mvSLWDLa5dti BnhDTyfinR/kwGpaNdwbkU0qBi/y2/yU/0pKf4bxZ2Cit3A248S5BYQNr4VmLYcAxt99 r67A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="q7SplP/Y"; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g5si7338470ejp.418.2019.10.08.05.36.49; Tue, 08 Oct 2019 05:37:13 -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=@gmail.com header.s=20161025 header.b="q7SplP/Y"; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730915AbfJHMgK (ORCPT + 99 others); Tue, 8 Oct 2019 08:36:10 -0400 Received: from mail-wm1-f67.google.com ([209.85.128.67]:55509 "EHLO mail-wm1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730249AbfJHMgJ (ORCPT ); Tue, 8 Oct 2019 08:36:09 -0400 Received: by mail-wm1-f67.google.com with SMTP id a6so2950525wma.5 for ; Tue, 08 Oct 2019 05:36:08 -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:mime-version :content-transfer-encoding; bh=Kc2Ivzmz/SqwidGdqpK+CvkXVy5k2Sl1jkfVbY/LHJY=; b=q7SplP/Y/2yE40tNY379pmoTEnauF4kpPRy2t/ObYgeynDMhWlZfiMFRIGTUrMwKkL tIC/4SAgt7me05rlP6uVlS7/9YDTCaUBkDhxKEe6CZoQNmeCi+LcAn+KL5jV/N7x+EuH MZP/9SGzmjM+4JOu2k82PxV0Sfmt8J8Pdp8BO1rvNu9Ooq9rH1XECqnBBJUJzVhBaaHu NAcUga0gC577BnN320mwrncTSPpbLjbvCpWlGKHnFSIaWU2n+Bcy2DafGWeaGwI4mID+ O768xU5EMNhRiWvnOSlS1RStSUPbBCYeRc+RU6wXL0MY3ZPrZ/wc3SNtgrkLxrGrwZeK 0EhQ== 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:mime-version :content-transfer-encoding; bh=Kc2Ivzmz/SqwidGdqpK+CvkXVy5k2Sl1jkfVbY/LHJY=; b=OBWZVyLDvc4bfgHpODEFnFQhpwbMnx3QMdCNFxOZ+wo/gY6uiL21KRLiOnFH2cwBZw WAVck6RaW7cZzcNs2ZvRb/DbVp9iiPXQCaNWBgNOnbK6kD9hI/jl387WUokOs8gr9auB SGCrHz7hAXwzrDiFZi3U+b2DtieRvbYJVFpbnblPZHShyAoZSoTolz8tV48eU55LwRXB aV18eSC1Cge/AhEZrUt2rwUljvKoIwSoGBO5suwSHWaKq0dDOlowJ/uNMXH5wwIekyBI ZR6CAPkeL5sV6WFku0DojMactFIqK1+ZH8dQiNr6rzNs9EY3wFnuSAry/B7rmMoYWjU2 wvSQ== X-Gm-Message-State: APjAAAU0fcMLJYmM9c9SsBouf/JDyLxFeW5eku/LUgiwRmjEZPLPEPkf 2MeG5BxEgeL8ClCrCHzbE3g= X-Received: by 2002:a1c:9988:: with SMTP id b130mr3778582wme.164.1570538168133; Tue, 08 Oct 2019 05:36:08 -0700 (PDT) Received: from localhost.localdomain ([104.238.174.53]) by smtp.gmail.com with ESMTPSA id d4sm23100575wrq.22.2019.10.08.05.36.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Oct 2019 05:36:07 -0700 (PDT) From: Changbin Du To: Jiri Olsa , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo Cc: Alexander Shishkin , Namhyung Kim , linux-kernel@vger.kernel.org, Changbin Du Subject: [PATCH v4 0/2] perf: add support for logging debug messages to file Date: Tue, 8 Oct 2019 20:35:52 +0800 Message-Id: <20191008123554.6796-1-changbin.du@gmail.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org When in TUI mode, it is impossible to show all the debug messages to console. This make it hard to debug perf issues using debug messages. This patch adds support for logging debug messages to file to resolve this problem. v4: o fix another segfault. v3: o fix a segfault issue. v2: o specific all debug options one time. Changbin Du (2): perf: support multiple debug options separated by ',' perf: add support for logging debug messages to file tools/perf/Documentation/perf.txt | 15 ++-- tools/perf/util/debug.c | 124 ++++++++++++++++++++---------- 2 files changed, 91 insertions(+), 48 deletions(-) -- 2.20.1