W3C home > Mailing lists > Public > whatwg@whatwg.org > May 2014

Re: [whatwg] Proposal: navigator.cores

From: Adam Barth <w3c@adambarth.com>
Date: Mon, 5 May 2014 08:26:51 -0700
Message-ID: <CAJE5ia_phZ5bOmi9MDJ-jr2ri-Ks=0u-SgGXidtrKyFYfzS57A@mail.gmail.com>
To: Boris Zbarsky <bzbarsky@mit.edu>
Cc: whatwg <whatwg@lists.whatwg.org>
On Mon, May 5, 2014 at 6:45 AM, Boris Zbarsky <bzbarsky@mit.edu> wrote:

> On 5/4/14, 9:49 AM, Adam Barth wrote:
>
>> Maybe navigator.hardwareConcurrency as a nod to the C++11 name?
>>
>
> What is the proposed behavior of this attribute on AMP (as opposed to SMP)
> systems?  Note that some of these are shipping in actual devices today, and
> I expect that to continue.


>From the proposal wiki page:

"On getting, the cores property should return the number of logical
processors available to the user agent. For example on OS X this should be
equivalent to running sysctl -n hw.ncpu."

Eli clarified further in <
http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2014-May/254202.html>:

---8<---
The proposal specifically states using logical cores, which handles
all of the CPUs you mentioned properly.

Intel CPUs with hyperthreading enabled report logical cores as double
the hardware cores. Depending on the version and configuration of the
Samsung Exynos Octa big.LITTLE CPUs, you will get either 4 logical
cores (only one cluster can run at a time) or 8 logical cores
(big.LITTLE MP, available in Exynos 5420 or later only).
--->8---

I'm sure there's more precise language we could use in the spec.

Adam
Received on Monday, 5 May 2014 15:27:48 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 17:00:20 UTC