Tune the executable module cache
APPX can keep a compiled process in memory for later calls. Two user settings govern the cache: how many modules it may retain and the lowest priority worth retaining.
Choose which modules to retain
- Check whether the process runs often enough to benefit from caching. Compare its process cache priority with the user's minimum priority.
- If frequently used modules compete for space, review the user's cache quota. When APPX trims the cache, it considers inactive modules in priority order.
- An active module stays in memory even when the quota is exceeded. End a test session and start a new one when comparing different user settings.
-
Processes are only removed from the cache when a new process needs to enter the cache (i.e. we never trim the cache when you end a process, only when you start a process).
-
Every process is placed in the cache when it is loaded - if the cache is full, some processes may be removed.
-
The cache is considered to be full if the number of processes in the cache exceeds the user's cache quota (defaults to 15).
-
Active processes are never removed from the cache.
-
A subprocess is active as long as it's family is active.
-
When trimming the cache, we remove as many low-priority, inactive processes as need to bring the cache back to the desired size (as determined by the user's cache quota).
-
While trimming the cache, we will remove all inactive processes that have a priority lower than the user's cache priority, even if the cache is not full.
-
A user's cache priority defaults to 15.
-
Since the default priority assigned to each process is 50, all processes are considered equal when we start trimming the cache.
-
If you have a low priority process, it will be trimmed before higher priority processes.
-
If you have a high priority process, it will tend to stay in the cache longer than low priority processes.
-
Since the default cache level for a user is 15, processes with a priority lower than 15 will not stay in the cache.
-
The cache can hold more processes than the user is allowed - this happens when the user has more active processes.
-
The documentation is wrong when it states that related and detached processes are not cached.