From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pl1-f197.google.com (mail-pl1-f197.google.com [209.85.214.197]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B5D5034752D for ; Sun, 9 Aug 2026 05:18:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.197 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786252706; cv=none; b=MjzNWhX+7pOImymXyoopsiOgVM5uKbDfumc2Pfk4O3hrdB96Z1rwUIh7tIkZSXN+EWLTS8oJm3bKp0vP9bbvvdqIx4lVo4IYiSy/OEcHDilKNS0eCv5UNn2od9QBoq4SfrkOk/uAmixVjw8J3w0zPkkGhi/rWvUslH9QJWRLrro= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786252706; c=relaxed/simple; bh=1f4SAfL/iH3VUl4bBcVnrLTKhHsC68BlN+4jz3pNqW8=; h=Date:In-Reply-To:Mime-Version:References:Message-ID:Subject:From: To:Cc:Content-Type; b=uupmgMqqy3QAQ+elW10FNh7aP7q1ZR3mAut10bbZ0lSsbAbLEt6GtusFk3zgXPr41TI9iPWdWUoskyL14mJEdK0hiezQ6/vrji5r+NSGbtIHcQEfU3LNRqkD4c9u0OZeuoRW16WDVF3HpyWxOzXwOp5Ll+9loZl+ubcebRaJEdc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--irogers.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=Lxbt1q7B; arc=none smtp.client-ip=209.85.214.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--irogers.bounces.google.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="Lxbt1q7B" Received: by mail-pl1-f197.google.com with SMTP id d9443c01a7336-2cfa55c9430so9012365ad.0 for ; Sat, 08 Aug 2026 22:18:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20251104; t=1786252704; x=1786857504; darn=vger.kernel.org; h=content-type:cc:to:from:subject:message-id:references:mime-version :in-reply-to:date:from:to:cc:subject:date:message-id:reply-to :content-type; bh=pSe2XCOqapMcKw3TgudQ6h4GJ1YS3LXbzUXugkTsEr8=; b=Lxbt1q7BERM0mDmap8TvyjL5RfovJhfVkQDLkSPbg27B/kr026SEWL4DHshVH09HnK ZXE6av7bfJ9I0WVPtv+C7r45aEHUM2P51yLBmq+S6e1XVvTRof2Sw5pq1CGTorH7ZaF1 cYdRbwPz8H7p+ISJrIrktg5V39VhYYqPgVcwJXYyzJSUNbQ8Qhrb4ZYck5Ov67Tvf2lx OgLd3FnvoOLYEBVe0z4LZxQ3tMjv/51jcEgz2gm23zzC7RVfiWkeC0iGj7kthCyyp78x 1FB/au+HJcwjJ4wWxUdgLQrRkcsnQe8dE6iLX6ENdlbmoEbEcArd9cOHwQCqerhGD3m7 9dzg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1786252704; x=1786857504; h=content-type:cc:to:from:subject:message-id:references:mime-version :in-reply-to:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=pSe2XCOqapMcKw3TgudQ6h4GJ1YS3LXbzUXugkTsEr8=; b=L5V89jk8fJco7Y6ZCJc4bok4wWc8zwt7NjpSaK16rHxiNGDSirRvzPdrPapDdDUFUW BLW+FfeJoijbOP0xcU9FPsB044VFIyfXQBPEbHMUBUTLOPP50FlWX4svnZIDadUw9+D0 q5V8qebR5lsAvP85afMFSpCobYm98j5j0TwnPZ9JgdUdioBSJgJ7lE3T1sndQ6AlF3en o+XiYoTkkatzfHWqDWbZoGF8Atsiyq2yPG9r1Mnf83aT8k+2BpJXLwAWIVirS0bNjkSd KDNOtLKHTN2MxdRts7Nc+u65ZghlLYEw7+eKQxb6wMzXXtWE0bwix9R4I21Taktn5QAf VeZA== X-Forwarded-Encrypted: i=1; AHgh+RrNfTnow2e2G9KoarqelqtyTQnOffWNV/ngTl7xWakglVFdK0cZy8dwgrnAzV7pUv6DEUQutbVjMPnPoBI=@vger.kernel.org X-Gm-Message-State: AOJu0Yxx/+JcHULMhBjKQsMUelfmI3MkF+brVsyGMVQgiWCIJbDChKmQ msZjtODzX5WempEodD38WliH+ZU1XNXY0QUzrWkXWKCdPnd+zvn9eqZpyGbSG6yt57Bj0JfTWCq OqEY0q+iS1g== X-Received: from dled17-n1.prod.google.com ([2002:a05:701b:42d1:10b0:13b:2a58:e5fa]) (user=irogers job=prod-delivery.src-stubby-dispatcher) by 2002:a17:90a:d885:b0:381:973e:fa08 with SMTP id 98e67ed59e1d1-3928242e8cemr11025060a91.18.1786252703515; Sat, 08 Aug 2026 22:18:23 -0700 (PDT) Date: Sat, 8 Aug 2026 22:18:17 -0700 In-Reply-To: <20260809041638.2402705-1-irogers@google.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 References: <20260809041638.2402705-1-irogers@google.com> X-Mailer: git-send-email 2.55.0.654.g21b8a5bc05-goog Message-ID: <20260809051820.2436530-1-irogers@google.com> Subject: [PATCH v4 0/2] perf python TUI report and flamegraph From: Ian Rogers To: irogers@google.com, acme@kernel.org, alice.mei.rogers@gmail.com, namhyung@kernel.org Cc: adrian.hunter@intel.com, jolsa@kernel.org, laixintaoo@gmail.com, linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org, mingo@redhat.com, peterz@infradead.org Content-Type: text/plain; charset="UTF-8" Implement a perf TUI using the python textual module. Using the textual framework means that in most modern terminals the mouse is supported, the color scheme can be configured, and screenshots made. The work is dependent on the extensions to the perf python module merged into perf-tools-next such as commit 88439191ad5e ("perf python: Add callchain support"). It is also dependent on the python textual module for TUI support. v4: Fix typo of profle to profile and tweak argparse command description to only mention flamegraph after that support is added (Sashiko). Sashiko notes a high severity issue because the script depends on perf Python module extensions that are already merged. This is because Sashiko is testing the changes against the perf-tools rather than perf-tools-next. Verified rich.errors.MarkupError don't occur for kernel DSOs, primarily as there is always a space after the square brackets. v3: Tweaks to commit messages (Sashiko). https://lore.kernel.org/linux-perf-users/20260809041638.2402705-1-irogers@google.com/ v2: Migrate from inbuilt perf python interpreter to perf python module. Improve the flamegraph performance. Use the textual's color scheme rather than red and white. https://lore.kernel.org/linux-perf-users/20260808065743.2328212-1-irogers@google.com/ v1: https://lore.kernel.org/linux-perf-users/20250725082425.20999-1-irogers@google.com/ Alice Rogers (2): perf python: New treport script perf python: treport add flamegraph support tools/perf/python/treport.py | 561 +++++++++++++++++++++++++++++++++++ 1 file changed, 561 insertions(+) create mode 100755 tools/perf/python/treport.py -- 2.55.0.654.g21b8a5bc05-goog