Apple Intelligence now features Image Playground, Genmoji, Writing Tools enhancements, seamless support for ChatGPT, and visual intelligence.

Apple Intelligence has also begun language expansion with localized English support for Australia, Canada, Ireland, New Zealand, South Africa, and the U.K. Learn more >

You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Changing the number of CPU Cores running

I want to change the number of cores the CPU uses. One minute I might want all 4 cores running the next only 1 core then back to 3 for example.


I have searched in the hope there was a terminal command that would reduce the cores, not at restart but immediately.

Is anyone aware of one?

________________


I can succeed using Xcode/Contents/Applications/Instruments.app/Preferences/CPUs giving me a slider to change the cores.




When the slider is clicked with the mouse to change the number of cores it requires user and password.



I have managed to run most of the process with Automator/AppleScript but this request for user and password is proving difficult.


In order to avoid it asking I have tried:


entering <DevToolsSecurity –enable> in Terminal; and


put both Instruments.app and XCode in


System Preferences/Security & Privacy/Accessibility


without effect.


Is there a way to avoid this request for user/password but still have the slider change the number of cores?

-------------------------------

Any other suggestions for changing the number of cores at any given time, not just for a process but the complete computer, would be welcome?

-----

Imac, MacOS Mojave


 

Earlier Mac models

Posted on Aug 16, 2023 4:50 AM

Reply

Similar questions

8 replies

Aug 16, 2023 6:31 AM in response to Need_help_give_help

Need_help_give_help wrote:

Also Apple must think it worthwhile as it has put it as an option in XCode.

It is worthwhile in Xcode because so that developers can test multithreaded code on a different number of processors. Otherwise, the developer might not notice a performance problem on their 24 CPU computer when it is running on a quad or dual core.


Also, you seem to be running on an ancient version of Xcode. Apple has removed that CPU option. The whole idea of multithreaded code doesn't have much meaning on modern computers.

Aug 17, 2023 1:13 AM in response to MrHoffman

Thanks MrHoffman for taking the time to respond. Yes hypervisor isn't the same thing I am trying to achieve.


I don't understand: “macOS doesn’t allow this sort of access into the scheduler past Xcode Instruments.”

as, to clarify, I am able to change the cores in Xcode/instruments/preferences/cpu.


I am hoping to get rid of the request for user and password by allowing perhaps XCode or Instruments  some special permission so it doesn't ask for the user/password when I select the core/slider.

Sep 3, 2023 5:28 PM in response to Need_help_give_help

Hey I want to change the amount of cores I am using and I've downloaded Xcode and all that but when I run the command

Xcode/Contents/Applications/Instruments.app/Preferences/CPUs

It says that I do not have the files. I am kinda new to the Apple computer industry and was looking for some help.


Thanks,

Rambo


Edit: preferences does not exist

Edit2:figured it out 😂

Changing the number of CPU Cores running

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.