summaryrefslogtreecommitdiff
path: root/opengl/tests/gl_basic/gl_basic.cpp
diff options
context:
space:
mode:
authorTorne (Richard Coles) <torne@google.com>2017-05-31 14:09:14 -0400
committerTorne (Richard Coles) <torne@google.com>2017-07-24 14:29:50 -0400
commit466cbe4bc1d9ee0d51d09602df10b52617d3bd31 (patch)
treecf709043ab8e59cac9665c9118c58a34103d0309 /opengl/tests/gl_basic/gl_basic.cpp
parenta404b8ad842ccb0bed26c8e284da237ce12d74de (diff)
Improve ActivityManagerInternal.startIsolatedProcess.
The processes created by ActivityManagerInternal.startIsolatedProcess were not being tracked by ActivityManager after creation (other than to handle crashes), but they still had ProcessRecords created for them. This meant that if a second process was started with the same name, a WTF would be triggered due to the old ProcessRecord still existing. To resolve this, we change the way that these special isolated processes start up: instead of directly executing the main() of the requested class after forking, the process first runs ActivityThread as with ordinary processes. When the process attaches to ActivityManagerService, it is given the name and parameters of the entry point class to execute instead of being given an ApplicationInfo to bind. We also reinstate the previously-disabled process start timeout, since the process is now expected to attach as normal. This means that ActivityManagerService can observe the process's death via Binder as usual and clean up the ProcessRecord, as well as making this process less of a special case. To ensure the process is still treated as important, we set a minimum OOM adjustment of PERSISTENT_SERVICE_ADJ (which is accurate as the system server is depending on the process even though it does not directly bind to it as a service), and exclude processes of this type from being killed due to being empty isolated processes. The process will exit voluntarily after the entry point function returns instead. Bug: 19061358 Test: Upgrade the current WebView implementation APK and check for WTFs Change-Id: Ide4f89d308851bb591194a8d59e6d581e9d59b50
Diffstat (limited to 'opengl/tests/gl_basic/gl_basic.cpp')
0 files changed, 0 insertions, 0 deletions