From 8368e1d58c1c479a9827b8fe150ce2461c445c22 Mon Sep 17 00:00:00 2001 From: amorimur <68889783+amorimur@users.noreply.github.com> Date: Fri, 22 Apr 2022 16:14:20 -0700 Subject: [PATCH] Update flamegraph.pl Add padding to make sure subtitle can be seen in an icicle graph --- flamegraph.pl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/flamegraph.pl b/flamegraph.pl index 9b9898e5..e9db1c69 100755 --- a/flamegraph.pl +++ b/flamegraph.pl @@ -1171,7 +1171,9 @@ sub flow { $y2 = $imageheight - $ypad2 - $depth * $frameheight; } else { $y1 = $ypad1 + $depth * $frameheight; + $y1 += $ypad3 if $subtitletext ne ""; $y2 = $ypad1 + ($depth + 1) * $frameheight - $framepad; + $y2 += $ypad3 if $subtitletext ne ""; } my $samples = sprintf "%.0f", ($etime - $stime) * $factor;