Patent ID: 7506310

Claim:
In a computing device, a method for reducing the memory needed to efficiently execute managed code by handling differently various sections of a managed code program with respect to caching, the method comprising: separating a managed code program into various sections wherein the separation is based on various attributes of the sections, the sections comprising a header, a resources section, a metadata section, and a method implementations section, wherein the metadata section comprises names of the methods of the managed code program, and the resources section comprises strings and images of the managed code program; loading from a storage the metadata section and a subset of the resources section into memory without loading the method implementations section or the resources not included in the subset, wherein a resource is included in the subset based on factors including one or more of the size, the type, or the frequency of use of the resource; maintaining the metadata section and the subset of the resources section in the memory such that the metadata section and the subset of the resources section are not removed in ordinary operation while running the managed code program; and loading at least a portion of the method implementations section and the resources not included in the subset into memory on demand.