[Nexus 6P Android Development] nathanchance:
Introduction

Alright guys, I've been taking a bit of a break from merging stuff and tweaking from a coding standpoint and more focusing on some governor settings. Ideally, I would like to set my own governor profile as default as Google's is solid but I think it can be optimized a bit. So with that, I debut Flash 1.0 (really original right?)

Download:

http://nchancellor.net/Kernels/angler/Profiles/Flash1.0

So what about it?

Let me break down the game plan of this profile as it may not be for you. Ultimately, I aim for this profile to be something like Ondemand, I want it to ramp up quickly so we get smoothness but I also want to ramp down once we have determined more power is not required (like typing or scrolling). Something kind of like Butterfly but less aggressive. This should make scrolling smooth while improving battery as well. So, what do we know?

First off, we all know that the little cluster uses less power than the big cluster; however, I just recently learned that the little cluster's maximum frequency (1555MHz) uses less power than the big cluster's minimum frequency (633MHz). That means we really don't want to use the big cluster unless really necessary (duh).

Next, we have to look at what the interactive governor actually aims to do. This was probably where I had to spend the most time understanding as there are quite a few tunables that matter in this process. I consulted this documentation provided by the kernel as well as soniCron's thread where he goes over the idea of loads. In order to have the governor do what we want, we need to specify what the governor needs to do at each frequency and how it needs to react when there are tasks (or loads) placed on it. Here's what I landed on:

Little cluster: let the governor scale really easy between 384MHz to 960MHz, have a fairly hard gap to cross at 1248MHz, then continue to scale with a little more difficulty between 1344MHz and 1555MHz

Big cluster: keep the frequency pegged at the minimum of 633MHz unless the load is over 99%, at which it can scale up with relative ease all the way up to max if necessary, then back to min.

What this will ultimately result in is a fairly even distribution on the lower cluster (with emphasis at 384MHz, 960MHz, and 1248MHz due to loads and input boost). I have made the kernel boost the little cores to 1248MHz for 50ms, which will make scrolling feel smooth, and due to the loads, it should scale down and hover around 768MHz during scrolling and other graphically intense tasks. Because the little cluster uses so little energy, we aim to allow it to scale up fairly easily between the frequencies, which restricting the big cluster unless it is really necessary.

Feedback

I am absolutely open to feedback on this, feel free to let me know what is working well and what is going wrong. While giving feedback, please give somewhat specific examples of things that were problematic and under what use cases it happens. If I can't reproduce, I can't fix the profile. This should improve battery life compared to the stock profile but my goal is performance with this as well. I want this to keep everything bursty. I did this profile mostly by reading the documentation so hopefully I did it right :silly:

Application

This profile is geared for EX Kernel Manager as it has this functionality built in (@flar2 really is awesome, isn't he?). I also recommend it for its battery monitor feature (how I tracked this profile's statistics), which got even better in the latest update due to a persistent notification that looks pretty neat.

If you have never applied a profile before:

Download EX Kernel Manager

Open the CPU section then Governor options and grant it storage permissions

Download my profile and move it to /sdcard/ElementalX/gov_profiles

Go back into EXKM > CPU > Governor options and choose the Load option

Select my profile and toggle the apply on boot on

Go into CPU > CPU Boost options and apply the "Input boost frequency" and "Input boost milliseconds" options for apply on boot (the power button to the right should be blue)

For Kernel Adiutor users:

Here are the values to add manually if you don't want to pay for EX Kernel Manager. I cannot help you with the process as I don't use Kernel Adiutor nor do I support it.

Governors should be interactive on both clusters

Min max for little cluster should be 384MHz and 1555MHz

Min max for big cluster should be 633MHz and 1958MHz

Governor settings for the little cluster:

go_hispeed_load 99

above_hispeed_delay 20000 1344000:40000

timer_rate 30000

hispeed_freq 768000

timer_slack -1

target_loads 60 384000:50 460800:50 600000:55 672000:60 768000:60 864000:55 960000:90 1248000:90 1344000:80 1478000:90 15552000:99

min_sample_time 60000

ignore_hispeed_on_notif 0

boost 0

fast_ramp_down 0

align_windows 0

use_migration_notif 0

use_sched_load 0

max_freq_hysteresis 80000

boostpulse_duration 0

Governor settings for the big cluster:

go_hispeed_load 99

above_hispeed_delay 40000 960000:60000 1728000:20000

timer_rate 30000

hispeed_freq 633600

timer_slack -1

target_loads 99 633600:80 768000:85 864000:90 960000:90 1248000:95 1344000:95 1444000:95 1536000:95 1632000:95 1728000:98 1824000:99 1958000:100

min_sample_time 30000

ignore_hispeed_on_notif 0

boost 0

fast_ramp_down 0

align_windows 0

use_migration_notif 0

use_sched_load 0

max_freq_hysteresis 80

000

boostpulse_duration 0

Input boost should be 1248MHz on little for 50ms

About my usage

I would not really call myself a heavy user by the traditional definition but I do watch a lot of YouTube on my phone, I am chatting in Telegram and Hangouts, I am browsing XDA, Google+, Twitter (with Fenix), Instagram, and Reddit (using Relay Pro), and I listen to music with both Bluetooth and wired headsets. I don't do much gaming so this profile is untested in that region (but it should do well). This is a full afternoon/evening's worth of that usage. The idle drain was high in this screenshot because Google Play Services has been wakelocking me a lot but I got 0.2% drain last night.

And with that, have at it!