SoundTriggerHelper: Remove unused models onLoad
If some process tries to start a recognition, the STH will now check to see if there are any other models that have been loaded and either: - Have a callback that's died (determined by pinging the binder) - Don't have a callback at all (meaning they didn't clean up after the last detection and didn't start it again). If it finds such a model, it will be stopped and unloaded, freeing up resources in the HAL. Test: Manually load model/kill the process and make sure that it is unloaded the next time some other model is loaded. Also made sure running models aren't evicted. Change-Id: Ia1139b47afe5f88102a3773d90f4f056ea3cdc92
Loading
Please register or sign in to comment