Patent ID: 7200842

Claim:
A computer-implemented method for converting and transforming an application software program to generate an object-oriented, verifiable, type-safe and pointer-safe sequence of instructions, said instructions comprising operation codes and operands, said sequence of instructions operable to be loaded to and executed by a resource-constrained device, said sequence of instructions converted from at least one class file, the method comprising: (A) analyzing instructions from said at least one class file and any associated references to a constant pool and arithmetic operations having 32-bit operands; and (B) removing said references to the constant pool and transforming said 32-bit operands based upon said analyzing by: (i) transforming at least one reference, of at least one of said instructions, to information in a constant pool by inlining directly at least one additional operand to said at least one instruction, wherein said at least one additional operand specifies a data type; (ii) replacing an operation code of another of said instructions, which accesses an entry in said constant pool to obtain a data type that was any one of a plurality of data types, with another operation code selected from a family of operation codes, wherein (a) each said another operation code in said family is for a different one of said plurality of data types so that the data type is explicit for said each said another operation code in said family; and (b) said another operation code represents said family for said entry in said constant pool; and (iii) transforming 32-bit operands for arithmetic operations such that arithmetic instructions are explicitly defined as using 16-bit operands wherein upon execution of said arithmetic instructions by a virtual machine on the resource-constrained device, only 16-bit operands are loaded onto a stack; and wherein the instructions formed by replacement and transformation according to (i), (ii), (iii) are directly executable by the virtual machine on said resource-constrained device without any other intermediate stage of reconversion or referencing.