(Q) kernel profile. - Thunderbolt Q&A, Help & Troubleshooting

Sorry I've searched around. Can someone explain what smartass does ? On a kernel or how it interacts?
Interactive set up also?
Using adryn bamf rom 1.3. This is my first time messing with setcpu. He said to set it back to 1ghz is to use it but it only goes to 1032 close to 1. I don't really like overclockihg since the phone is fast as it is. Sorry for the noobish question thx again.
Sent from my ADR6400L using XDA Premium App

In a nutshell, smartass is a type of governor that controls the scaling of the procesor speed and controls the idle loop.
What does a governor do? Well, while a processor may be rated at 1.0 GHz, it is not runnng at full speed all the time. It only runs at that full 1.0 when called upon to do so for various intense functions and calculations. The rest of the time, when the phone isn't required to be doing much, the processor "underclocks" itself to conserve power, minimize heat, and prolong the life of the chip. It's like driving a car: You don't floor the gas pedal and constantly keep the engine at 8,000 RPM all day, and so it is with processor scaling.The governor is what controls this latter part. And there are several different types of governors out there that control the scaling in different ways
Interactive is one type of governor that takes command of the idle loop. Smartass sort of doubles down on that same concept, but is more responsive. Smartass also allows for the kernel to cap the max frequency when the phone is sleeping (screen off). This prevents the need to create sleep profiles while reducing power draw, so it improves battery life
While we're on the subject, a few other terms you may want to know since you'll start seeing them soon are BFS (brain f-ck scheduler - pardon the french) and CFS (completely fair scheduler). These are two types of task schedulers that linux kernels use to control task management. Again, in a nutshell, BFS generally is faster, but lags when multitasking, while CFS is slightly slower, but can handle multitasking a little better

Hey thankbyou bro for taking time to explain this. I really appreaciate it. Now I can set up setcpu and actually understand some terms lol. Thx
Sent from my ADR6400L using XDA Premium App

Related

Overclocked-UV-Kernel-Battery Life Without Set-CPU

If you are using one of the Over-Clocked Undervolted Kernels please uninstall set-cpu and observe your battery life for 3 days and compare it to what you got when you used set-cpu. Then report as to if it is better, worse, or the same.
Just compare to what how long your battery lasts with your normal usage. Please do not give replies like "I only used 30% in two days with normal use."
Just reply with either better, worse, or same. Because usage is relative and that is not the purpose of this.
I think that set-cpu is interfering with the built in govenor and its ability to scale the freq of the phone. I think that it is staying on what-ever freq you set in set-cpu and scaling properly and thus reducing the battery life, and making the undervolting useless.
IF YOU BELIEVE YOU HAVE BETTER BATTERY LIFE WITHOUT SETCPU, THEN GET LOGS WHILE IT IS RUNNING AND SEND THEM TO THE DEV.
I have also noticed lag on the home screen with setcpu, I started using Overclock Widget to detect the values and to diff freq screen off 245-576 and put the phone on sleep while charging so will stay cool. Battery life has been great so far! I'm using 2.6.33.4 [email protected] #1 about to upgrade to his newest 2.6.34...I think SetCpu has flaws!
Will let you know my results.
this thread may be of some help. im currently trying pershoots 5.12vfp release without setcpu at all.
i do, however, remember getting 37 hours with moderate use with setcpu and profiles set, but i cant remember which kernal it was exactly. i think it may have been IRs 4.29 release..
Just uninstalled SetCPU and I'm running Pershoot's newest 2.6.33.4 925 Kernel. I will report back my findings in a couple of days...
Been curious about this for a while, but does the Nexus automatically throttle CPU speed by itself when SetCPU is not installed?
paulk_ said:
Been curious about this for a while, but does the Nexus automatically throttle CPU speed by itself when SetCPU is not installed?
Click to expand...
Click to collapse
Nope, incredible and onwards only.
Did this Quite a bit ago... ran with and without for over a week and i have better battery life without setcpu
When you don't have setcpu, you're not running at 1113ghz..
persiansown said:
When you don't have setcpu, you're not running at 1113ghz..
Click to expand...
Click to collapse
Perhaps...However, Linpack is proportional (I think) to the device's performance. My little experiment was testing different frequency kernels and measuring that against Linpacl
998: 7.4
1.13: 8.2
1.19: 8.9
So it would appear that performance increases with each kernel which wouldn't be the case if SetCPU was required.
I have some reasons to believe that SetCPU would interfere with the actual design of the Nexus One. I mean after all, i'm sure it was programmed to manage itself. So why have another app that does the same thing, twice? Just a thought, but for one thing, my phone is definitely cooler when charging compared to having SetCPU with profiles.
dogiedogie said:
Nope, incredible and onwards only.
Click to expand...
Click to collapse
You mean that the Incredible features CPU throttling?
jlevy73 said:
Perhaps...However, Linpack is proportional (I think) to the device's performance. My little experiment was testing different frequency kernels and measuring that against Linpacl
998: 7.4
1.13: 8.2
1.19: 8.9
So it would appear that performance increases with each kernel which wouldn't be the case if SetCPU was required.
Click to expand...
Click to collapse
There are dozens of potential optimizations that can be done to improve performance without touching the cpu speed. Different kernels, especially if they're from different people, will have different flags set in the build and so will perform differently even at the same clock speed.
Casao said:
There are dozens of potential optimizations that can be done to improve performance without touching the cpu speed. Different kernels, especially if they're from different people, will have different flags set in the build and so will perform differently even at the same clock speed.
Click to expand...
Click to collapse
I completely agree however all the kernels I use are from the same person and the optimizations at the different clocks speeds are identical. Therefore the spread in my linpack scores indicate that setcpu is not required. At least, that's my theory
this and other threads have made me question why we need setcpu anyways. I have it running and its great but can't we just integrate what setcpu is doing from the get go instead of having an external app running a separate process?'seems a little inefficient to me. The reason I say this is that I noticed most people are using the same settings for set cpu.
anyways, I dunno how relevant all this is since froyo's just around the corner and that may alleviate some problems but bring more problems
Yeah, start bashing my app, knowing I was the one who came up with the ideas behind the 1113MHz/uv hack in the first place (in fact, I came up with the 21MB hack as well, so prominently displayed in the OP's kernel thread title). Thanks, nexus one community.
I can explain that setcpu does not run any code in the background if your profiles are disabled, I can explain how cpufreq works, I can explain what lengths I went to to optimize the profiles, and I can explain that the profiles are very passive (except sometimes on the Droid, but there's an option for tweaking that) but I probably won't bother. Grab 1.5.3a and use it, or don't use it. I don't care either way.
I think that set-cpu is interfering with the built in govenor and its ability to scale the freq of the phone. I think that it is staying on what-ever freq you set in set-cpu and scaling properly and thus reducing the battery life, and making the undervolting useless.
Click to expand...
Click to collapse
You obviously do not know how cpufreq works. Setcpu does not touch the values after it sets a profile. Profiles actually run code only when it receives broadcast intents. It sets the max and min bounds and the governor if necessary within a fraction of a second. The service is completely idle otherwise. It can't "interfere with the built in governor." Okay, then. What is your big theory? What exactly is setcpu doing wrong?
SetCPU is advantageous because it allows you to tweak speeds on the fly and based on certain conditions. You can have solely kernel based overclocking and undervolting, sure, and that is perfectly fine. SetCPU is a convenient tool for controlling that without having to compile and flash a new kernel. If you do not like profiles, do not use them. They were only introduced in 1.3.0 But don't uninstall SetCPU because it does nothing with profiles disabled.
dogiedogie said:
Nope, incredible and onwards only.
Click to expand...
Click to collapse
HTC implements a rather awkward driver in nearly all of their Sense UI devices (and I think the Magic 32A) that throttles based on certain conditions. I am not entirely sure how it works, as I have not looked into the specifics, but it seems to max out the CPU under some conditions.
chowlala said:
I have some reasons to believe that SetCPU would interfere with the actual design of the Nexus One. I mean after all, i'm sure it was programmed to manage itself. So why have another app that does the same thing, twice? Just a thought, but for one thing, my phone is definitely cooler when charging compared to having SetCPU with profiles.
Click to expand...
Click to collapse
I am 100% sure this is placebo effect. Setcpu can't make your phone run hotter just because it's there. If you had a charging profile set for 1113/1113, sure, but that is not setcpu itself. Linux does not control the CPU scaling any further than what ondemand does - there is nothing preventing the CPU from going up to your max during sleep (or rather, when the screen is off), for example, or when your battery is low.
Oh, and using the active widget is a bad idea if you care about battery life. I tried to optimize it as much as possible, but realize that it's updating a lot more things than other apps are (the frequency, the bounds, and two temperature readings) at a relatively fast interval. The home screen does pause a bit while it is updating. That is a fact of life. Longer intervals are essentially useless because the update interval for cpufreq itself is on the order of thousands of microseconds. The current appwidget refreshes if the screen is on, regardless of whether it's visible or not (there is currently no way to tell if it is visible). A live wallpaper would be a much better idea than a constantly updating appwidget, and I'll look into that.
Let me explain this bit better. Cpufreq will scale your CPU between the max and min values automatically. Once the CPU load hits the "up threshold," it takes your CPU frequency from the min to the max, then gradually eases it down. SetCPU lets you easily change the max and min values on the fly. If you want, it can also prevent the system from scaling the CPU up that high during times you don't want it to (with profiles, of course). It does not and cannot interfere with the actual governor.
Well there you have it, straight from the source
TL;DR - setCPU doesn't run code in background unless you use profiles, it doesn't make your phone hotter unless you use a 1113/1113 profile, & if you value battery life don't use setCPU Active widget.
SetCPU
coolbho3000 said:
...
Click to expand...
Click to collapse
Props dude. Keep up the good work.
To be honest I'm a user, donator and supporter of SetCPU. I've never had cause to complain.
Not bashing your app dude, in fact I have the paid version. I am only wondering why people are noticing better battery life without it than with it. Want to see if it really is setcpu or something else. To do that something has to be isolated.
And I believe that if the freq are set in the kernel then the phone will scale up an down on its own.
coolbho3000 said:
Yeah, start bashing my app, knowing I was the one who came up with the ideas behind the 1113MHz/uv hack in the first place (in fact, I came up with the 21MB hack as well, so prominently displayed in the OP's kernel thread title). Thanks, nexus one community.
I can explain that setcpu does not run any code in the background if your profiles are disabled, I can explain how cpufreq works, I can explain what lengths I went to to optimize the profiles, and I can explain that the profiles are very passive (except sometimes on the Droid, but there's an option for tweaking that) but I probably won't bother. Grab 1.5.3a and use it, or don't use it. I don't care either way.
You obviously do not know how cpufreq works. Setcpu does not touch the values after it sets a profile. Profiles actually run code only when it receives broadcast intents. It sets the max and min bounds and the governor if necessary within a fraction of a second. The service is completely idle otherwise. It can't "interfere with the built in governor." Okay, then. What is your big theory? What exactly is setcpu doing wrong?
SetCPU is advantageous because it allows you to tweak speeds on the fly and based on certain conditions. You can have solely kernel based overclocking and undervolting, sure, and that is perfectly fine. SetCPU is a convenient tool for controlling that without having to compile and flash a new kernel. If you do not like profiles, do not use them. They were only introduced in 1.3.0 But don't uninstall SetCPU because it does nothing with profiles disabled.
HTC implements a rather awkward driver in nearly all of their Sense UI devices (and I think the Magic 32A) that throttles based on certain conditions. I am not entirely sure how it works, as I have not looked into the specifics, but it seems to max out the CPU under some conditions.
I am 100% sure this is placebo effect. Setcpu can't make your phone run hotter just because it's there. If you had a charging profile set for 1113/1113, sure, but that is not setcpu itself. Linux does not control the CPU scaling any further than what ondemand does - there is nothing preventing the CPU from going up to your max during sleep (or rather, when the screen is off), for example, or when your battery is low.
Oh, and using the active widget is a bad idea if you care about battery life. I tried to optimize it as much as possible, but realize that it's updating a lot more things than other apps are (the frequency, the bounds, and two temperature readings) at a relatively fast interval. The home screen does pause a bit while it is updating. That is a fact of life. Longer intervals are essentially useless because the update interval for cpufreq itself is on the order of thousands of microseconds. The current appwidget refreshes if the screen is on, regardless of whether it's visible or not (there is currently no way to tell if it is visible). A live wallpaper would be a much better idea than a constantly updating appwidget, and I'll look into that.
Let me explain this bit better. Cpufreq will scale your CPU between the max and min values automatically. Once the CPU load hits the "up threshold," it takes your CPU frequency from the min to the max, then gradually eases it down. SetCPU lets you easily change the max and min values on the fly. If you want, it can also prevent the system from scaling the CPU up that high during times you don't want it to (with profiles, of course). It does not and cannot interfere with the actual governor.
Click to expand...
Click to collapse
I too am a fan of setcpu, and over the last week I did get curious due to this this thread. I found my battery ran down quite significantly faster without setcpu, maybe because I didn't have my sleep profile of lowest freq min/max, or my battery profile of max 756, or my low battery profiles scaling down my cpu max. Either way, stop bashing the app, it's awesome, and if you had concerns, take them to the dev rather than start a witch hunt in the forums trying to make a posse.
People that report better battery, may not have had setcpu set up correctly in the first place. A friend of mine at work installed it, ran for a day and uninstalled it, citing it didn't do anything and infact drained his battery. He had the widget running, and had upped the minimum cpu freq to 500 and something, max to the 1.13ghx. He didn't run profiles. But as such, he wasn't letting his phone scale down to the lowest freq when it wanted to, and had the widget drain. I got him to set t up as I have mine, and he was blown away with the change.
"My car wont go over 20km/h"
"Are you putting your foot on the accelerator?"
"Whats an accelerator?"
Things have to be used correctly to get the best out of them, and unless someone saying it's far worse than without actually comes in and puts up their values they have it set to, we have no idea why they are having the fault. My experience (I have worked tech call centres for years) is that 99/100 issues people experience are due to not using things as they are set out to be, or just have no idea how to do what they are trying to do. My work mates thing was that he thought all apps would go faster if he increased the minimum freq, so therefore use less battery because the processes are completed faster. In a way it's logical, but the result is that even when nothings running the cpu wont fall below that value, so the battery drained much faster than he expected.

[Q] Voltage Terms

Can someone explain what the different terms under i/o scheduler and cpu governor mean and actually do? Ive searched and all i can find are things like "cfq is first generation scheduler" is that doesnt really answer my question. T.i.a.
Sent from my Verizon Fascinate, running Cyanogenmod 7
You can think of the I/O Scheduler as the thing that decides how to allocate resources to different processes. They run with different goals in mind, but one easy way to consider them is on a gradient of how well they handle multiple tasks.
For simple phones, where few tasks will run simultaneously, a simple scheduler will work well. With more simultaneous tasks comes more complexity in management, and some more complex schedules (which are theoretically more CPU intensive) may be needed. The general gradient from basic to complex is noop, sio, deadline, cfq, bfq.
The governor can be thought of as the thing that decides at what clock speed to run your CPU. Again, they range on a gradient of complexity. Ondemand, for instance, will run at a low clock speed until needed, and will then quickly jump up to max speed as required and then slowly ramp back down if not needed. Conservative, on the other hand, will ramp up more slowly if needed, which means that it is theoretically less responsive to sudden high demand tasks but at the same time it will also theoretically save more battery. Conservative, for instance, is used in the Glitch kernel when the screen is off, and ondemand is used when the screen is on.
Performance runs at max clock all the time (which is good for seeing whether your phone can handle a particular overclock setting) and powersave will run at min clock speed all the time.
Interactive, interactivex, and smartass are related in the way they work. Interactive and interactivex basically poll a period of time to see what the demand is, and attempt to scale it from there. Smartass keeps the clock speed at low or deep sleep when the screen is off, and will poll the first 1-2 seconds of awake time. If the processor is needed at a high demand within that time, smartass will jump up as needed. Otherwise, it will poll a given amount of time (I think the default is 50 seconds) to see what the demand is in that previous chunk. I've heard that smartass is very good at managing battery life in overclocked setups.
Userspace is not recommended from my understanding.
THANK YOU!
Sent from my Verizon Fascinate, running Cyanogenmod 7

Best/Prefered overclocking practices

I was wondering what people think are the best practices for overclocking this device in terms of performance and battery life.
Currently I'm running OpenOptimus (v2.202) with the latest Franco Kernel. The settings are 122-787 MHZ with the interactiveX governor (I read that smoothass is better but none of the other ones work).
I've noticed it spends a lot of time in the 122-244 range (I use it only lightly) but when it is down there it is running at 90-100% and it periodically ramps up. It remains responsive though.
I'm looking to discuss whether that is preferable or if something more like a minimum of 420 (the default), why, and personal experiences with different settings.
This one here.
Stock frequencies work fine for a normal user (245/600 smartass feels snappy already on fkernel+cm7)
Increasing the lowest values a bit more have no significant increase in battery drain but performance increases.
Sent from my LG-P500 using XDA Premium App

[REQ] Standalone fix for high CPU freq with screen on

As I understand solution for "998 MHz with screen on" bug is found: http://forum.xda-developers.com/showthread.php?t=1225411&page=17#post16944722
We need to replace only one governor.
I don't want to play with different ROMs and kernels and I'm looking for simplest solution.
Is it possible to compile it as a module ("ondemand_mod" for ex.) and add it to stock ROM?
Or any other (simple) way?
Wrong section ...
Sent from my X10i using Tapatalk
Why wrong Section, this is Development to get the CPU Governor working correctly
Wolfbreak said:
Why wrong Section, this is Development to get the CPU Governor working correctly
Click to expand...
Click to collapse
Exactly, this is the right section for such request.
However, I can't help but wonder: is this really a "problem"?
No offence to anyone, but I find that the phone is very snappy
when on max frequency... The big problem for me, would be if it
didn't go into Deep Sleep immediately after turning the screen off
and stayed at min frequency for an extended period.
When the screen is on (aka using the phone) I'd like it to be as FAST
as possible. That's the reason I use the minmax governor.
Anyway, again, I don't mean to argue with anyone, I am just
presenting my point of view.
My_Immortal said:
However, I can't help but wonder: is this really a "problem"?
No offence to anyone, but I find that the phone is very snappy
when on max frequency... The big problem for me, would be if it
didn't go into Deep Sleep immediately after turning the screen off
and stayed at min frequency for an extended period.
When the screen is on (aka using the phone) I'd like it to be as FAST
as possible. That's the reason I use the minmax governor.
Anyway, again, I don't mean to argue with anyone, I am just
presenting my point of view.
Click to expand...
Click to collapse
Yes, it's really problem.
Higher frequency - higher power consumption. Moreover - with higher frequency CPU used with higher voltage so consumption is even more higher. So at 998 MHz CPU eats about 5 times more battery than on 246MHz.
With properly tuned governor I don't feel any real lags or slowdowns.
And, when screen is on CPU load is usually is lower than 20% at full frequency. So I don't want to waste my battery.
As I see it's possible to compile and use governor as module.
Could someone compile it? And assemble as xRecovery package?
Or point me where to read about compiling for arm, where to get tools and so on...
Karlson2k said:
Yes, it's really problem.
Higher frequency - higher power consumption. Moreover - with higher frequency CPU used with higher voltage so consumption is even more higher. So at 998 MHz CPU eats about 5 times more battery than on 246MHz.
With properly tuned governor I don't feel any real lags or slowdowns.
And, when screen is on CPU load is usually is lower than 20% at full frequency. So I don't want to waste my battery.
Click to expand...
Click to collapse
The thing is, on 245 MHz, you can't get any kind of decent performance.
Try this: set the minimum and maximum CPU frequency with SetCPU to 245 and attempt to use the phone normally.
Also, you might be right about voltage, but if the CPU is forced to work on lower freqs when it actually needs higher, there's definitely stress and increased battery consumption.
My phone lasts for more than 24 hours and it's always at max frequency when the screen is on. No lag, no freezes, no drain.
I do agree that the ondemand governor might not function as expected but I fail to experience the actual problem. That might be just me though.
Xperia X10i via Tapatalk
My_Immortal said:
The thing is, on 245 MHz with high load, you can't get any kind of decent performance.
Try this: set the minimum and maximum CPU frequency with SetCPU to 245 and attempt to use the phone normally.
Also, you might be right about voltage, but if the CPU is forced to work on lower freqs when it actually needs higher, there's definitely stress and increased battery consumption.
My phone lasts for more than 24 hours and it's always at max frequency when the screen is on. No lag, no freezes, no drain.
I do agree that the ondemand governor might not function as expected but I fail to experience the actual problem. That might be just me though.
Click to expand...
Click to collapse
There is no need to work on 245MHz as proper governor rise frequency automatically when it's necessary.
And really no stress for CPU to work an low frequency at full load. Moreover - CPU will consume more power at 500Mhz with 45% load than at 250Mhz with 95% load.
Sometime I use phone for navigation - long time with screen on and very low load. In this scenario battery drains very fast.
And last one - I like to have everything working properly. In case that I'll really need high frequency all the time I'll use other governor. I just want to have a choice.
I need a simple solotion for this too..I use z kernel and I found that Thego2s kernel fixed this problem..I was going to flash that kernel but think that has a bug and stoucks on logo ..can some one sayas a simple way?
Yes, I think a lot of people would prefer to use just small and simple fixes rather than replacing the whole kernel with a lot of nice but (personally) unnecessary features.
I am waiting for developers to release a fix for this problam

[Q] Aroma settings (MeanBean)

This is my very first time to play with Aroma in meanbean and it has some options that I know little about. I tried to search the internet using broad search terms to find out more but didn't come up with too much.
1) What frequencies have you been able to OC to and keep it stable? What voltage settings (undervolt, normal, overvolt, max) did you use?
2) Does overvolting actually use more power if you are only doing normal tasks like placing a call or sending a text?
3) What are the differences between Ondemand, Intellidemand, and Interactivex2 when it comes to CPU governors? (nothing is explained I'm just required to pick one)
4) What is the real difference between focusing on Battery vs Performance? Is it like a laptop with discreet graphics where it can run on the Intel 4000HD until you start a game then it kicks on the discreet graphics for more power?
Thanks for any explanations. I'd like to get the most from my phone and just curious what the options are all about!
ToiletDucky said:
This is my very first time to play with Aroma in meanbean and it has some options that I know little about. I tried to search the internet using broad search terms to find out more but didn't come up with too much.
1) What frequencies have you been able to OC to and keep it stable? What voltage settings (undervolt, normal, overvolt, max) did you use?
2) Does overvolting actually use more power if you are only doing normal tasks like placing a call or sending a text?
3) What are the differences between Ondemand, Intellidemand, and Interactivex2 when it comes to CPU governors? (nothing is explained I'm just required to pick one)
4) What is the real difference between focusing on Battery vs Performance? Is it like a laptop with discreet graphics where it can run on the Intel 4000HD until you start a game then it kicks on the discreet graphics for more power?
Thanks for any explanations. I'd like to get the most from my phone and just curious what the options are all about!
Click to expand...
Click to collapse
1. It is different for every phone. No chip is exactly alike. Experiment, but the 1.7 or so overclock is usually safe with most phones. If you are overclocking then you may or may not need to over volt, It depends on your phone. You will have to test what works for your phone. If you adjust the settings too high and you start experiencing reboots, lock ups, freezes, or apps acting up then your probably went too high with the overclock or didn't go high enough with the over volt. Generally, if you are overclocking say to 1.7 you should probably do over volt. If you are overclocking to 1.89 then you may need max over volt.
2. No, you will see negligible power use or battery loss.
3. Use ondemand or intellidemand governor. Either are good. Do not use the Interactivex2 governor since it seems to cause a lot of problems with this phone like reboots and lock ups.
4. Stick with performance. The battery savings are so minuscule you won't notice a difference but it may cause problems.

Categories

Resources