From nobody Fri Mar 4 01:39:02 2022 X-Original-To: freebsd-arch@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id C66F419FF43D for ; Fri, 4 Mar 2022 01:39:10 +0000 (UTC) (envelope-from mike@mail.karels.net) Received: from mail.karels.net (mail.karels.net [216.160.39.52]) by mx1.freebsd.org (Postfix) with ESMTP id 4K8r9p0lSYz4llN for ; Fri, 4 Mar 2022 01:39:10 +0000 (UTC) (envelope-from mike@mail.karels.net) Received: from mail.karels.net (localhost [127.0.0.1]) by mail.karels.net (8.16.1/8.16.1) with ESMTPS id 2241d2L2045465 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO) for ; Thu, 3 Mar 2022 19:39:02 -0600 (CST) (envelope-from mike@mail.karels.net) Received: (from mike@localhost) by mail.karels.net (8.16.1/8.16.1/Submit) id 2241d20M045464; Thu, 3 Mar 2022 19:39:02 -0600 (CST) (envelope-from mike) Message-Id: <202203040139.2241d20M045464@mail.karels.net> To: freebsd-arch@freebsd.org From: Mike Karels Reply-to: mike@karels.net Subject: Re: support for asymmetric CPUs List-Id: Discussion related to FreeBSD architecture List-Archive: https://lists.freebsd.org/archives/freebsd-arch List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-arch@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <45462.1646357942.1@mail.karels.net> Date: Thu, 03 Mar 2022 19:39:02 -0600 X-Rspamd-Queue-Id: 4K8r9p0lSYz4llN X-Spamd-Bar: + Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of mike@mail.karels.net has no SPF policy when checking 216.160.39.52) smtp.mailfrom=mike@mail.karels.net X-Spamd-Result: default: False [1.23 / 15.00]; HAS_REPLYTO(0.00)[mike@karels.net]; REPLYTO_ADDR_EQ_FROM(0.00)[]; TO_DN_NONE(0.00)[]; MID_RHS_MATCH_FROMTLD(0.00)[]; NEURAL_HAM_SHORT(-1.00)[-1.000]; FORGED_SENDER(0.30)[mike@karels.net,mike@mail.karels.net]; RCVD_NO_TLS_LAST(0.10)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:209, ipnet:216.160.36.0/22, country:US]; FROM_NEQ_ENVFROM(0.00)[mike@karels.net,mike@mail.karels.net]; FAKE_REPLY(1.00)[]; ARC_NA(0.00)[]; FREEFALL_USER(0.00)[mike]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-0.95)[-0.952]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-arch@freebsd.org]; AUTH_NA(1.00)[]; NEURAL_SPAM_MEDIUM(0.88)[0.880]; RCPT_COUNT_ONE(0.00)[1]; DMARC_NA(0.00)[karels.net]; MLMMJ_DEST(0.00)[freebsd-arch]; R_SPF_NA(0.00)[no SPF record]; RCVD_COUNT_TWO(0.00)[2] X-ThisMailContainsUnwantedMimeParts: N Replying to several messages, including my own: Although several people mentioned energy efficiency, that is not my immediate goal. At least with the Alder Lake CPUs, I suspect that the difference in energy use between low load on P-cores and E-cores is small. These are not especially energy-efficient chips; the i7-12700K is rated at a base power of 125 W, with a peak of 190 W. Instead, I am more interested in system throughput and sensible placement decisions using fairly simple algorithms. I plan to experiment with starting most processes on E-cores, and promoting to P-cores as soon as they start using much CPU time. This should reserve the P-cores for the processes that most need them, and keep the processes with lower utilization from interrupting them and disturbing caches. In any case, I'm hoping that simple algorithms can beat random placement. Naively, I hope that similar strategies would also lower power consumption for varying workloads with mixed core types, although not as much as algorithms that were more sensitive to efficiency of different types of workload on the different cores. I haven't decided yet whether to consider threaded processes differently; the E-cores are supposedly better for threaded processes. I also don't know if/when I'll experiment with Intel's Hardware Feedback Interface; it will obviously depend on availability of documentation or example code. In theory HFI could yield quicker placement decisions. Any additional input welcomed... Mike