mercurysquad Posted August 5, 2008 Share Posted August 5, 2008 New version 1.3.2 is now available! New page for all downloads/bug reports is here. INFO:We have switched to Google Code. Downloads from this post have been removed. Info on this page may be outdated. Everyone's encouraged to use the google code page instead. -------------------------------------------------------------------------------------------------------- N/2 bus ratio support giving most users <1GHz pstates. Undervolting support, sse2 rtcfix kernel support, direct ctl change, Pstate override, default pstate, bug fixes. Kernels on which it will work: any. Thanks to the help of people over on #xnu-chat, an experimental Intel SpeedStep driver is now available which doesn't require a speedstep kernel (ie. it should work well with sleep kernels and allow you to resume/sleep). It will work on any Intel processor which supports speedstep (including older Pentium M). However, timing might be unstable on older processors (being fixed), so Core or higher is highly recommended. Note that it will not magically give sleep/resume ability to your speedstep kernel. Please switch to a sleep or vanilla kernel. NO AMD SUPPORT. We need more testing before it can be termed a working kext. Please download the attached zip, unzip it and do in Terminal: sudo kextload IntelEnhancedSpeedStep.kext You don't need to put it in /System/Library/Extensions for testing. Then use any SpeedStep GUI. Two of them are attached, use whatever you like. Once you are satisfied, put it in /S/L/E and it should load everytime you boot up. Here is more specific info about how to install the kext and use the SpeedStep app If you experience problems with GUI apps, simply close it and use the terminal to test. A lot of people are reporting problems with the speedstep.app and cputhrottler2beta apps. These were NOT created by me and this is not what we are testing. So please, close those apps and try manually throttling using terminal. An updated SpeedStep.app is in the works, tuxx will provide more info on it. A beta is uploaded but NO support yet until it's finished. To see which frequencies are available: sysctl kern.cputhrottle_freqs To switch frequency: sudo sysctl -w kern.cputhrottle_curfreq=YYYY (replace YYYY with what you want from the list you got. You can also set a single digit number directly which is the frequency (pstate) number: 0 is highest speed, 1 is next lowest etc. What to test - 1) That you can actually switch CPU speed 2) Whether your timing is stable (ie. OSX UI/animations should be smooth, not stuttering in audio) 3) Test whether you can still sleep and then resume - if your sleep/resume worked before > Make sure you unload ACPICPUThrottle.kext and/or AppleIntelCPUPowerManagement.kext before loading this! < To get debug log messages, type this in Terminal: sudo dmesg | grep IntelEnhancedSpeedStep If it doesn't work for you, paste on pastebin the output of the above command, and of sysctl machdep.cpu && uname -a , then post the URL here. To get information about the current freq/voltage and available freq/voltage, type sysctl -a | grep throttle INFO From all the bug reports and debug logs, I have come to the conclusion: ACPI SUCKS. So I have halted debugging ACPI autodetect of p-states. It is good enough now for 80% of users. For the remaining 20%, please create your P-states manually in steps of 2xFSB. Next up: support for <1Ghz speed on supported kernels, and auto-throttle. New features/fixes : 1.3.2 - fix a bug which displayed incorrect current frequency value when using n/2 bus ratio 1.3.1 - fixed certain issues with <1ghz support 1.3 - N/2 bus ratio support, should provide <1GHz pstates to most people. Note that if you have sse2, this will be enabled ONLY if you are using a kernel which supports <1ghz properly. Currently the only such kernel is my kernel 9.4 which is not released yet. :-) - Excessive debug messages are now removed. Should fix stuttering while changing frequency - Added extra IODelay after switching pstate so that sysctl displays the new values. This should make people happier. - Minor internal fixes. 1.2.2 - Better kernel feature detection. Better clock recalibration. 1.2.1c - Kernel feature autodetection, override via Info.plist key "KernelFeatures" in IOKitPersonalities. Set to -1 for autodetect (only works with new kernels which are NOT out yet), 0 = no speedstep,1ghz+, 1=speedstep kernel,1ghz+, 2=speedstep kernel,less than 1ghz support. - No more phantom PStates (e.g 2401 mhz) - Default Pstate during bootup/load, set DefaultPState key in Info.plist, -1=no default, 0=pstate0 is default etc. - Doesn't allow <1 ghz throttling unless patched kernel supports it (vanilla/sleep kernels dont) 1.2.0 - Added delay for latency while switching pstate - should fix people not being able to switch frequencies consistently - Undervolting! New sysctl key kern.cputhrottle_curvolt to change the current voltage. Setting will be remembered for that pstate. - Added sysctl key kern.cputhrottle_ctl for direct changing of fid/vid: only for testing!! Settings will not be remembered - Load PState table from kext's info.plist! For those who get "There was an error getting Pstate table from ACPI". To use this, open the kext's Info.plist in property list editor. Expand IOKitPersonalities/IntelEnhancedSpeedStep and you will see PStateTableDisabled. It is an array of arrays. Each element is one pstate. Each pstate has 2 elements, first is the frequency in MHz and 2nd is voltage in mV. If you change the name of the array to PStateTable, it will be loaded by the kext instead of autodetecting via ACPI. NO error checking so make sure it's valid for your CPU. 1 Link to comment Share on other sites More sharing options...
joe75 Posted August 5, 2008 Share Posted August 5, 2008 nice job, mercurysquad Link to comment Share on other sites More sharing options...
Krazubu Posted August 5, 2008 Share Posted August 5, 2008 Nice work The system and sound stutter when the mode is set to manual in the AC pan of the CPU throttler. CPU is C2D E6650 Link to comment Share on other sites More sharing options...
mercurysquad Posted August 5, 2008 Author Share Posted August 5, 2008 Nice work The system and sound stutter when the mode is set to manual in the AC pan of the CPU throttler. CPU is C2D E6650 Will look it up. And quick tip for anyone else suspecting it's due to speedstepping: check dmesg - sudo dmesg | grep IntelEnhanced. If such stuttering is expected on your system, there will be a WARN message saying so. Also: if it doesn't work at all for some people, check sudo dmesg, if it says "There was an error getting PState table from ACPI" - this is a known issue. We are working on manually overriding your frequency/voltage tables, kext will be out soon. Link to comment Share on other sites More sharing options...
titooo Posted August 5, 2008 Share Posted August 5, 2008 Thanks for the application man. I think it's a great advance as it will let us have "vanilla kernel + speedstep options"(which till now only was possible using Coolbook, which cost 10$) or "sleep kernel + speedstep options". But unfortunantely I couldn't test it till Asus repair my laptop... Link to comment Share on other sites More sharing options...
nobb1x Posted August 5, 2008 Share Posted August 5, 2008 tried it, at the start it gave me 5 p-state (see log) but using tuxx speedstep app it never hit the 800mhz one,and use the 1200mhz as lower one, i don't know if this is usual. trying some cpu intensive applications it seem to switch the speed, while using itunes it make the experience very bad,with continue stuttering. Closing the Speedstep.app the stuttering has gone, so i'm unsure if the problem is related to that app or at the kext. usually i use the ACPICPUThrottler for speedstep and never seen that problem (stuttering i mean) Cputhrottler2beta2 crashes my system so i can't try it, i lost the keyboard and mouse after a while i start it. some infos about my system notebook Compal FT00 C2D 2ghz (7250) macos 10.5.3 toh kernel 9.2.0 (speedstep) i didn't tried sleep/resume, but i has never worked before too. Have a good work!! test.zip Link to comment Share on other sites More sharing options...
Krazubu Posted August 5, 2008 Share Posted August 5, 2008 I forgot to say that sleep mode still doesn't work, but it never worked btw, the mobo is an ASUS P5B with intel 965 Link to comment Share on other sites More sharing options...
kennyp Posted August 5, 2008 Share Posted August 5, 2008 Nice, very nice! Compaq c714nr using Vanilla kernel 9.4.0, in 10.5.4 kext in working great. Using CPU Throttler2Beta2 I an sitting at 800 mhz and it auto steps to 1067 and 1467. No change with sleep....(goes to sleep ok, but on wake cpu fan does not return to active) As I said before, nice! KennyP Link to comment Share on other sites More sharing options...
mrheat Posted August 5, 2008 Share Posted August 5, 2008 hi here my results - check my sig for hardware details http://pastebin.com/ma91d66c keep up the good work! regards, mrheat Link to comment Share on other sites More sharing options...
eclau Posted August 5, 2008 Share Posted August 5, 2008 After loading IntelEnhancedSpeedStep.kext, I did the following in Terminal: sudo -s chown root /Applications/SpeedStep.app/Contents/MacOS/SpeedStep chmod +s /Applications/SpeedStep.app/Contents/MacOS/SpeedStep But SpeedStep did not launch. Can someone help? Thanks! CPUThrottler2 was unable to detect my CPU frequency... showing 0 all the time. Link to comment Share on other sites More sharing options...
nobb1x Posted August 5, 2008 Share Posted August 5, 2008 After loading IntelEnhancedSpeedStep.kext, I did the following in Terminal:sudo -s chown root /Applications/SpeedStep.app/Contents/MacOS/SpeedStep chmod +s /Applications/SpeedStep.app/Contents/MacOS/SpeedStep But SpeedStep did not launch. Can someone help? Thanks! CPUThrottler2 was unable to detect my CPU frequency... showing 0 all the time. it don't start automatically, you need to start by hand, if you want it start with the system you need to follow this: (from the readme) Now go to System Preferences/Accounts click on lock(if it is locked), select Logins Items, and then click on + to add speedstep.app, browse to applications select speedstep.app and click add, and check that box. btw, if it don't start, be sure the speedstep kext load, check the system.log to view or type sudo dmesg after the kextload. Link to comment Share on other sites More sharing options...
dasepsilon Posted August 5, 2008 Share Posted August 5, 2008 hell of a kext! working great (at least up to now, i.e. 3 minutes ) THANKS A LOT!! (i'm on a dell xps 1330 with some intel core 2 duo, t5750 or something) Link to comment Share on other sites More sharing options...
mercurysquad Posted August 6, 2008 Author Share Posted August 6, 2008 Thanks to all those who tested! Some issues have been fixed, a new beta will be put up soon. Some general answers: tried it, at the start it gave me 5 p-state (see log) but using tuxx speedstep app it never hit the 800mhz one,and use the 1200mhz as lower one, i don't know if this is usual. This is being investigated. Apparently most such processors can't really go below 1Ghz but report 800mhz anyway. trying some cpu intensive applications it seem to switch the speed, while using itunes it make the experience very bad,with continue stuttering. From your log it definitely seems to be the app - it is switching Pstate several times a second, and since the kext locks the CPUs while switching, you will of course experience stuttering. Please try using manual switch method (sysctl -w ... described above). i didn't tried sleep/resume, but i has never worked before too. It can't fix your sleep/resume, it will just not mess with it if you could sleep/resume before. Link to comment Share on other sites More sharing options...
JimDandy Posted August 6, 2008 Share Posted August 6, 2008 Thanks for this. The kext works on my machine, but throttling using either of the programs causes poor performance, in my case with ITunes (what I tried). I was using either one set to automatic throttling. Also, I get only four steps for a 1.6 cpu. Link to comment Share on other sites More sharing options...
eclau Posted August 6, 2008 Share Posted August 6, 2008 Not working on Q6600 overclocked to 3.0GHz on Gigabyte P35-DS4 http://pastebin.com/mefe5b2 Thanks! Link to comment Share on other sites More sharing options...
westwaerts Posted August 6, 2008 Share Posted August 6, 2008 I forgot to say that sleep mode still doesn't work, but it never worked btw, the mobo is an ASUS P5B with intel 965 strange because on my p5b sleep works ( manually and auto), but restart and shutdown only randomly. Link to comment Share on other sites More sharing options...
r_o_o_s Posted August 6, 2008 Share Posted August 6, 2008 Thank you! This is the beginning of fixing one of the two remaining thing that are not working on my D830. The kext loads fine. Tuxx doesn't start for some reason but cputhrottle2beta2 does. The cpu is a t7300 and i detect the following modes: 800 1200 1600 2000 2001 (!) Neither of the 800 or 2001 modes work but the rest of them do. Sleep still works fine. The sound is affected when switching freqs, but only just as it happens. Link to comment Share on other sites More sharing options...
timmyj Posted August 6, 2008 Share Posted August 6, 2008 thanks for this works a treat, to get the tuxx to start u need to chmod +x SpeedStep.app/Contents/MacOS/SpeedStep but then if u want to remove the prompt for password run sudo -s chown root /Applications/SpeedStep.app/Contents/MacOS/SpeedStep chmod +s /Applications/SpeedStep.app/Contents/MacOS/SpeedStep Link to comment Share on other sites More sharing options...
mitch_de Posted August 6, 2008 Share Posted August 6, 2008 Works here. E4400 2.0GHZ , (little overclocked by FSB), so 1398 to 2333 MHZ with that stepping. MSI P965-NEO F, VANILLA 10.5.4 Kernel The speedtesp app works also. ( Thanks for the hint avoid everytime admin password input) The CPUTrottler2Beta, first didnt alow me to run any new app (only the running apps worked ), also sometimes no CTB2 window came up after starting CPUTrottler2Beta, after a few seconds it asked for admin password and mostly then the window came up. But not always. No error logs for that "no window" thing in the console. Only some messages about an fork() problem (running first time CT2B, try to start Xbench,... ). I had to close CT2B first, and restart CT2B again to run the Apps my tried to start apps 06.08.08 12:23:05 com.apple.launchd[162] ([0x0-0x82082].com.spiny.xbench) fork() failed, will try again in one second: Resource temporarily unavailable (xbench cant start up) 06.08.08 12:23:15 com.apple.launchd[162] ([0x0-0x84084].com.realtech.openglex) fork() failed, will try again in one second: Resource temporarily unavailable (..cant start up) 06.08.08 12:23:57 com.apple.launchd[162] ([0x0-0x85085].com.mechanicalpants.CPUHistory) fork() failed, will try again in one second: Resource temporarily unavailable But even Systemevents coundnt run (until i closed CTB2) 06.08.08 12:24:26 com.apple.launchd[162] (com.apple.PreferenceSyncAgent) fork() failed, will try again in one second: Resource temporarily unavailable 06.08.08 12:24:38 com.apple.launchd[162] ([0x0-0x86086].com.apple.iCal.helper) fork() failed, will try again in one second: Resource temporarily unavailable 06.08.08 12:24:56 com.apple.launchd[162] (com.apple.PubSub.Agent) fork() failed, will try again in one second: Resource temporarily unavailable After i closed CTB2, the apps all can start normal and after that i didnt get that problem again. So can i use Speedtep app + your great .kext ? Or does i need the CTB2 app also for config the .kext ? Also i am a bit confused (perhaps its now not implemented) about saving profile. CTB2 never saved it , so it had to config the setttings alyways again. Default was always Manual: 1398 , Dynamic 1398/1398. HINT: Checking if the .kext works . Xbench is super for that, because if set to dynamic stepping, you can see that XBENCH (need to run only CPU+MEM Tests) the first CPU Bench Value is always worst, the trottler need some time to adjust to higher MHZ and the CPU Bench runs very fast. After 0.5 sec i think its runnung full MHZ and the values are same as without stepping as max. MHZ. Question: I can see that if wether Speedstep nor C2TB2 running, the .kext didnt step anymore up/down (fixed MHZ as last stepping). Is that right ? GREAT THING !!!! Link to comment Share on other sites More sharing options...
wingrunr21 Posted August 6, 2008 Share Posted August 6, 2008 Ok, it works for me with a few quirks: No errors show up in dmesg other than the debugging message reporting throttling. I am getting a few "glitches" with my mouse. It seems it will lag for a second and then it will jump to the correct location on screen. I have to run CPUThrottler2 three times to get it to work properly. The first time it opens it just sits at 1200 mhz no matter what. The second time it will throttle until I remove the AC adapter and then just stop. The third time it works fine. The other oddity with that program is that when it is running I cannot use a bash prompt. It seems like it is locking up all tty sessions for some odd reason. Another very fast test for CPU throttling is to do a cat /dev/urandom > /dev/null from a terminal. That should quickly move your CPU up to full throttle. Link to comment Share on other sites More sharing options...
mercurysquad Posted August 6, 2008 Author Share Posted August 6, 2008 Not working on Q6600 overclocked to 3.0GHz on Gigabyte P35-DS4 http://pastebin.com/mefe5b2 Thanks! Can you please post the output of sudo dmesg after loading the kext? Thanks. Also check your BIOS whether it has speedstep enabled. Link to comment Share on other sites More sharing options...
mitch_de Posted August 6, 2008 Share Posted August 6, 2008 Seems to be very "cool" also for desktop users with overclocked CPUs. If nothing to do, CPU can cool down more than with C1E (in BIOS enbaled/disabled like enhanced speedstep enabled/disabled). Q: Does CE1 CPU engergiesaver works beside speedstep (bios of mainboard manage that) or does it nothing running OS X ? PROBLEM: Aftera view minutes working speedtep app quits (no more in menu). Only that message in the syslog, no dmesg of your .kext. login[2438]: DEAD_PROCESS: 2438 ttys000 (i know that 2438 was speedstep). Now i will try CTB2 running insted of speedstep. Working since 15 minutes without quitting like speedstep. Only asking every 5 Min for admin pwd, i made the same trick to (sudo .....) as hint above some posts. Link to comment Share on other sites More sharing options...
wingrunr21 Posted August 6, 2008 Share Posted August 6, 2008 This is an update from my previous post. Using SpeedStep.app is a lot better than the CPUThrottler. Mouse lag is non-existent or at least not noticeable except for when then CPU changes frequency. There is still a slight lag but otherwise rather smooth. One interesting thing to note is that the kext is picking up an 800 mhz throttle level and a 2601 mhz throttle level. Neither one of these levels work. Here are the levels that do work: 1200 1600 2000 2600. Link to comment Share on other sites More sharing options...
mitch_de Posted August 6, 2008 Share Posted August 6, 2008 Now 2 hours later, all is OK. CTB2 is running and has not quit as SpeedStepp app. Also stepping has worked all the time without any problem. Link to comment Share on other sites More sharing options...
eclau Posted August 6, 2008 Share Posted August 6, 2008 Can you please post the output of sudo dmesg after loading the kext? Thanks. Also check your BIOS whether it has speedstep enabled. The following items in BIOS are enabled: CPU Enhanced Halt (C1E) CPU Thermal Monitor (TM2) CPU EIST Function Output of sudo dmesg: http://pastebin.com/m18674818 Also, same problem with E7200. Link to comment Share on other sites More sharing options...
Recommended Posts