]> git.proxmox.com Git - mirror_zfs.git/commit
clean up __dbuf_hold_impl
authorMatthew Ahrens <mahrens@delphix.com>
Fri, 31 Aug 2018 17:16:54 +0000 (13:16 -0400)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Fri, 31 Aug 2018 17:16:54 +0000 (10:16 -0700)
commitadb726eb0ed69e7331ddd308da8fec9316f6426d
treefc2cb42f02dd74c6f066a8e319347ddc2ff27184
parent9e7fb6c1718b4651f9134dde5f9fe79fa44f76d8
clean up __dbuf_hold_impl

We can simplify the dbuf_hold code by allocating dbuf_hold_arg_t's on
demand, rather than allocating a big array of them up front.  While this
can occasionally increase the number of allocations, typically only one
allocation is needed since the indirect block is already cached.

The performance test suite gets the same results with this change.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Tony Nguyen <tony.nguyen@delphix.com>
Signed-off-by: Matthew Ahrens <mahrens@delphix.com>
Closes #7841
module/zfs/dbuf.c