aboutsummaryrefslogtreecommitdiffstats
path: root/include/sys
diff options
context:
space:
mode:
authorAlexander Motin <[email protected]>2021-08-17 12:15:54 -0400
committerGitHub <[email protected]>2021-08-17 10:15:54 -0600
commit6b88b4b501a9e12dd6feee7e3cb2824bc70beeca (patch)
tree8dca8b6ea9f1d8ae628a454ec2ead51dcf422f46 /include/sys
parent72f0521abadd77ef06fb1d10c4f4f80af50ec279 (diff)
Remove b_pabd/b_rabd allocation from arc_hdr_alloc()
When a header is allocated for full overwrite it is a waste of time to allocate b_pabd/b_rabd for it, since arc_write() will free them without ever being touched. If it is a read or a partial overwrite then arc_read() and arc_hdr_decrypt() allocate them explicitly. Reduced memory allocation in user threads also reduces ARC eviction throttling there, proportionally increasing it in ZIO threads, that is not good. To minimize or even avoid it introduce ARC allocation reserve, allowing certain arc_get_data_abd() callers to allocate a bit longer in situations where user threads will already throttle. Reviewed-by: George Wilson <[email protected]> Reviewed-by: Mark Maybee <[email protected]> Signed-off-by: Alexander Motin <[email protected]> Sponsored-By: iXsystems, Inc. Closes #12398
Diffstat (limited to 'include/sys')
-rw-r--r--include/sys/arc_impl.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/sys/arc_impl.h b/include/sys/arc_impl.h
index 8421903fb..3c5af9d86 100644
--- a/include/sys/arc_impl.h
+++ b/include/sys/arc_impl.h
@@ -988,7 +988,7 @@ extern unsigned long zfs_arc_max;
extern void arc_reduce_target_size(int64_t to_free);
extern boolean_t arc_reclaim_needed(void);
extern void arc_kmem_reap_soon(void);
-extern void arc_wait_for_eviction(uint64_t);
+extern void arc_wait_for_eviction(uint64_t, boolean_t);
extern void arc_lowmem_init(void);
extern void arc_lowmem_fini(void);