On Fri, Dec 22, 2023 at 05:59:34PM +0800, kernel test robot wrote: > > > Hello, > > kernel test robot noticed a -18.0% regression of stress-ng.link.ops_per_sec on: > > > commit: 8d993618350c86da11cb408ba529c13e83d09527 ("btrfs: migrate get_eb_page_index() and get_eb_offset_in_page() to folios") > https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git master Unfortunatelly the conversion to folios adds a lot of assembly code and we can't rely on constants like PAGE_SIZE anymore. The calculations in extent buffer members are therefore slower, 18% is a lot but within my expected range for metadta-only operations. This could be improved by caching some values, like folio_size, so it's a dereference and not a calculation of "PAGE_SIZE << folio_order" with conditionals around.