Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp458446pxa; Wed, 19 Aug 2020 06:21:14 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxMbv36IWVA1G493b4xyGoLr5dbxn+5xpAL6ySB77g5svDVWCigdvsYmcZT7wSN8YmLKFnk X-Received: by 2002:a17:906:1707:: with SMTP id c7mr25553350eje.498.1597843273734; Wed, 19 Aug 2020 06:21:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597843273; cv=none; d=google.com; s=arc-20160816; b=R6Z2FAFhdkGbuj3zNzAxPfFaTrbcsJ865LjG6PeENOqfm/UZA20BV57PbuK4+pfnnI LqURKRQ8JlYBSOd7HxzTclr+iujxa+Fktkt7y+IpnQfR0vxokZaU4Yo2k0u0ExqjcfYY u3upK9Bf6sJn8+y8/4NLPWmH5h9OvSV2Qq2FliCNK8b61+uyDjivZpQbx038Adn6LrvO wqe7wjsz/Q8pxh14XzUJxiIucgOWVDKdD7+/6jZ8SIE0ySkXLo3I1UEfntPmWHHWMAli QoVTwhT/lVu3iWqQa/6Sj3bbp8l9LeJJn/PU0tioNt+C4edb4DhfEwRvnGAwV92qu1vQ 3yFg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=v6oWupOTxMkZT/KhS528vX3zYkNGL3N/FEeWSRmmOn0=; b=V4MXVGoTd9SL41pG0nwsqIuXEojVqHusKI7WDp0OyP6Vp5oVx9bXB6+UtmPNKK+vYW EXf3H+Pu+MxtFvV7Ncy62/SkUFXAqUek//suwwakscIxfIdSediq60SXfcuAQ1ZVlZxI dgUW+r54kJLd8Y7IQnlGrgtR+7j/9vU6j0TbeqbLgHYQnLCHTUXfrEN/h07idquDDzZ9 vsI58cWnTcott6KkWkvrqVYUqorQuKbVh615z043HidpWjXEMkSQjjydYxlhI259Gc5e 2rmvV8I1cukKkf5hxawD/vcaYOUZUAKliJiELq6nSpS5OG6lEwOW2RZW1Fz5/bgLei4R bSvQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=iSIpNlfu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k30si20889846edj.513.2020.08.19.06.20.49; Wed, 19 Aug 2020 06:21:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=iSIpNlfu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728192AbgHSNRn (ORCPT + 99 others); Wed, 19 Aug 2020 09:17:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38386 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728478AbgHSNNP (ORCPT ); Wed, 19 Aug 2020 09:13:15 -0400 Received: from mail-ot1-x341.google.com (mail-ot1-x341.google.com [IPv6:2607:f8b0:4864:20::341]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 692EAC061343 for ; Wed, 19 Aug 2020 06:12:52 -0700 (PDT) Received: by mail-ot1-x341.google.com with SMTP id 93so19010485otx.2 for ; Wed, 19 Aug 2020 06:12:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=v6oWupOTxMkZT/KhS528vX3zYkNGL3N/FEeWSRmmOn0=; b=iSIpNlfuXZbrlw6rncA1oe7w/qv2xYw/6l2S4tSOFY//wPo6/BByC0wlD9SOKMk1TZ YFxokN4ECfm6Olm/zuRvKR7R98nq1jR5iDMPcG+bTKKjfYj5RLD55mfc1fI2VzwcDxOL juDlmE7EDJx9Q/ZAM9pznkKQ4Du/VNEzucXWMtd2QujvnqCPV5zPr8D1NYlpmf8EDuwW 3nRoY3hvWVbIYILVYzumEF6U8bZwiXbpeFxnA1v4YcqhXD8OsvWITY5I+DYszTJZj8bw FA65AR3M1rZRln2t4wnYwdkp8jOjck9CaG59dshT+x6ts1wBo3HRZzwoinUSCc2FTcBf lQaA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=v6oWupOTxMkZT/KhS528vX3zYkNGL3N/FEeWSRmmOn0=; b=CtzqJmyhQPrroxBZmx4SQuzYwZ4Q/fkUFdZQi9JjbeVHZfWKSCbinOkjcyT6xhJVEK 5jFmQxscZWNSnr4731siO/bTPLI78Tqu8qe3X2iyjmeYMC0edAee8Ip0oHiucH07ms2f us9xQR/bjQas5eUuESGDdmR7vQvT6R0i8TfxBPFgTePjDJDPSLPKmw+OsELhkV3p6VGl Ben3UYZeRO+CBKy8DNnJGSQ6g/pnVlG7VauFEJIZH/7Qz0nEI8odwzsOqv12Q8YXtFBG ms+yVzkZkvaq8xx5zlZRU37YecULFPpo7AC65TPIJSscEBVC77ymQrFIXyjq7dJed1lr dSbg== X-Gm-Message-State: AOAM531Ytk0U+qrXXTN2Ib1ceCGWHzKekiELwSjNvrCpI1YdYo7jtkBt Lyi8/Ue9A6JK+s25e2F7v5mbTgeFjO2Avnwgba4= X-Received: by 2002:a05:6830:20d6:: with SMTP id z22mr18863076otq.94.1597842771741; Wed, 19 Aug 2020 06:12:51 -0700 (PDT) MIME-Version: 1.0 References: <1596435031-41837-1-git-send-email-pullip.cho@samsung.com> <5f41af0f-4593-3441-12f4-5b0f7e6999ac@redhat.com> <20200818085444.GA72202@KEI> In-Reply-To: <20200818085444.GA72202@KEI> From: Pekka Enberg Date: Wed, 19 Aug 2020 16:12:32 +0300 Message-ID: Subject: Re: [PATCH] mm: sort freelist by rank number To: Cho KyongHo Cc: David Hildenbrand , Andrew Morton , "linux-mm@kvack.org" , LKML , hyesoo.yu@samsung.com, janghyuck.kim@samsung.com Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi KyongHo and David, On 07.08.20 09:08, Pekka Enberg wrote: > > > I think having more knowledge of DRAM controller details in the OS > > > would be potentially beneficial for better page allocation policy, so > > > maybe try come up with something more generic, even if the fallback to > > > providing this information is a kernel command line option. On Tue, Aug 18, 2020 at 12:02 PM Cho KyongHo wrote: > I don't find if there is a way to deliver detailed DRAM information > through ACPI, ATAG or something similar. But I didn't find. Perhaps that's still the case today then. In the context of this patch, what I am hoping is that we'd turn the "dram_rank_granule" parameter -- even if it's still a manually configured thing -- into an abstraction that we can later extend. IOW, something similar to what the "energy model" (kernel/power/energy_model.c) today is. On Mon, Aug 10, 2020 at 09:32:18AM +0200, David Hildenbrand wrote: > I guess one universal approach is by measuring access times ... not what > we might be looking for :) I don't think it's an unreasonable approach, but measurement accuracy and speed will determine if it's actually practical. There are examples of this kind of approach elsewhere too. For example, MCTOP [1] which aims to provide topology-aware OS abstractions, uses cache latency measurements to infer the topology. 1. https://timharris.uk/papers/2017-eurosys-mctop.pdf Regards, - Pekka