aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-postgresql.py
diff options
context:
space:
mode:
authorFilipe Manana <[email protected]>2023-05-04 12:04:19 +0100
committerDavid Sterba <[email protected]>2023-06-19 13:59:23 +0200
commitfbb2e654d898f141a2cde37074535d9cec10b03a (patch)
tree6bf05a0d815f99a72620ca06a8b805c3ff9a48b2 /tools/perf/scripts/python/export-to-postgresql.py
parent12df6a622ed8f0cd14470c6d76fe1b85f621f230 (diff)
btrfs: avoid extra memory allocation when copying free space cache
At copy_free_space_cache(), we add a new entry to the block group's ctl before we free the entry from the temporary ctl. Adding a new entry requires the allocation of a new struct btrfs_free_space, so we can avoid a temporary extra allocation by freeing the entry from the temporary ctl before we add a new entry to the main ctl, which possibly also reduces the chances for a memory allocation failure in case of very high memory pressure. So just do that. Reviewed-by: Anand Jain <[email protected]> Signed-off-by: Filipe Manana <[email protected]> Reviewed-by: David Sterba <[email protected]> Signed-off-by: David Sterba <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions