From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752022AbdI2NN6 (ORCPT ); Fri, 29 Sep 2017 09:13:58 -0400 Received: from merlin.infradead.org ([205.233.59.134]:50208 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750782AbdI2NN5 (ORCPT ); Fri, 29 Sep 2017 09:13:57 -0400 Date: Fri, 29 Sep 2017 15:13:29 +0200 From: Peter Zijlstra To: Vitaly Kuznetsov Cc: kernel test robot , Ingo Molnar , Juergen Gross , "Kirill A. Shutemov" , Andrew Cooper , Andy Lutomirski , Boris Ostrovsky , Jork Loeser , KY Srinivasan , Linus Torvalds , "Paul E. McKenney" , Stephen Hemminger , Steven Rostedt , Thomas Gleixner , LKML , lkp@01.org Subject: Re: [lkp-robot] [x86/mm] 9e52fc2b50: will-it-scale.per_thread_ops -16% regression Message-ID: <20170929131329.tekd6a7yfrkm7lwl@hirez.programming.kicks-ass.net> References: <20170927055914.GO17200@yexl-desktop> <87d169zo9o.fsf@vitty.brq.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87d169zo9o.fsf@vitty.brq.redhat.com> User-Agent: NeoMutt/20170609 (1.8.3) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Sep 29, 2017 at 02:24:03PM +0200, Vitaly Kuznetsov wrote: > 1) In case the system is under extreme memory pressure and > __get_free_page() is failing in tlb_remove_table() we'll be doing > smp_call_function() for _each_ call (avoiding batching). We may want to > have a pre-allocated pool. MMU_GATHER_BUNDLE should avoid it being for _every_ call. Also, note that tlb_gather is preemptible, so pre-alloc is 'difficult' and you will run out, esp. when memory is right. > 2) The default MAX_TABLE_BATCH is static (it is equal to the number of > pointer we can fit into one page - sizeof(struct mmu_table_batch) == > 509), we may want to adjust it for very big systems. That would then put more stress on the memory allocator because you're then asking for higher order pages.