On iOS we are trying to log energy use by our network extension to help us isolate troubled areas. task_info with TASK_POWER_INFO_V2 does return task_energy value and it's growing over time, but it's not clear what exactly it means and how it supposed to correlate to battery usage screen from iOS settings. Does anybody know anything about this?
task_info and TASK_POWER_INFO_V2
it's not clear what exactly it means
Indeed.
how it supposed to correlate to battery usage screen from iOS settings
It’s not.
In the absence of detailed documentation, I think the only thing you can safely do is compare values between runs on the same hardware.
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
how it supposed to correlate to battery usage screen from iOS settings
I agree with Quinn here and was actually surprised to hear that this worked on iOS. I would recommend trying to capture traces with Instruments to profile CPU, Battery usage, etc... before I spend time on trying to decipher the task APIs.