From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752493AbbHCCGf (ORCPT ); Sun, 2 Aug 2015 22:06:35 -0400 Received: from szxga01-in.huawei.com ([58.251.152.64]:18486 "EHLO szxga01-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751063AbbHCCGd (ORCPT ); Sun, 2 Aug 2015 22:06:33 -0400 Message-ID: <55BECC85.7050206@huawei.com> Date: Mon, 3 Aug 2015 10:05:57 +0800 From: Xishi Qiu User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:12.0) Gecko/20120428 Thunderbird/12.0.1 MIME-Version: 1.0 To: Dave Hansen CC: Andrew Morton , Mel Gorman , Vlastimil Babka , Johannes Weiner , Michal Hocko , , , , Linux MM , LKML Subject: Re: [PATCH] mm: add the block to the tail of the list in expand() References: <55BB4027.7080200@huawei.com> <55BC0392.2070205@intel.com> In-Reply-To: <55BC0392.2070205@intel.com> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.177.25.179] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2015/8/1 7:24, Dave Hansen wrote: > On 07/31/2015 02:30 AM, Xishi Qiu wrote: >> __free_one_page() will judge whether the the next-highest order is free, >> then add the block to the tail or not. So when we split large order block, >> add the small block to the tail, it will reduce fragment. > > It's an interesting idea, but what does it do in practice? Can you > measure a decrease in fragmentation? > > Further, the comment above the function says: > * The order of subdivision here is critical for the IO subsystem. > * Please do not alter this order without good reasons and regression > * testing. > > Has there been regression testing? > > Also, this might not do very much good in practice. If you are > splitting a high-order page, you are doing the split because the > lower-order lists are empty. So won't that list_add() be to an empty Hi Dave, I made a mistake, you are right, all the lower-order lists are empty, so it is no sense to add to the tail. Thanks, Xishi Qiu > list most of the time? Or does the __rmqueue_fallback() > largest->smallest logic dominate? > > . >