Click here to Skip to main content
15,887,875 members
Everything / CPU

CPU

CPU

Great Reads

by Jeremy C. Ong
Accelerate a C++ article with GPU support using Intel's oneAPI
by Alexandre De Pereyra
Efficient anti-aliasing techniques are an important tool of high-quality, real-time rendering. A new Intel technique called Morphological Antialiasing (MLAA) addresses limitations of the standard technique, MSAA. This article discusses MLAA implementation. Includes code samples and free download.
by Paul Lindberg
This case study details how the game takes best advantage of low-power systems, while still scaling up to look and run fantastic on more robust systems.
by Apriorit Inc, Artem K.
Find out approaches which you can use to improve runtime algorithms for zero-day threat detection

Latest Articles

by ToughDev
Hyper-V & Hardware Assisted Virtualization
by Jeremy C. Ong
Accelerate a C++ article with GPU support using Intel's oneAPI
by Martin Vorbrodt
How to measure CPU time?
by Apriorit Inc, Artem K.
Find out approaches which you can use to improve runtime algorithms for zero-day threat detection

All Articles

Sort by Title

CPU 

3 Mar 2018 by Lê Ngọc Quý
Hello everybody! I have a problem in my projects. Hope anyone can help me! Thank you very much.I want to get current clock of processor in real-time (update each second) to plot a graph.I create a Timer with 1000 miliseconds interval, inside the Timer_Tick() function, I use this code to...
6 Jul 2013 by Ron Beyer
I hope you have that code in a try...catch block. You are probably throwing a lot of exceptions which causes the program to lock up in the routine while you are attempting to get an invalid object on everything until you get the one that works. What you need to do is find the correct...
21 Aug 2017 by Wendelius
I'm trying to understand why different tools show different results for CPU utilization. I created a simple loop that should completely consume all CPU resources. However, depending which tool I use for observation of the CPU load I see very different results. The situation is roughly like...
19 Dec 2014 by OKarpov
How to use ASM in C#.NET and most fast memory copy method
19 Dec 2021 by John Bon Jovy
For my C# .Net Framework project I need to get 5 values: 1) CPU Load 2) CPU Temp 3) Current Voltage 4) VID Voltage 5) Current Frequency After doing some research, I figured that the best way to obtain those values would be to use...
19 Dec 2021 by 0x01AA
ISensor supports a property SensorType SensorType which is defined in ISensor like this: public enum SensorType { Voltage, // V Current, // A Power, // W Clock, // MHz Temperature, // °C ...
11 Jan 2022 by John Bon Jovy
I implemented the code that obtaining hardware sensors' readings using OpenHardwareMonitor. The code looks like this: using OpenHardwareMonitor.Hardware;namespace WindowsFormsApp3{ public - Pastebin.com[^] It basically searches for the...
11 Jan 2022 by 0x01AA
I searched a lot to get a solution with OpenHardwareMonitor but I also had no success. Furthermore in a lot of posts I found a remark that OpenHardwareMonitor is not a good tool, but this I can't jugde. During these researches I found this easy...
11 Sep 2015 by radnix
Greetings :)I have an application named Test.exe. Inside this application I can immediately get its own name and process ID like this:string processName = Process.GetCurrentProcess().ProcessName; int processID = Process.GetCurrentProcess().Id;Using performance counters, inside...
11 Sep 2015 by Wendelius
Have a look at this[^] answer. As far as I can see, it would help you to locate the correct process and corresponding counter instance.
19 Jun 2011 by thexcodec
I tried to get the CPU Bus Speed and Multiplier(ratio) and found out that I could not via C#.So I am wondering if anyone knows how to get these with C++ without using Win32_ type libraries.
19 Jun 2011 by Albert Holguin
Getting information about the hardware installed on a system (and its operational parameters) is a function controlled by the drivers and operating system. C++, or any programming language, does not have calls to directly interface to hardware installed. Everything is processed via the OS's...
20 Jun 2011 by Harmanjeet Singh
I am not agree with the above solution as it says no to your question. I worked at OS level. the thing you require can be done using the concept Device Driver Programming in windows, using which you can even do firmware level programming.. :)
17 Sep 2012 by AfterShave
How can I calculate the CPU Speed in VB.NET and how to find the CPU Temperature?
17 Sep 2012 by fjdiewornncalwe
I haven't checked out all the links, but here are 225,000 Results[^] for you to start from. Please make an effort to search your question first. We are more than happy to help you with a specific issue you may encounter as you make an effort to get there.
24 Jan 2011 by sunil kumar meena
I am looking for information on how to make a 4-bit CPU? Looking to get some details.
24 Jan 2011 by Nish Nishant
This is one example I got with a quick google:http://www.galacticelectronics.com/Simple4BitCPU.HTML[^]
21 Sep 2013 by Homero Rivera
Hi all!I'm trying to write a program that automatically creates as many threads as the computer can handle (not malware!).How do you create an instance of PerformanceCounter that gets the usage across all CPUs/Cores?All I've seen are examples that work on an individual core.Thank...
21 Sep 2013 by Zoltán Zörgő
In general it is a bad idea to drive a system at it's limits. But what's the problem with having those per core counters? Aggregate them, and you get an overview. I suggest you check both approaches here:...
25 Sep 2013 by Sergey Alexandrovich Kryukov
In case my comments to the question are still unclear: as soon as you have more threads then the CPU cores (which is usually much, much less then the number of threads the system can possibly handle), adding each thread only degrades performance.Threads are used mostly to implement scenarios...
22 Sep 2013 by User 59241
1. To use multiple cores you have to break your computation into multiple threads. The OS can't do that for you. Many problems cannot be broken down so you are left with single threaded, single core computation.2. If you are able to rewrite your computation so that it can be broken into...
6 Sep 2018 by Member 13976376
I'm currently working with a CpuSimulator, and I'm struggling with the instructions below, so some help would be greatly appreciated. "Type a program that reads numbers from IO (input), write them to IO and save them on the stack (PSH) until the user inputs the number 0. Then print the numbers...
6 Sep 2018 by OriginalGriff
a) Is simple: test before you push, not after. At the moment, you read the value, poush it, and then decide to repeat. You need to read it, test, it if it's zero exit the loop, otherwise push and go round again. b) I'm not at all familiar with the assembly code: so I can't be precise. But ......
3 May 2011 by Lutosław
I need to control C-State configuration. Specifically, I'd like to execute the following asm code:__asm { rdmsr and eax, 0x00 or eax, 0x01 wrmsr }Currently, I got this exception on rdmsr line:Unhandled exception at 0x00e3139e in...
20 May 2011 by i.flower
this instruction must be executed at a privilege level of 0.
21 May 2011 by Richard MacCutchan
I think you're out of luck unless you can elevate yourself to Kernel Mode[^].
22 Mar 2022 by Naqib Ullah 2022
first of all I want to get the data from the user after that I want to calculate the average waiting time along with process arrival time as well as process burst time in c++ language. What I have tried: i need this project as soon as possible...
18 Jun 2011 by thexcodec
Hey guys, I am here again with a problem.In my program I need to calculate the current CPU usage.I have searched google and found similar code across multiple websites but it just feels way too complicated for what I need to do AND my CPU never hits 100% usage with this calculation.Not...
18 Jun 2011 by Dr.Walt Fair, PE
Have a look at this link.[^]
25 Apr 2013 by Abhik03
Hi,I want to get the Memory Usage of a particular process in percentage (%). Below is the code which I used for CPU. But I am unable to get the same for Memory. There are so many counters in Memory Performance that I'm confused how to calculate or we can directly get the display in percentage...
26 Apr 2013 by StianSandberg
Hi.1) Open MMC2) File -> Add/Remove snap-in3) In the list of available snap-ins, locate "Performance", mark it and click add4) Expand the treeview and select "Performance" You will then see the performance graph.5) Rightclick the grapch and select "Add counters"Then a windows opens...
15 Mar 2018 by Member 13728029
Write Wombat1 machine language program that converts a number into a radix representation. For example, a number converted into radix 2 or radix 3. The program should be able to convert a decimal number into any radix from 2 to 8. Your program should take two inputs. The first input will be the...
15 Mar 2018 by CPallini
I suggest you to first write the symbolic code (assembly) and then, once your're confident it could work, transform it in machine language. Moreover, start simple: write, at first, a simple converter to radix 2 representation.
15 Jul 2016 by Dan_Suitor
We are experiencing periods of time when CPU utilization of our application goes to %100 percent for several seconds. I tracked this down to two CLR methods which are called when ‘new’ objects are created. The first being ?JIT_New@@YIPAVObject@@PAUCORINFO_CLASS_STRUCT_@@@Z. The second being...
3 Apr 2016 by MYQueries1
As we know that what are the things in the RAM are taken by the Processor to RUN. Who takes up the task of putting the data from HDD to RAM. Is it CPU? If yes It means again the Processor will do that task? I am bit confused can any on explain?Thanks in AdvanceWhat I have tried:As we...
3 Apr 2016 by Kornfeld Eliyahu Peter
What loads data from the storage (disk) to the memory is your application...When you are opening a file and do some read process, you actually load some of that file into a memory structure...The CPU by itself can not access the storage, but only the memory...
3 Apr 2016 by OriginalGriff
Physically? Loads of things, including a whole number of other processors...The HDD data itself is stored in magnetic bits, which are read by a magnetic head which floats a tiny distance above the surface of a spinning disk: small changes in the magnetism of the disk surface are detected by...
1 Sep 2015 by codeprojectddx
I have been confused about this for a long time.As i know ,the thread switch is achieved by windows because of the cpu's support,but i actually donot know the mechanish.Hope a little help .thank you .
1 Sep 2015 by Sergey Alexandrovich Kryukov
Please see my comment to the question.The idea is: you can switch the task with the instructions JMP or CALL, and it can happen by hardware interrupts. The essence of things in not in the switch instruction, but in what's the interpretation of the target address of this instructions. So,...
11 Feb 2017 by Richard MacCutchan
This question is far too broad for a Quick Answers forum. You need to do a lot of research on hardware and software before you can even start thinking about the design. Google will find you lots of articles about facial recognition to start with.
6 Sep 2012 by MR. AngelMendez
Hi, how can I get my program to monitor all CPU usage from my computer.Thanks in advanced.
6 Sep 2012 by Sergey Alexandrovich Kryukov
Total CPU usage? I can tell you right away — 100% ;-)[EDIT]And if you need it not total, but per process, you can use the class from System.Diagnostics.PerformanceCounter:http://stackoverflow.com/questions/278071/how-to-get-the-cpu-usage-in-c[^]Good luck,—SA
6 Sep 2012 by db7uk
there are a couple of examples out there. What have you tried?http://stackoverflow.com/questions/278071/how-to-get-the-cpu-usage-in-c[^]http://blogs.msdn.com/b/dotnetinterop/archive/2007/02/02/system-diagnostics-performancecounter-and-processor-time-on-multi-core-or-multi-cpu.aspx[^]
28 Aug 2013 by sumith sudesan
Is there any methods otherthan performance counter....?
5 Sep 2014 by user8x86
Can I use namespace System.Runtime.Caching in order to modify the properties and values of CPU Cache L1, L2 and L3?msdn.microsoft.com told me the namespace allows create new cache storage in windows like a virtual RAM.But, i wanna program with Cache which is included by CPU. Can you tell...
5 Sep 2014 by OriginalGriff
No, you can't.L1, L2, L3 caches are typically inside the processor silicon in multicore processors: "normal" memory (which is what the System.Runtime.Caching namespace is concerned with) is external to the processor and is not a part of L1, L2, or L3...
5 Sep 2014 by Zoltán Zörgő
What???Do you know what CPU cache is? I doubt. At least read wikipedia: http://en.wikipedia.org/wiki/CPU_cache[^]It would be a disaster if one could modify those cache values. CPU cache and runtime cache is totally different things, on totally different level of functionality regarding...
22 Jun 2020 by Patrice T
Quote: i need to control the cpu and gpu usage by percentage how do i do it? Basically, you don't, it is a bad idea. Such feature is a dream for any malware, that's why it is the OS's job to manage those resources. Said otherwise, it is a bad...
4 Sep 2014 by user8x86
Can you tell me how to calculate the time which CPU had used?Example:----------------------public int Main(){int a, b, c;a = 1; b = 2;return (c = a + b);}----------------------If we ignore these time: compiling, provide varibles storage, load data to...
4 Sep 2014 by Duncan Edwards Jones
The addition is one machine instruction, and copying into a buffer is another so 2 clock cycles is the absolute minimum. So - .00000005 seconds (+/- 100%)
4 Sep 2014 by kavitha3
Hi ,I am not understanding what is your need and why ...But i can redirect u to Mr.Robert's Article.Its about ::How To: Measure execution time in C#[^]::
4 Sep 2014 by Rob Philpott
You can't. Depends on what speed the CPU is clocked at, what instruction set its running, what the JIT does, whether it gets 'inlined' or branched etc.
4 Sep 2014 by user8x86
Your mean is: The time - which Microsoft calculates in order to "swap out" any process and "swap in" another process - is static (Can't be changed)?
22 Feb 2013 by Alireza ghasemi
Hello dearsI want to know a 2.5 GHz CPU how many Calculation can do in every second.
22 Feb 2013 by willington.d
http://answers.yahoo.com/question/index?qid=20091026003012AA9cXIT[^]
26 Aug 2021 by Slow Eddie
How much Ram will an Intel Core I5 10th generation support? I want to increase the ram in my Acer Aspire from 12 GB to 16GB or 32GB. do you have any idea? What I have tried: Going to the ACER support website, but it is useless.
26 Aug 2021 by OriginalGriff
It's not just the CPU you need to check (in fact that's about the last thing!) You need to look at the motherboard - these are normally the limiting factor for RAM fitment, and all the Acer machines I've ever looked at were shipped with the max...
26 Aug 2021 by Dave Kreskowiak
You can find that at Supported Memory Type for Intel® Core™ Laptop Processors[^] But, it's not the CPU that's going to limit the amount of RAM you can use, it's the motherboard.
18 Feb 2017 by Brady Kelly
Just recently my PC's performance has become dismal, I even got about 10 'pauses' in the editor while typing these two sentences. Now if I used Process Explorer, I can sort by CPU, memory, and IO, descending, so the culprits are always visible at the top of the table.The problem with that is...
18 Feb 2017 by Mehdi Gholam
You shouldn't get "pauses" on Windows 10 since the scheduler is pretty good, however:1) Pauses could indicate cpu heat problems, so check your system's fans and clean and lubricate them (WD40 is excellent).2) Disconnect from the internet and see if you still have problems.3) Update your...
22 Apr 2013 by Abhik03
I want to store the CPU and Memory Utilization of all the individual tasks after every 5 mins. from the task manager into a DB, say SQL Database. Is it possible to write a console application in C# which can accomplish this task and store the utilization in SQL Table.
22 Apr 2013 by Sergey Alexandrovich Kryukov
You can get this information is you use System.Diagnostics.PerformanceCounter:http://msdn.microsoft.com/en-us/library/system.diagnostics.performancecounter.aspx[^].You can use this introductory CodeProject article to see how to do things: An Introduction To Performance...
22 Apr 2013 by Zoltán Zörgő
Actually all the information you got so far is correct:- Task manager is just a tool to display data. It is not collecting anything- In the background of task manager (and others like this) are system level tools, like WMI, as Mike Meinz highlighted.- And you can access them easily also...
20 Nov 2018 by Apriorit Inc, Artem K.
Find out approaches which you can use to improve runtime algorithms for zero-day threat detection
6 Sep 2014 by user8x86
Can you tell me how to view the addresses of variables in CPU registers address?p/s: The address can be useful for my assembly project.Thanks for solutions!
6 Sep 2014 by OriginalGriff
Um.CPU registers don't have addresses: they aren't part of the "normal" memory, they are specific places in the processor which can hold values (normally but not necessarily integer) which can be interpreted as memory addresses. But except for some rather odd processors you cannot take the...
7 May 2023 by ToughDev
Hyper-V & Hardware Assisted Virtualization
26 Mar 2014 by Naim_86
Dim check As Thread Private Sub RunThread() Dim newThread1 As New ThreadStart(AddressOf Checkdata) check = New Thread(newThread1) check.Start() End Sub Private Sub Checkdata() Dim dt As Date Dim dset As DataSet Dim prr() As...
26 Mar 2014 by Dave Kreskowiak
Put a Thread.Sleep(15000) just before your Next statement.This will force the thread to go to sleep for 15 seconds freeing up the CPU to do other things.Ummm...What's with the Application.ExitThread(), Application.Exit() and Application.DoEvents() calls? You don't need any of them. Get...