[VOTE] Best Hotplug for MOTO E. - Moto E General

I open this topic for a discussion of the performance and acceptance, famous hotplug ...
What is CPU Hot-plug?
Hot-plug by definition is adding or removing things without switching off the system. Say Add a hard disk to the system and increase it's storage capacity without switching off the system. CPU hot-plug means adding or removing CPU's from the system without switching off the system.
Why CPU Hot-plug?
This feature came in for servers which have so many CPU's and one or more CPU's may become faulty. And switching off the server and physically removing it may be costly for any business. CPU hot-plug helps here by hot-plugging out the CPU from the software so that nothing gets scheduled on the CPU once that is done the power rails of the CPU can be turned off from the software and later if need be, the CPU can be safely removed from the system.
Similarly, Adding CPUs.
Hot-plugging for Saving Power.
But, this feature is increasingly being used for saving power. We have so many mobile phone or tablets with 4-Core, 8-Core CPU's etc... But when the mobile is just idling in your pocket waiting for any call or when the tablet is in standby or playing a song, one really does not need the power of so many cores. So, Mobile/Processor makers nicely use the hot-plug mechanisms to turn off the CPU. When very lightly loaded or in standby the not-need cores are hot-plugged off. And added whenever needed. This way there is a lot of power saving achieved.
A bit of Internals.
Once it is decided that a CPU is going to be hot-plugged basic thing needs to be done. In a multi-processor system there are several processes running, or sleeping in every CPU. Which essentially means there could/will be some processes that are running or sleeping in the CPU that we would like to hot-plug. So, first thing to be done is to "migrate". The migration scheduler thread has to run and transfer all the running or sleeping processes into the other available cores. The isr's. We need to mention the interrupt controller that this core is no longer available for servicing interrupts if the core is capable of handling interrupts. This step is very architecture specific.
After this is done the architecture specific hot-plug code is invoked in arch/xxx/mach-xxx/cpuxxx.c. This will do what is needed in the specific chip to switch off the cpu rails and turn off or reduce to voltages according to the need.
When adding the core the same step is reversed. Once the hardware specific things are done the new CPU is added to schedulers domain and scheduler starts freely migrating threads into the new cpu.
Pitfalls of CPU Hot-plug:
When CPU Hot-plug is used for power saving, the major pitfall is the cpu not being available on time during sudden load conditions. It always take a while to predict the load, and latency in brining a CPU online and latency in moving a process to a new CPU. So, there can be instances in which we have a load and the CPU's are not yet added to the system to digest it. This might lead to some uneasy user experience. Even after paying money for a 4/8 CPU product the user may not have them when needed. But, this is not as bad as I have worded it. It is just a balance.
If there is a running task on a CPU which is going to be hot-plugged it has to be moved to another CPU. There is always a cache penalty associate with every migration as there will be no cache for this process in the per-cpu cache of the new processor where it has moved. Cache penalty is separate subject and it is very very architecture specific.
How and when to Hot-plug?
There is no simple answer or this. It is purely dependent on the SoC. Every SoC vendor have their own implementation of the logic. There are some open source implementations also available. Also, there are some multi-core SoC's which don't use CPU hot-plug for power savings.
I modify my kernel, each with a different version of hotplug, each will have to try it, and based on the experience rate, the hotplug with the most votes, will be the default hotplug my kernel.
FIRST VERSION
FenomenalMOD with MSM_ZEN DECISION
msm: add msm_zen_decision
This adds a simple driver intended to allow the MPDecision service to be disabled.
The driver is easily extendable, but currently it:
- Can be enabled/disabled in /sys/kernel/zen_decision/enabled
- On screen power OFF it removes all cpu cores after suspend_wait_time
- On screen power ON it enables all cpu cores.
- /sys/kernel/zen_decision/suspend_wait_time (ms) refers to how long we wait after screen is off to remove the cores (default 5s). This just to avoid removing cores in excess.
DOWNLOAD: ZEN-Hotplug
SECOND VERSION
FenokenalMOD with msm_hotplug
It will switch on more cores very quickly. In Dorimanx kernel, this hotplug can be heavily tweaked to be battery friendly to pure performance. With the right tweaks it is a very good choice for balanced performance.
DOWNLOAD: MSM Hotplug
THIRD VERSION
FenomenalMOD with Mako Hotplug
Basic Hotplug by francisco franco
DOWNLOAD: Mako Hotplug
FIVE VERSION
FenomenalMOD with AUTOSMP Hotplug (very good!!)
AutoSMP is a simple but effective hot plug governor by mrg666
You can modify this in sys/kernel/autosmp/conf
DOWNLOAD: AUTOSMP
SIX VERSION
FenomenalMOD with Bricked Hotplug(very good!!!)
Conservative hotplug driver by @showp1984
DOWNLOAD: BRICKED HOTPLUG
Please, try each before voting, Czech performance, battery, etc .... ALL DOWNLOAD IS FOR AOSP ROMS (CM, AOSP, PARANOIS, ETC=

Tested bricked Hotplug bestBatery backup with best performance, i accidentally voted mako

not working for stock?

DAVI FELICIANO said:
not working for stock?
Click to expand...
Click to collapse
No, its only for test

Msm & Mako!

Here's a tie, I'll add the 3 most voted hotplugs ...

DELETED

Related

[Q] [CPU/GPU Governor] Best fitting for my needs? well described

Hello
I am on a quest to find the best governor or kernel for me.
Firstly heres my ''specs'':
I am using I9505, on GE JFLTE-GPE 5.0.1 rom. Right now i have Hulk Kernel, but i have also tried Alucard/Goggy_Max.
I do not care if i have to flash kernels, etc. but i do not wish to change rom
I use my phone for Facebook, Snapchat, Messenger, Chrome, Gmail and loads of music. My music is on my MicroSD (64GB 95MB/s reads). i do NOT game on my phone.
My wish is for the most smooth performance of the above-mentioned, but it is also VERY important for me to have good battery life. Therefore i use Greenify and Amplify. I have limited many alarms/wakelocks, and greenified alot (not Messenger/Snapchat, because it stops notifications)
I do NOT own SetCPU, but i am using STweaks on Hulk Kernel right now.
I have usually used Ondemand governor, but found out yesterday that governors can do alot of difference, so i have shortly tried Badass, and trying SmartassH3 right now. I have been very satisfied with Ondemand governor, but i would be happy if i could get better battery life, with the same performance. For my GPU im trying 'Simple'' governor.
Furthermore ive considered the following governors; DanceDance, Badass, Ondemand, Yankactive, Smartmax, Impulse, SmartassH3 but i am not limiting myself to these, if you have other suggestions.
Thanks in advance
Links to my used Rom/Kernels
Goggy_max : http://forum.xda-developers.com/showthread.php?t=2741181
Hulk_Kernel : http://forum.xda-developers.com/galaxy-s4/i9505-develop/kernel-hulk-kernel-v1-stweaks-based-t3050469
GE Rom : http://forum.xda-developers.com/showthread.php?t=2557353
Alucard Kernel : Included as default in rom.
Here's a thread with explanation on pretty much all CPU governors and I/O schedulers.
Based on what you're saying, Intellidemand should be ok for you. It scales CPU based on the GPU load. So that means if your GPU is not working hard (gaming) your CPU should sit in lower frequencies.
SmartassH3 is more of a conservative governor.
You can even try the conservative governor. It was designed with battery in mind. Meaning that this governor prefers the lower CPU frequency. This also means less smoothness.
Another option is to activate one of the Intelli-Plug profiles from Hulk.
Eco performance is what I would suggest. It will turn your phone into a dual core phone but with some performance tweaks.
You could also try the other profiles and see what works best. But you get more battery savings by turning cores off or disabling them.
GDReaper said:
Here's a thread with explanation on pretty much all CPU governors and I/O schedulers.
Based on what you're saying, Intellidemand should be ok for you. It scales CPU based on the GPU load. So that means if your GPU is not working hard (gaming) your CPU should sit in lower frequencies.
SmartassH3 is more of a conservative governor.
You can even try the conservative governor. It was designed with battery in mind. Meaning that this governor prefers the lower CPU frequency. This also means less smoothness.
Another option is to activate one of the Intelli-Plug profiles from Hulk.
Eco performance is what I would suggest. It will turn your phone into a dual core phone but with some performance tweaks.
You could also try the other profiles and see what works best. But you get more battery savings by turning cores off or disabling them.
Click to expand...
Click to collapse
Hi
I tried the SmartassH3, but it seems it keeps rather high freqs? atleast it made my phone warmer than usual, so i am back to Ondemand until further. I activated the intelliplug and limited the cores to 2, and ive felt no performance loss yet. Which is great, so thanks for that tip
BTW, after ive begun with the governor tweaks, ive noticed my Poweramp decides to turn off when my screen is off? :/ It is not hibernated by Greenify, and Amplify has not limited either, so i do not understand why it stops. If i choose ''use wakelocks'' in Poweramp, it stays active. But this ofc. drains battery very quickly . Do you have any idea, what could be the problem here?
Check with an app to see how many cores you have active. Some said those settings don't work. For me they seem to work. But just to make sure.
When using poweramp the device will be awake anyway.
Governors should not have any effect on apps and how they run, except performance-wise. Governors can't put apps to sleep.
Poweramp requires the media service to run. Make sure you did not block that.
GDReaper said:
Check with an app to see how many cores you have active. Some said those settings don't work. For me they seem to work. But just to make sure
When using poweramp the device will be awake anyway.
Governors should not have any effect on apps and how they run, except performance-wise. Governors can't put apps to sleep.
Poweramp requires the media service to run. Make sure you did not block that.
Click to expand...
Click to collapse
I've already checked with Trickster MOD kernel settings, and verified it works
Ill check up on the media service. Do you know its exact name in Amplify?
amd62 said:
I've already checked with Trickster MOD kernel settings, and verified it works
Ill check up on the media service. Do you know its exact name in Amplify?
Click to expand...
Click to collapse
No, as I don't use Amplify.
after ALOT of tests, i think ive found out what happend. I limited the screen off max freq to 384MHz, and i think this was the problem. I will report back if it is NOT the problem. Else consider it solved
EDIT: Seems it was not. The search continues :I

Overheating problem on Stock ROM

Hi guys!!
I am running Stock ROM on my GT-I9301, with @sev3n1985 kernel. I have overheating problems! Sometimes it's very hard to hold my phone. How can I solve it? Btw, I'll leave my Kernel Settings down bellow
Regards :*
Settings (I use Kernel Adiutor):
- CPU Max Freq: 1401Mhz
- CPU Min Freq: 300Mhz
- CPU Governor: smartmax
- Multicore Power Saving: Disabled
- CPU Hotplug: MSM Hotplug (MPDecision desactivates)
- CPU Boosted: 1
- Max Cores Screen Off: 1
- Thermal: Temperature Throttle
Sent from my S3 Neo+ (GT-I9301I) running Custom Made StockROM with @sev3n1985 kernel
Have you already done a factory reset?
Perhaps it's just a bad app.
Jhnsn said:
Have you already done a factory reset?
Perhaps it's just a bad app.
Click to expand...
Click to collapse
I use Greenify even on some system apps, so no background apps. And my ROM is deodexed. So I think that's not the problem. But thank you
Sent from my S3 Neo+ (GT-I9301I) running Custom Made StockROM with @sev3n1985 kernel
S3 Neo is familiar with overheating problems even on stock, but I'm trying to understand, do you have that problem even if you are not using your phone that much?
Sometimes hot plug & governors (more tied to the interactive than ondemand) logic simply bricks hot plug & then you have all cores running all the time. Their is also a conflict tied to additional bust frequency logic. All this is actually cased by Samsung & it's never been corrected in this kernel (it is corrected only in official CM12.1 repo). Simple reset resolve this until it happens again.
Regarding Smart max try like this:
Also go with mpdecision hot plug & use simple on demand GPU governor.
It should save some juice keep consumption under control & device cooler.
Zola III said:
Sometimes hot plug & governors (more tied to the interactive than ondemand) logic simply bricks hot plug & then you have all cores running all the time. Their is also a conflict tied to additional bust frequency logic. All this is actually cased by Samsung & it's never been corrected in this kernel (it is corrected only in official CM12.1 repo). Simple reset resolve this until it happens again.
Regarding Smart max try like this:
Also go with mpdecision hot plug & use simple on demand GPU governor.
It should save some juice keep consumption under control & device cooler.
Click to expand...
Click to collapse
Thanks for your time, dude
You can also try like this to keep it more in green line frequency range even more during the light tasks, performance for the light tasks is not stellar but it's more than good enough this way.
Note: Ideal awake frequency (targeted one) for this SoC should actually be 600MHz considering power voltage and DRAM frequency dependencies but on Samsung firmware this is not fast enough so it actually produces contra effects; jumps to higher frequencies more often along with waking up additional cores so 787 is advised minimum. On the other hand peple who love & use Smart max on other light wait roms such as CM's (without of heap load Samsung bull****s) can actually try with 600MHz. Still interactive governor is possible to be tuned better.
Best regards.

Setting Up Custom Kernels for testing..etc. (Osprey)

Setting up Custom Kernels​
*this information is helpful for anyone, everything written here, I have thoroughly tested, this guide is not laid out beautifully,I will rewrite it on my desktop pc soon.
There seems to be allot of confusion about how to set up
"Custom" Kernels for the Moto G 2015 (Osprey) for testing
This is mostly due to the following reasons :
Guides/info are Outdated
info usually Vague/Confusing for Novice
Guides are often for different hardware/software
Information is wrong or unfounded or based on speculation/theory
tunables for "performance" often do the opposite
But the biggest issue that Novices have seems to be
A lack of understanding that almost every tunable has
An equal opposite reaction (side effects)
Therefore balancing each tunable with each other is essential*
Getting Ready to bench
1 ) My First step is, head over to the Android Modders Guide (look in KA to see which Gov's & Scheduler's) and get familiar with the Govs & Sched's featured in the kernel your using
2 ) now that you're familiar with that open up KA and go to
To the hotplugging section, disable any hotplugging
For the reason that you want to be able to accurately test the performance/characteristics of The CPU and Governor in use (in order to properly tune the system.)
(If you want, turn it back on when your *COMPLETELY DONE TUNING*)
3 ) make sure that while testing your phone CPU freq and Gov
That you're IO ReadAhead cache is set to 128, that way it doesn't interfere or confuse you while trying to set the CPU.
4 ) Go to the misc tab, do you see "Dynamic Fsync" ?
If so turn that off, This will switch it back to Standard Fsync
So in the rare case of a system crash your less likely to damage your data.
5 )*(optional) in the IO tab, Disable add random, and then go to entropy tab and set to 64-192 or 128-256 depending on preference.
Now onto the benching itself
1 ) alright, open the CPU tab and check the Max CPU Frequency, if there is OC available make sure you Never Start your testing/tuning using the Highest OC Frequency
(We don't have a baseline yet and most chips will not be able to perform properly or stable at these higher OC freq's eg. Above 1.593 GHz) start testing with your Max CPU set to
1.363 GHz and work your way up testing each one for performance and stability(Geekbench 3 is a good start).
2 ) Do the same thing for Selecting a Governor for benching . (Your phone might get warm while benchmarking, if you feel Like your phone is getting too hot, this could effect performance turn the phone off for a while until it cools down. Also make sure you restart occasionally in between tests to refresh everything.)
3) in GPU Tab, this is going to be just like setting up the CPU with one exception, you'll want to stick with one of
these two GPU govs (simple_ondemand) & (Msm-adreno)
the other ones are experimental.
and another thing, if your overclocking gpu to max550-650
i recommend setting the min freq to 200 for 550 and 310 for 650mhz, to avoid heat due to ramping up and down.
4 ) alright now into the IO tab, this is where you pick the scheduler that you're going to test with, I suggest fiops or tripndroid. *.
5 ) start benchmarking, I suggest you do multiple tests of whatever your using to benchmark.
6 ) Have fun!
*understand that benching will eat battery, therefore make sure when you get settings you like, you do separate battery test on a full charge.
*once you get the tunables that you're comfortable with.
You can enable hotplugging if you want.
I will post my recommended tunables for the 1GB Osprey
Below...
__________________________________________________________
*if you're going to be doing GPU heavy tasks i recommend
disabling Adreno idler.
recommended tunable for Adreno Idler
(battery savings and cool GPU)
24
17
6

Lag in games?

Hi everybody, I'm using an XT1642 with RR 7.1.1 but had the same problem with stock nougat too (I thought RR would help but it didn't): Serious lagging in Angry Birds Pop. GameBench shows fps usually around 20, while on my old Xperia Z1 Compact it's almost always 60...
Does anybody have an idea what might be the problem?
It's possibly an issue with the kernel not online-ing cores. Even so, it shouldn't lag that far behind the Z1 (even though the Z1 does have a faster CPU).
I recommend installing an app called "Kernel Adiutor", and manually change the minimum/maximum cores of the "big" cluster of the CPU, or even offline the big cluster and see if Angry Birds scales better on 4 cores.
Thank you! Setting "minimum cpus big" to 3 did solve the problem. I assume that shouldn't be kept this way because of the battery. Is there a way to have the setting changed to 3 when I open the app and back to 2 when I'm not playing? Like in getools?
berliner77 said:
Thank you! Setting "minimum cpus big" to 3 did solve the problem. I assume that shouldn't be kept this way because of the battery. Is there a way to have the setting changed to 3 when I open the app and back to 2 when I'm not playing? Like in getools?
Click to expand...
Click to collapse
There are a couple routes to this. There should be 2 variables within the Kernel Adiutor (I use EX kernel manager which is definitely worth a buy, the dev also develops the ElementalX kernels) that are called "Up Threshold" and "Down Threshold" for the big cluster. Essentially, "Up threshold" marks the CPU load at which the CPU begins to online the big cluster cores, while "Down Threshold" is the CPU load at which the CPU begins to offline big cluster cores.
I set the minimum to 0, and my up/down load levels are 60 and 45, respectively (I'm a super light user, just some reddit and clash royale), and my maximum is 4. However, lowering up and down load levels may help as the load at which the CPU onlines is much lower.
However, this may not work regardless. Some apps scale weird on octa-core CPUs; I know that Chrome was very, very janky on early big.LITTLE designs.
With EX Kernel manager flar built in a "performance" and "battery saving mode" which can be toggled via a desktop widget. I find it super useful if I'm using my G4 for VR. Essentially, you can set the max frequency and CPU governor per each mode. It is a paid app however, but the dev is great (he has a kernel out for the G4 as well) and well worth the price.
Thanks again, I will loot into it!

Is this Frequency Table behavior normal?

Hey all. I'm trying to understand our phone more to see where performance improvements can be made(if any). I'm currently using Kernel Adiutor as my default choice for kernel management on a Stock ROM to see what the trends are.
What I'm noticing so far is that on-boot, the frequency tables populate normally as usage rolls around; big cores and LITTLE cores activate as I ramp up complex tasks (web browsing on non-mobile friendly sites, synthetic tests). However upon the first screen-off event, over time Kernel Adiutor reports little/no activity from big cores and the LITTLE cores activities are doing most of the lifting with little control over the min/max frequencies. Right now, I'm working with default CPU Tunables as one of my control variables, but the Frequency Table's report on the lack of max ramp is confusing me and I can't figure out why. On top of that, my tables show that utilizing Input Boost Frequency Core function on the Stock ROM does absolutely nothing.
I'm wondering whether my readings are right and there's a way to manually control big/LITTLE core behavior beyond the initial boot up. I'm working with a Google Pixel and see that the upward trend between EAS and our HMP kernels is just the ramp up speed between the Energy Model and our usual timers therefore achieving performance lies in tuning those timers, yet I can't even get to that step yet. Which is why I'm sharing what I know now.

Categories

Resources