From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-13.3 required=3.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_IN_DEF_DKIM_WL autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A8BD4C4338F for ; Mon, 16 Aug 2021 19:02:48 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 8918760F39 for ; Mon, 16 Aug 2021 19:02:48 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230107AbhHPTDT (ORCPT ); Mon, 16 Aug 2021 15:03:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43832 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229556AbhHPTDR (ORCPT ); Mon, 16 Aug 2021 15:03:17 -0400 Received: from mail-yb1-xb30.google.com (mail-yb1-xb30.google.com [IPv6:2607:f8b0:4864:20::b30]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 26C5FC061764 for ; Mon, 16 Aug 2021 12:02:46 -0700 (PDT) Received: by mail-yb1-xb30.google.com with SMTP id z5so34842109ybj.2 for ; Mon, 16 Aug 2021 12:02:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=G0f9iRcSsCU/k5L+VbuDUsYeEux2WN96aAx3sy3SC9c=; b=Dcrdwc1B6HWhDdaf1O5JH+TqzMxb3cMuOuaU9GtFTUDuGgaV3Ji5vmD2mKc2/Sb5DR erb+34mjxpF4H1aaNZfvCjRTO+/ssiwYJj/Upf5b+HEEA9OThYCftfBhqPUFIdslsAET ZAIdN9AwwTXuyc26EvpFmQCMjwU16Bi+lxpk4MkbsxjwmtXKAcPgi3a4x2aP/IllUr7S rM3YdN9A4PNT2YjzPlF5y6GI7+GnG6F1Bovvc9dWG+wHaK8uKGsTmX0dYRA3dNv++Ut3 dOsUXMkgztU3w2AP0jnGRMswEMJyTmQdekjPlcZIcLTfLpI3+2ELGD9OEXpdO50iux5q UH7g== 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=G0f9iRcSsCU/k5L+VbuDUsYeEux2WN96aAx3sy3SC9c=; b=nE3aA9vXmWKNBj+bTNPPOTx3RO2PzI1e2NfKi6MhqDQ6RQv8TWubOZ+l8yAHQSQY/V KX3OhajfTyt1VpJhklcdUjJh+Jmp4mxx/8stIBVdX+JD+4OyfzY9ABCK/tL4ObYEMyQK W1FqwV+Tpm/egd/EPKvoYqcq8n7grKLiBeoBMTZgzRjZKe1FDX3oCELVbAOuC3nw2V3L Nl0qoxOVKzyk3Qo0tEyW5pNtTVIqOcs9nGn1lHeNH93uSM6kfwQaVddrPMawaKP7Myws 8hF+MBRzR4WaSVpEQIdiGwEagegsD5Gj1q/UEqL1r/bVkZxpTmPGDJzWVy7uMZCmULPC 4PDw== X-Gm-Message-State: AOAM5324pHmzM0+fbeYVQ1+4iMwaA3eZ7fyeX33PhsEHt2NBwcaS/7j0 eXqXbApA7mr9D6ytuSscjoHibXSSyYgP2AB4iw9wVQ== X-Google-Smtp-Source: ABdhPJwR09CPvPLzoIX6mxvF1M/yXa/y8ztSGP+JV/qw0FXfUOiKsi5NS1cWdEmZ64/j28oDzNwkhT9TbOTMR09jVM4= X-Received: by 2002:a25:30c:: with SMTP id 12mr23527035ybd.212.1629140565133; Mon, 16 Aug 2021 12:02:45 -0700 (PDT) MIME-Version: 1.0 References: <20210816154401.23919-1-tao.zhou@linux.dev> In-Reply-To: From: Josh Don Date: Mon, 16 Aug 2021 12:02:34 -0700 Message-ID: Subject: Re: [PATCH] sched/core: An optimization of pick_next_task() not sure To: Peter Zijlstra Cc: Tao Zhou , linux-kernel , Thomas Gleixner , Joel Fernandes , "Hyser,Chris" , Ingo Molnar , Vincent Guittot , Valentin Schneider , Mel Gorman Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Aug 16, 2021 at 11:53 AM Peter Zijlstra wrote: > > On Mon, Aug 16, 2021 at 11:44:01PM +0800, Tao Zhou wrote: > > When find a new candidate max, wipe the stale and start over. > > Goto again: and use the new max to loop to pick the the task. > > > > Here first want to get the max of the core and use this new > > max to loop once to pick the task on each thread. > > > > Not sure this is an optimization and just stop here a little > > and move on.. > > > > Did you find this retry was an issue on your workload? Or was this from > reading the source? I would be surprised if this made a noticeable difference on SMT2, but I could certainly see how this would help with larger SMT configurations where we have more opportunities to invalidate the other siblings.