The SystemDictionary class has about 60 C static variables which hold well-known classes. They should be consolidated into a single static block of C array-type, indexed by an enum, as in vmSymbols. This will simplify maintenance and scaling and allow certain optimizations.
At JVM bootstrap, approximately 25% of all symbol lookups resolve to these symbols. It is probably worthwhile making a fast path for these (using vmSymbols::find_sid).
The object code which operates on these classes as a group (for GC and initialization) will be much more compact if they are made into an array indexed by an enum. Several object files are smaller by 1-10Kb, including systemDictionary.o, vmStructs.o, javaClasses.o, and jvm.o, and the DLL is about 40Kb smaller.
The number of well-known classes will increase as new low-level features are added to support other languages. Adding them should be as simple as adding new vmSymbols.
Benefits:
- fewer symbols in the binary
- code simplification
- a fast path through the class lookup routine
- easier expansion in the future