[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZHnGyNd4lHz/pwKr@dhcp22.suse.cz>
Date: Fri, 2 Jun 2023 12:39:04 +0200
From: Michal Hocko <mhocko@...e.com>
To: Marcelo Tosatti <mtosatti@...hat.com>
Cc: Christoph Lameter <cl@...ux.com>,
Aaron Tomlin <atomlin@...mlin.com>,
Frederic Weisbecker <frederic@...nel.org>,
Andrew Morton <akpm@...ux-foundation.org>,
linux-kernel@...r.kernel.org, linux-mm@...ck.org,
Vlastimil Babka <vbabka@...e.cz>
Subject: Re: [PATCH 2/4] vmstat: skip periodic vmstat update for nohz full
CPUs
On Tue 30-05-23 11:52:36, Marcelo Tosatti wrote:
> @@ -2022,6 +2023,16 @@ static void vmstat_shepherd(struct work_
> for_each_online_cpu(cpu) {
> struct delayed_work *dw = &per_cpu(vmstat_work, cpu);
>
> + /*
> + * Skip periodic updates for nohz full CPUs.
> + * Any callers who need precise values should use
> + * a snapshot of the per-CPU counters, or use the global
> + * counters with measures to handle errors up to
> + * thresholds (see calculate_normal_threshold).
> + */
> + if (tick_nohz_full_cpu(cpu))
> + continue;
In other code path we have used cpu_is_isolated, is there any reason to
diverge from that here? Isn't this effectivelly the same kind of
problem?
> +
> if (!delayed_work_pending(dw) && need_update(cpu))
> queue_delayed_work_on(cpu, mm_percpu_wq, dw, 0);
>
>
--
Michal Hocko
SUSE Labs
Powered by blists - more mailing lists