Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8715783
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T05:55:43+00:00 2026-06-13T05:55:43+00:00

The CPU is designed to drop into low power modes whenever it can to

  • 0

The CPU is designed to drop into low power modes whenever it can to save power and keep cool, I’d like to make a program to prevent that from happening.

I’m working on a few different embedded platforms (Freescale Coldfire 8052, TI Sitara AM3359, probably a few others in the pipeworks) and so I wanted to make an application that will just keep the CPU fully loaded for benchmarking. I want to write my own since it would be easier to cross-compile then to look for a solution per target.

My initial thought was just:

while(1);

Question 1:
But at I over simplifing this? top shows that program taking about 99.4% CPU usage, so I guess it’s working, but it doesn’t seem like it should be so simple. 🙂 Anyone know if there should be more to it than that?

Question 2:
If I wanted to expand this to do different loads (say, 50%, 75%, or whatever) how could I do that? I managed to get a 18~20% CPU usage via:

while(1){usleep(1);}

Is there a more, scientific way rather than just guessing and checking at sleep values? I would think these would be different per target anyway.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T05:55:45+00:00Added an answer on June 13, 2026 at 5:55 am

    while(1); will eat up all your CPU cycles but won’t exercise most parts of your CPU (let alone the GPU). Most modern CPUs have the ability to selectively switch off individual execution units if they’re not used: the only way to prevent it is:

    1. tell the CPU/SoC driver to disable power saving
    2. exercise all control and execution units of your CPU/GPU/chipset/etc.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Have advancements in CPU design like dynamic instruction scheduling narrowed the performance gap between
I wrote a monolithic designed program which is quite rough on the processors needs.
Can CPU Cache still be utilized for memory use by the programmer while it
Taking CPU affinity into account, will such an environment be useful with threading? Or
When CPU uses its program counter to fetch next instruction, does the address of
CPU Switches from User mode to Kernel Mode : What exactly does it do?
I have this (working) CPU code: #define NF 3 int ND; typedef double (*POT)(double
I want to record Cpu usage ,cpu time ,VM size in notepad per minute
What do the terms CPU bound and I/O bound mean?
Every new generation of CPU introduces some sets of new instructions, i.e. MMX, 3DNOW,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.