Skip to content
  • Jan Kara's avatar
    lib: Proportions with flexible period · f3109a51
    Jan Kara authored
    
    
    Implement code computing proportions of events of different type (like code in
    lib/proportions.c) but allowing periods to have different lengths. This allows
    us to have aging periods of fixed wallclock time which gives better proportion
    estimates given the hugely varying throughput of different devices - previous
    measuring of aging period by number of events has the problem that a reasonable
    period length for a system with low-end USB stick is not a reasonable period
    length for a system with high-end storage array resulting either in too slow
    proportion updates or too fluctuating proportion updates.
    
    Acked-by: default avatarPeter Zijlstra <a.p.zijlstra@chello.nl>
    Signed-off-by: default avatarJan Kara <jack@suse.cz>
    Signed-off-by: default avatarFengguang Wu <fengguang.wu@intel.com>
    f3109a51