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 Received: from shelob.surriel.com (shelob.surriel.com [96.67.55.147]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D534EC433EF for ; Thu, 26 May 2022 14:20:41 +0000 (UTC) Received: from localhost ([::1] helo=shelob.surriel.com) by shelob.surriel.com with esmtp (Exim 4.94.2) (envelope-from ) id 1nuELf-00011D-57; Thu, 26 May 2022 10:20:23 -0400 Received: from mail-qk1-x733.google.com ([2607:f8b0:4864:20::733]) by shelob.surriel.com with esmtps (TLS1.2) tls TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1nuELb-00010i-S5 for kernelnewbies@kernelnewbies.org; Thu, 26 May 2022 10:20:20 -0400 Received: by mail-qk1-x733.google.com with SMTP id 190so1530143qkj.8 for ; Thu, 26 May 2022 07:20:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vt-edu.20210112.gappssmtp.com; s=20210112; h=sender:from:to:cc:subject:in-reply-to:references:mime-version:date :message-id; bh=gsI0vsVrbqM0SdBJ/7gHlSsqliczeRiRRVYeSfdLSME=; b=Jk4CwhydIXtT8bq/nfJkbF8onvqXHWBENyaciMWgXgEUqFVI16XESm9kxSHrHKEZ3i ctAdmowo6tD2xZShecdP196jYx5fRtaSMKFUVqruRIwbkdVQuR9wpJGqDPkyPEDuiYlc Pm9pjI1Dz1C6iLNrOuUx5JhMf0npbzMI8iAov5sEmLBKForR9WkT/wV8UNx+ibJWNc5V VZHjobNC/xuzTLfmCeZ1MpKMdMS3WOgiSdsvSuMM7XjBbkZV+iUh+/ccFw2cMmLKWvI/ rDyWTg7msh0333yo1FBlfNWx2/Uu/pxdCu/PxFXupFTip4poG05YI/Ug9hzWK3z1A9wN 9LsQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:sender:from:to:cc:subject:in-reply-to:references :mime-version:date:message-id; bh=gsI0vsVrbqM0SdBJ/7gHlSsqliczeRiRRVYeSfdLSME=; b=ABPSrWyRbyeUWvKwQdIm8RApgowJEUUz/tgny+h51tGW1obU+tdjiFFh4cfJeusQbx TzigTGXwYkJqtXO3gbRQTqe0SUnzlHTWhQdfN9g5Jf0kT4F4/XB9J8M8Q4z3pgSfCADl VqledN5Pii3BB+rG8QOE6A0r/tGvh3oZBfFEsi2N06eWW9z2MYZ3C8G1cBHZE6YUodnV hdoFULP3b9IyiniVKSBSa5+Xu0vnSTmp9My2Wd/578Ss3o1NRQUKd5KoBttigNcq1+F5 KvFxXVvwUzwGG4wxT5UKgJqYF6YUClLPzYKoZN8aoHRFTZkZheYPGMUsmUerHvYuONSR 8DfA== X-Gm-Message-State: AOAM5318aMVnznkUGlQfbY1Nycv4Amvt2QOrKECGYdggV3c8bFwyOxMz wAImM8KaPTc8l5P5t1ocLwJ9GS5LnL7Z7w== X-Google-Smtp-Source: ABdhPJwwL/e0307cp8V3Qu9hN3FVaLZNSDvfPud2zxgAQdlxi2UNCC14pxSOkEQtVFx6PZw+t0gHDg== X-Received: by 2002:a05:620a:341:b0:6a3:49b2:dbb7 with SMTP id t1-20020a05620a034100b006a349b2dbb7mr21391773qkm.5.1653574818564; Thu, 26 May 2022 07:20:18 -0700 (PDT) Received: from turing-police ([2601:5c0:c380:d60:f276:1cff:fe8f:1dec]) by smtp.gmail.com with ESMTPSA id i4-20020a05622a08c400b002fac21ffd71sm1082411qte.6.2022.05.26.07.20.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 26 May 2022 07:20:17 -0700 (PDT) From: "Valdis Kl=?utf-8?Q?=c4=93?=tnieks" X-Google-Original-From: "Valdis Kl=?utf-8?Q?=c4=93?=tnieks" X-Mailer: exmh version 2.10.0-pre 07/05/2021 with nmh-1.7+dev To: dakra137@gmail.com Subject: Re: Hacking the schedutil governor to upshift to maximum clock rate at every process dispatch. In-reply-to: References: Mime-Version: 1.0 Date: Thu, 26 May 2022 10:20:16 -0400 Message-ID: <1456834.1653574816@turing-police> Cc: kernelnewbies@kernelnewbies.org X-BeenThere: kernelnewbies@kernelnewbies.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Learn about the Linux kernel List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: kernelnewbies-bounces@kernelnewbies.org On Mon, 23 May 2022 17:37:09 +0300, David Kra said: > I am considering modifying the scheduler and governor to get a jackrabbit > start whenever a process is dispatched. Before learning how to, I would > like some advice on whether to, and how much to do. Step 0: gather actual data, and see if you will get any significant observable boost. (If you don't know how to test if you will get any improvement, you probably don't know how to test for improvement after the patch is done. So you may as well do that part up front, unglamorous as it may be) Hint: powertop is your friend (or are the cool kids using something else this week?) > * Is there a better way to achieve the same result? It would probably be a lot easier to just set the CPU governor to "performance" mode. > * Is this a dumb thing to do? Probably, but it will depend on your use case. > * Is it safe to rely on the existing code, firmware, and microcode to handle the > subsequent downclocking, and for my hack to only do the upclocking? Well, you're just going to turn around and upclock it at the end of that process's tiimeslice, so it's unclear what real benefit you'd get from downclocking. _______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies