Received: by 2002:a05:6602:2086:0:0:0:0 with SMTP id a6csp4679781ioa; Wed, 27 Apr 2022 08:49:24 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy+CiZvGaosa5Af7sOTL6/N20/DufL0dvhA+O2vQZy4lkZ/G2jlJpRmxp36N7TDc1yOh9lp X-Received: by 2002:a05:6a00:1354:b0:50c:e672:edfc with SMTP id k20-20020a056a00135400b0050ce672edfcmr30190682pfu.50.1651074564633; Wed, 27 Apr 2022 08:49:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1651074564; cv=none; d=google.com; s=arc-20160816; b=Ib2hWpc3Sv5QrP/QLxNU9TtksmPOA9yBi/+ZhNIVBIkZtaFdmqAC/16sJCZOAUqtkh st8PT/28ZyxZBx9cUMK3lKqLf3QDjLnFCvoKbQpR7yEOWiqJIQHIQz9J7CUDY7uoEXz5 1/DkKT1nQc8GriOyKz1GMs5N5OoG3tyOJ2XARYqv0NHlZzQcDXxA1nUR2hd8fj2wnNDX v/VWJzIna/UFUaweYk3JUCIU/ee8GrdpJzLYRIVcC708in+WeJblN34VhySltN17LxdS gHB47I/1wWhqtYMp+ns6PAAvD+WulIwp+Xq+oqDwA4QYcpEtCuYkbL3YX91TQ6HGbC75 9eAw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=LNAyzMhGrm56//UE4/ZGodPQJ3CS7zahQHt/zd8A0Jg=; b=EJMUfBwr4Vn96A1eOxHuNd6EyezezEPkYoFevw4pfa9lvWISJb1e9sOW+3wWZqClg5 YJvL11renuehwYTRBlcHuHwYwea4yciCiFi8cb6d4LfGd+9YRvCrx42vuhl71gZP1ajk AcBZiKkiiRsHlHkNJd9Mc0ybhVaMWJugcmaLXy4KaCZRNtc0tLgtJbcLbWtv8M01OqM3 YuUqpJHmhBcWN1Oi2w/QkcbS0eJN6hCxosk+4P0JJJ33tfth52f5tD9R6C0HZ+xVVNpd nebnWZLn+qGKsNzdsrNta1VYjJRRctJWCmf2dIiIDvFi9O3kyd/TltRUV+7q0x85xXJY V2hQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=TI+WtwdF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id h187-20020a6283c4000000b00505ab468000si1634870pfe.215.2022.04.27.08.49.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Apr 2022 08:49:24 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=TI+WtwdF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 10F702EE3DD; Wed, 27 Apr 2022 08:22:59 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240013AbiD0PZm (ORCPT + 99 others); Wed, 27 Apr 2022 11:25:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49002 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240012AbiD0PZk (ORCPT ); Wed, 27 Apr 2022 11:25:40 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 4E5462EC35F for ; Wed, 27 Apr 2022 08:22:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1651072942; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=LNAyzMhGrm56//UE4/ZGodPQJ3CS7zahQHt/zd8A0Jg=; b=TI+WtwdFA5DXsd6+RECnE85bMtjxuHk/9vdo+GlkPQomThxieBWjXILyp6V95VB8acX9/J K/r2h6KpdOPNWjWSRLW+FknoXOROI7TX1QPGDJBH4L6BI5ju0jDoFRN9c5qbKLzGuLVowu bjy4Q+q3EQ0XKxdFuJv1aN0Fgl0xHMQ= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-245-N_FnrifQOxWIGho6WLXR_g-1; Wed, 27 Apr 2022 11:22:19 -0400 X-MC-Unique: N_FnrifQOxWIGho6WLXR_g-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 6C24280418C; Wed, 27 Apr 2022 15:22:19 +0000 (UTC) Received: from fuller.cnet (ovpn-112-2.gru2.redhat.com [10.97.112.2]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 1B5A21468F21; Wed, 27 Apr 2022 15:22:19 +0000 (UTC) Received: by fuller.cnet (Postfix, from userid 1000) id E7726416F574; Wed, 27 Apr 2022 12:21:47 -0300 (-03) Date: Wed, 27 Apr 2022 12:21:47 -0300 From: Marcelo Tosatti To: Nicolas Saenz Julienne Cc: Minchan Kim , Mel Gorman , Vlastimil Babka , Michal Hocko , LKML , Linux-MM Subject: Re: [RFC PATCH 0/6] Drain remote per-cpu directly Message-ID: References: <20220420095906.27349-1-mgorman@techsingularity.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Scanned-By: MIMEDefang 2.85 on 10.11.54.7 X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Apr 26, 2022 at 01:06:12PM +0200, Nicolas Saenz Julienne wrote: > On Mon, 2022-04-25 at 15:58 -0700, Minchan Kim wrote: > > On Wed, Apr 20, 2022 at 10:59:00AM +0100, Mel Gorman wrote: > > > This series has the same intent as Nicolas' series "mm/page_alloc: Remote > > > per-cpu lists drain support" -- avoid interference of a high priority > > > task due to a workqueue item draining per-cpu page lists. While many > > > workloads can tolerate a brief interruption, it may be cause a real-time > > > task runnning on a NOHZ_FULL CPU to miss a deadline and at minimum, > > > the draining in non-deterministic. > > > > Yeah, the non-deterministic is a problem. I saw the kworker-based draining > > takes 100+ms(up to 300ms observed) sometimes in alloc_contig_range if CPUs > > are heavily loaded. > > > > I am not sure Nicolas already observed. it's not only problem of > > per_cpu_pages but it is also lru_pvecs (pagevec) draining. > > Do we need to introduce similar(allow remote drainning with spin_lock) > > solution for pagevec? > > Yes, I'm aware of the lru problem. I'll start working on it too once we're done > with the page allocator (and if no-one beats me to it). That said, I don't know > if we can apply the exact same approach, the devil is in the details. :) I think one necessary step for that (adding spinlock to protect per-CPU lru_pvecs) would be to find a suitable testcase. Mel, do you have anything in mind ? > > -- > Nicol?s S?enz > >