on Win32, this is found in the GetSystemInfo API call.Richard.Hill wrote:Can an APL function discover how many cores are available in the users computer?
⎕wcall 'W_Ini' 'GetSystemInfo'
(>SYSTEM_INFO) LIB Kernel32
⎕wcall 'W_Ini' '[type]SYSTEM_INFO'
{W wProcessorArchitecture, W wReserved, D dwPageSize, P lpMinimumApplicationAddresss, P lpMaximumApplicationAddress, D dwActiveProcessorMask, D dwNumberOfProcessors, D dwProcessorType, D dwAllocationGranularity, W wProcessorLevel, W wProcessorRevision}
While true, the Atom N450 has a single core, it is also hyperthreaded, and thus I believe that GetSystemInfo will then report 2 processors. I know this is true on my Pentium computer with hyperthreading. My pentium-M no hyperthreading reports a 1 processor. Core-2 Duo reports 2. It would be interesting to see what a Core-I7 with 4 cores reports...aplus wrote:I ran this code on a cheap entry level Acer Netbook with an Intel Atom N450 Processor (1.66 GHz, 512KB Cache) and was surprised to see 2 as the number of cores. In Control Panel/System it reports only 1 core.
Richard, on your computer, does this[code](5+⎕io)⊃⎕wcall 'GetSystemInfo' âRichard.Hill wrote:Brent, Thank you...
Core 2 Quad Q9505 reports 4
Adam, does your ActiveProcessorMask report 255? [code](5+⎕io)⊃⎕wcall 'GetSystemInfo' âAdam Kertesz wrote:My i7-740QM is reporting 8 cores, the same as my CPU Meter gadget shows.
Users browsing this forum: No registered users and 0 guests