[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 619
  • Last Modified:

How to get a CPU speed using a Windows API

How to get a CPU speed using a Windows API
I'm interested in MHZ value, NOT in processor type (386, 486, Pentium etc.)
0
tbbrhun
Asked:
tbbrhun
1 Solution
 
anthonycCommented:
Processor Speed (MHZ) or CPU Make (486, Pentium, Etc?)

I can get the CPU mae for you but I am not sure the MHZ is possible
0
 
tbbrhunAuthor Commented:
Edited text of question
0
 
VerolandCommented:
Write a benchmark app.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
abelCommented:
I have a DLL of Intel (from the program CPUINFO) which does the trick. You only have to call the function in that DLL to get extended processor information. The function for the processor speed is very accurate (but of course uses a loop since you can't find that info on the chip itself...). I have the code for you in C and I can post that if you want, but it might be easier to download it yourself (full sourcecode, samples executables and dll's in one) at:

http://developer.intel.com/design/perftool/cpuid/

It's very easy to use. Look it up, try the executable coming with it if it fits your needs and try calling the dll's. The full documentation of the functions in the dll's is in the package as well. Don't bother about having to ship yet another dll with your app, it's only 20kb. And if you would want to incorporate it in your executable you can use the accompanying source code (be warned: assembler and C!).

Hope this helps you out.

Regards, Abel
0
 
tbbrhunAuthor Commented:
no comments, just THANKS A LOT, ABEL
0
 
MirkwoodCommented:
Bought This Question.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now