Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove ARC/ZIO physdone callbacks. #14948

Merged
merged 1 commit into from
Jun 15, 2023
Merged

Commits on Jun 12, 2023

  1. Remove ARC/ZIO physdone callbacks.

    Those callbacks were introduced many years ago as part of a bigger
    patch to smoothen the write throttling within a txg. They allow to
    account completion of individual physical writes within a logical
    one, improving cases when some of physical writes complete much
    sooner than others, gradually opening the write throttle.
    
    Few years after that ZFS got allocation throttling, working on a
    level of logical writes and limiting number of writes queued to
    vdevs at any point, and so limiting latency distribution between
    the physical writes and especially writes of multiple copies.
    The addition of scheduling deadline I proposed in openzfs#14925 should
    further reduce the latency distribution.  Grown memory sizes over
    the past 10 years should also reduce importance of the smoothing.
    
    While the use of physdone callback may still in theory provide
    some smoother throttling, there are cases where we simply can not
    afford it.  Since dirty data accounting is protected by pool-wide
    lock, in case of 6-wide RAIDZ, for example, it requires us to take
    it 8 times per logical block write, creating huge lock contention.
    
    My tests of this patch show radical reduction of the lock spinning
    time on workloads when smaller blocks are written to RAIDZ pools,
    when each of the disks receives 8-16KB chunks, but the total rate
    reaching 100K+ blocks per second.  Same time attempts to measure
    any write time fluctuations didn't show anything noticeable.
    
    While there, remove also io_child_count/io_parent_count counters.
    They are used only for couple assertions that can be avoided.
    
    Signed-off-by:	Alexander Motin <mav@FreeBSD.org>
    Sponsored by:	iXsystems, Inc.
    amotin committed Jun 12, 2023
    Configuration menu
    Copy the full SHA
    a34161c View commit details
    Browse the repository at this point in the history