JakeRoggenbuck / auto-clock-speed

A utility to check stats about your CPU, and auto regulate clock speeds to help with either performance or battery life.
https://autoclockspeed.org
MIT License
37 stars 9 forks source link

Add all changed for csv enabled #472

Closed JakeRoggenbuck closed 1 year ago

JakeRoggenbuck commented 1 year ago

fixes #469

JakeRoggenbuck commented 1 year ago

This is a huge speed up if csv is not enabled. This entire green block doesn't get called. image

Better version of #467

Camerooooon commented 1 year ago

I have this fixed in https://github.com/JakeRoggenbuck/auto-clock-speed/pull/461. If we merge now it will cause conflicts. Sorry, I didn't realize yesterday.

JakeRoggenbuck commented 1 year ago

I have this fixed in #461. If we merge now it will cause conflicts. Sorry, I didn't realize yesterday.

That's alright, I don't think it will cause because the area where we implement it only overlaps by a line but if you want to have the flag checked like this in your PR, that's alright by me.

We need to make sure that the flag gets checked before the function gets called.

if do_thing {
  thing();
}

and not something like this.

fn thing() {
  if !do_thing { return; }
}

thing();

The implementations are kinda different.

JakeRoggenbuck commented 1 year ago

Fixed in #461