aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/scripts/python/export-to-postgresql.py
diff options
context:
space:
mode:
authorFilipe Manana <fdmanana@suse.com>2025-04-16 17:05:11 +0100
committerDavid Sterba <dsterba@suse.com>2025-05-15 14:30:52 +0200
commit8faab454c59efbe13707b74963a4bc9a8a55fb49 (patch)
tree61136202ca8a2ff59dac55f8d6e93bcd87112b8c /tools/perf/scripts/python/export-to-postgresql.py
parentbtrfs: exit after state split error at set_extent_bit() (diff)
downloadlinux-rng-8faab454c59efbe13707b74963a4bc9a8a55fb49.tar.xz
linux-rng-8faab454c59efbe13707b74963a4bc9a8a55fb49.zip
btrfs: simplify last record detection at set_extent_bit()
There's no need to compare the current extent state's end offset to (u64)-1 to check if we have the last possible record and to check as as well if after updating the start offset to the end offset of the current record plus one we are still inside the target range. Instead we can simplify and exit if the current extent state ends at or after the target range and then remove the check for the (u64)-1 as well as the check to see if the updated start offset (to last_end + 1) is still inside the target range. Besides the simplification, this also avoids seaching for the next extent state record (through next_state()) when the current extent state record ends at the same offset as our target range, which is pointless and only wastes times iterating through the rb tree. 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/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions