NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Jit Manager Utility (jitman.exe)

Jitman is a utility that allows SDK users to control various options in the NGWS runtime related primarily to JIT compilation and garbage collection. The utility presents a simple dialog-based UI that allows the user to set these options. When launched, Jitman places an icon in the tray so the utility can be easily accessed. The following picture shows the UI:

UI Options

Option Description
Use EconoJIT only If this option is checked, NGWS runtime will only use the EconoJIT when compiling code. If this option is not checked, the regular JIT compiler is used.

These two compilers offer administrators tradeoffs related to the speed at which the compiler runs, the amount of memory the compiler uses and the quality of code produced by the compiler. The characteristics of EconoJit are:

  • The compiler itself runs very fast
  • The amount of memory used by the compiler is bounded and can be controlled by the administrator.
  • The quality of the code produced by the compiler is not as high as the quality of the code produced by the regular JIT.

In contrast, the regular JIT compiler produces higher quality code, but the compiler itself doesn’t run as fast as the EconoJIT. In addition, the amount of memory used by the compiler is variable and cannot be controlled.

The default value for this setting is “off”. That is, use the regular JIT compiler.

Max Code Pitch Overhead If EconoJIT is being used, this setting controls the ratio of time spent jitting code vs. running code. If this ratio begins to exceed what is specified (i.e too much time is spent jitting), the EconoJIT expands the code cache to bring the ratio down.

The default value for this setting is 10%.

Limit Size of Code Cache When this box is checked, the “Max Code Cache” field is enabled. If this box is not checked, the maximum size of the code cache is all the memory on the machine.
Max Code Cache If EconoJIT is being used, this setting controls the maximum size of the buffer used to hold the jitted code. If the buffer overflows, code is pitched out to make room for the newly compiled code. Jit compilation will fail on any method for which the jitted code size exceeds the total size of the buffer (i.e. the MaxCodeCache should be large enough to accommodate the largest method). The buffer size is given in bytes.

The default value for this setting is “unlimited” – the code cache will use all available memory on the machine.

Optimize for Size Causes the JIT compiler to optimize for small code size rather that speed.

The default value for this setting is “off”.

Enable Concurrent GC When concurrent GC is enabled, collections happen on separate threads so the threads running user code aren’t stopped during the collection. Concurrent GC is generally slower than normal GC, but results in smaller pauses. As a result, concurrent GC is useful for apps requiring a high degree of user interaction, like client UI apps. Concurrent GC requires write-watch support from the OS. This support is currently available on Windows2000 and the upcoming refresh of Windows98. This check box is disabled if the OS doesn’t have the necessary support.

The default value for this setting is “off”.