bcachefs: Improve an insert path optimization
authorKent Overstreet <kent.overstreet@gmail.com>
Fri, 31 Jan 2020 01:26:08 +0000 (20:26 -0500)
committerKent Overstreet <kent.overstreet@linux.dev>
Sun, 22 Oct 2023 21:08:35 +0000 (17:08 -0400)
commitfdf224003354fb14e20f638e479273c4728dfc0a
treede3f0ebe37a2063ca523ceffb6e0d06a3dd07b20
parent7d4aed1ea408f45aef8ddf5f28d8c10680b4f214
bcachefs: Improve an insert path optimization

The insert path had an optimization to short circuit lookup
table/iterator fixups when overwriting an existing key with the same
size value - but it was incorrect when other key fields
(size/version) were changing. This is important for the upcoming rework
to have extent updates use the same insert path as regular keys.

Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/bset.c
fs/bcachefs/btree_update_leaf.c