Hi
When measuring the thread pool with ThreadPool.GetM axThreads(..), it returns
25 threads per CPU. On a hyper threaded machine, though, it returns 50
threads, still only having one CPU. How do I accurately determine the
physical CPU count? Any idea?
Thanks, Urs 5 6927
Urs Vogel wrote: threads, still only having one CPU. How do I accurately determine the physical CPU count? Any idea?
I would guess WMI would be the route to take, but more importantly, how
come you need to know the physical CPU-count?
Note that "physical cpu-count" has been a rather vague term for quite a
while now. All recent CPU's have multiple, concurrent computational units.
--
Helge Jensen
mailto:he****** ****@slog.dk
sip:he********* *@slog.dk
-=> Sebastian cover-music: http://ungdomshus.nu <=-
Thanks Helge
I need it for licensing purposes for an application server. Hyper threaded
CPUs must still count as ONE CPU.
Urs
"Helge Jensen" <he**********@s log.dk> schrieb im Newsbeitrag
news:42******** ******@slog.dk. ..
Urs Vogel wrote:
threads, still only having one CPU. How do I accurately determine the physical CPU count? Any idea?
I would guess WMI would be the route to take, but more importantly, how come you need to know the physical CPU-count?
Note that "physical cpu-count" has been a rather vague term for quite a while now. All recent CPU's have multiple, concurrent computational units.
-- Helge Jensen mailto:he****** ****@slog.dk sip:he********* *@slog.dk -=> Sebastian cover-music: http://ungdomshus.nu <=-
"Urs Vogel" <uv****@msn.com > wrote in message
news:%2******** **********@TK2M SFTNGP09.phx.gb l... Hi
When measuring the thread pool with ThreadPool.GetM axThreads(..), it returns 25 threads per CPU. On a hyper threaded machine, though, it returns 50 threads, still only having one CPU. How do I accurately determine the physical CPU count? Any idea?
Thanks, Urs
Read the NUMBER_OF_PROCE SSORS environment variable, or use System.Manageme nt
and the WMI class Win32_processor .
Note that each core (logical CPU) is treated as a separate CPU by the OS, so
the value returned by GetMaxThreads is valid as far as the CLR is concerned.
Willy.
I would not rely on any formula involving the maximum threads per processor
for the simple reason that this value can change with some future build of
the framework. In any case, WMI or some Win32 call surely exists for
determining that. Try Googling on:
"determine number of processors" windows
.... or similar.
--Bob
"Urs Vogel" <uv****@msn.com > wrote in message
news:%2******** **********@TK2M SFTNGP09.phx.gb l... Hi
When measuring the thread pool with ThreadPool.GetM axThreads(..), it returns 25 threads per CPU. On a hyper threaded machine, though, it returns 50 threads, still only having one CPU. How do I accurately determine the physical CPU count? Any idea?
Thanks, Urs
Bob
found the following, looks rigth into the CPU(s), checks for Hyperthreading
and even retrieves the logical and physical CPU IDs: http://www.intel.com/cd/ids/develope...base/43838.htm
Thanks. Urs
"Bob Grommes" <bo*@bobgrommes .com> schrieb im Newsbeitrag
news:O1******** ******@tk2msftn gp13.phx.gbl... I would not rely on any formula involving the maximum threads per processor for the simple reason that this value can change with some future build of the framework. In any case, WMI or some Win32 call surely exists for determining that. Try Googling on:
"determine number of processors" windows
... or similar.
--Bob
"Urs Vogel" <uv****@msn.com > wrote in message news:%2******** **********@TK2M SFTNGP09.phx.gb l... Hi
When measuring the thread pool with ThreadPool.GetM axThreads(..), it returns 25 threads per CPU. On a hyper threaded machine, though, it returns 50 threads, still only having one CPU. How do I accurately determine the physical CPU count? Any idea?
Thanks, Urs This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Canneloni |
last post by:
Xeon hyperthreaded CPUs show up as two CPUs in the cpuinfo file.
So a dual Xeon machine appears as a quad processor.
In Windows, it's the same thing.
A dual Xeon will have 4 CPU charts showing in the Task Manager cpu chart.
Ok, then question.
|
by: AWHK |
last post by:
I got 4 virtual CPUs on my computer (xeon processor) and I got this .NET
application that runs a lengthy processor intensive task.
I have noticed when I start two instances of the application (each one
running its lengthy processor intensive task) they use one virtual CPU each.
How can I implement this functionallity within one application ie. running
two lengthy tasks within one application using two CPUs. Do I use
appdomains,...
|
by: Shreyas Kulkarni |
last post by:
hi there,
recently i have got a problem regarding calculation of sum of digits in
a floating point or precision number. the weird behaviour of
compiler/language is preventing me from calculating the sum of all
digits. the compiler doesnt store the number as given by the user. some
of the precision digits are lost or changed (at will!). so by any
method, i m unable to reliably calculate the sum of provided number;
except i input the...
|
by: RP |
last post by:
Hi all, where can I find some docs on tuning asp.net 1.1 for HT CPUs? We
just upgraded our server to a single HT CPU and it appears that the OS still
reports 2 CPUs?
TIA!
|
by: adsheehan |
last post by:
I have been reading many of the posting on the GIL and impact on
threading etc.
I have found is confusing and would welcome some clarity on this.
I understand that embedding the interpreter in a C/C++ application
limits it to one CPU.
If the application is multi-threaded (system threads) in will not use
additional CPUs as the interpreter is tied to one CPU courtesy of the
GIL.
True or False?
| |
by: Klaas Vantournhout |
last post by:
Hi,
I am currently using OpenMP (gcc 4.2.0) to do parallel computing on a
computer with a certain amount of cpu's.
I need the total number of cpu's as a variable in my code. So I was
wondering how I could do this. Does there exists a system call for that
or something or is the best way just to take this out of /proc/cpuinfo?
I also would like to use some preprocessor code in it to cancel out the
|
by: rcamarda |
last post by:
I have been unsuccessful locating information about the maximum number
of CPU's SQL Server 2005 Enterprise supports.
However I did find info in a document about configuring a fail over
cluster solution. It said 4 CPUs, but it is unclear how that works out
with multi core processors.
Is it 4 sockets? So with a quad core quad socket we could go have a 16
core system?
BTW the chart shows the CPU count jumping to 64 CPU's under Server
2003...
|
by: Shekar |
last post by:
Is there a class/module/function in PHP that will help me identify the
number of CPUs on a system?
php_uname() does not provide that information. Though I can execute a
system command, I do not have a
consistent method that will work across platforms like Linux, SunOS,
AIX, HP-UX and Windows*
Thanks
Shekar
|
by: John |
last post by:
Is there a way to find the number of processors on a machine (on linux/
windows/macos/cygwin) using python code (using the same code/cross
platform code)?
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |