summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/stackcollapse.py
diff options
context:
space:
mode:
authorDamien Le Moal <dlemoal@kernel.org>2026-03-16 20:40:20 +0900
committerCarlos Maiolino <cem@kernel.org>2026-03-18 10:08:07 +0100
commitc1f955437440f92632e2efca4b591371bb3caefc (patch)
tree96f7e6dd37365a02e36f7e331715c6b83e9f53f7 /tools/perf/scripts/python/stackcollapse.py
parent68aa101bf2046aa8365333a3768cece07975ca5f (diff)
xfs: avoid unnecessary calculations in xfs_zoned_need_gc()
If zonegc_low_space is set to zero (which is the default), the second condition in xfs_zoned_need_gc() that triggers GC never evaluates to true because the calculated threshold will always be 0. So there is no need to calculate the threshold and to evaluate that condition. Return early when zonegc_low_space is zero. While at it, add comments to document the intent of each of the 3 tests used to determine the return value to control the execution of garbage collection. Signed-off-by: Damien Le Moal <dlemoal@kernel.org> Reviewed-by: Hans Holmberg <hans.holmberg@wdc.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Carlos Maiolino <cem@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions