aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/scripts/python/bin/stackcollapse-report
diff options
context:
space:
mode:
authorFilipe Manana <fdmanana@suse.com>2025-04-02 13:31:46 +0100
committerDavid Sterba <dsterba@suse.com>2025-05-15 14:30:41 +0200
commit53828c759ad7d281a8e7f26b7c1102db9ec678f2 (patch)
treee16d7f351b66d68bfdb169ce0b6f254f98b0006d /tools/perf/scripts/python/bin/stackcollapse-report
parentbtrfs: remove redundant check at find_first_extent_bit_state() (diff)
downloadlinux-53828c759ad7d281a8e7f26b7c1102db9ec678f2.tar.gz
linux-53828c759ad7d281a8e7f26b7c1102db9ec678f2.zip
btrfs: simplify last record detection at test_range_bit()
The overflow detection for the start offset of the next record is not really necessary, we can just stop iterating if the current record ends at or after out end offset. This removes the need to test if the current record end offset is (u64)-1 and to check if adding 1 to the current end offset results in 0. By testing only if the current record ends at or after the end offset, we also don't need anymore to test the new start offset at the head of the while loop. This makes both the source code and assembly code simpler, more efficient and shorter (reducing the object text size). Also remove the pointless initialization to NULL of the state variable, as we don't use it before the first assignment to it. This may help avoid some warnings with clang tools such as the one reported/fixed by commit 966de47ff0c9 ("btrfs: remove redundant initialization of variables in log_new_ancestors"). Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'tools/perf/scripts/python/bin/stackcollapse-report')
0 files changed, 0 insertions, 0 deletions