Closed eth-p closed 1 year ago
Thanks for the hard work on this! Unfortunately this isn't power-related so I don't think PowerTools is the best fit for THP.
SystemToolbox has support for this, in case you're looking for a plugin that can do this.
Happy Holidays!
This commit adds the ability for PowerTools to change the kernel transparent hugepages setting.
I gave the backend the ability to change between
never
,madvise
, andalways
, but only gave the frontend the option to toggle betweenalways
andmadvise
. While this might seem like an odd choice, the kernel docs mention thatnever
is "mostly used for debugging purposes". Withmadvise
as the "off" option, it requires processes to explicitly opt in to THP support via syscalls. Presumably these processes would know how to use it properly, and would be negatively affected by turning THP off entirely.Known Issues:
Depending on how the game launches and the timing of PowerTool's persistence setting, any changes to the THP setting may not take affect in time.
Future Considerations: