Converting program-specific virtual machine instructions...

Electrical computers and digital processing systems: processing – Instruction decoding – Decoding instruction to accommodate plural instruction...

Reexamination Certificate

Rate now

  [ 0.00 ] – not rated yet Voters 0   Comments 0

Details

C712S227000, C709S241000, C709S241000, C717S152000

Reexamination Certificate

active

06292883

ABSTRACT:

BACKGROUND OF THE INVENTION
The invention relates to a method for executing a source program on a processing unit comprising a predetermined microcontroller core for executing native instructions from a predetermined set of micro-controller specific instructions; the method comprising:
a pre-processing step of expressing program statements of the source program in a sequence of instructions comprising virtual machine instructions; and storing the sequence of instructions in an instruction memory; and
an execution step of fetching instructions from the instruction memory; using conversion means of the processing unit to convert virtual instructions fetched from the instruction memory into native instructions; and feeding the native instructions to the microcontroller core for execution.
The invention further relates to a processing unit for executing instructions of a virtual machine, the instructions being referred to as virtual machine instructions; the processing unit comprising:
a predetermined microcontroller core for executing native instructions from a predetermined set of micro-controller specific instructions; the native instructions being different from the virtual machine instructions;
an instruction memory for storing instructions including at least one of the virtual machine instructions;
a converter comprising conversion means for converting a virtual machine instruction fetched from the instruction memory into at least one native instruction for execution by the microcontroller core.
Increasingly, source programs are expressed in (compiled to) instructions of a virtual machine instead of native instructions of a microcontroller core on which the program is to be executed. A main reason for using a virtual machine is portability of programs between different machines (platforms). A program expressed in the virtual machine instructions of the virtual machine can be executed relatively easily on several concrete machines, using suitable interpreters operating on those machines. At this moment a driving force for using portable programs is Java, where Java programs are exchanged via Internet and can be executed on different native machines using processors with different instruction sets. Using a compiler, Java programs are expressed in Java byte codes (JBCs), which form the instructions of the Java Virtual Machine. The resulting code is usually referred to as a Java applet.
Conventionally, programs expressed in virtual machine instructions are executed by means of software interpretation. The processor (CPU) executes a special interpreter program, where in a loop the processor fetches a virtual machine instruction, decodes it into a sequence of native instructions of the microcontroller core of the processor and executes each native instruction. This technique is slow and requires an additional interpreter program, which can be relatively large. To improve the execution speed, the so-called Just-In-Time (JIT) compilation technique is used. Just before starting execution of software module expressed in virtual machine instructions, the module is compiled to native code (i.e., expressed in native machine instructions). In this way, the module needs to be stored twice in addition to the code for the compiler. The additional storage requirements of software interpretation are not desired for embedded systems. To avoid performance and storage overhead, it is preferred to use a hardware interpreter. In itself a hardware interpreter is known in the form of a Prolog pre-processor for Warren's abstract instruction set. In the paper “A Prolog pre-processor for Warren's abstract instruction set” by B. Knödler and W. Rosenstiel, Microprocessing and Microprogramming 18 (1986) pages 71-81, a pre-processor is described for interpreting programs written in the Prolog programming language on a Motorola 68000 processor (MC68000). A compiler is used to translate the Prolog source program into instructions, which have been defined by Mr. Warren and which are generally used for executing Prolog programs. The set of Warren instructions forms a virtual machine designed for executing Prolog programs. The sequence of Warren instructions resulting from the compilation are loaded into RAM and executed by the MC68000 with the aid of the pre-processor. After power-on, the MC68000 first performs a booting procedure by executing native MC68000 instructions. At the end of the booting procedure, the MC68000 is ready to initiate the execution of a Prolog program. This is started by jumping to a predetermined address range. The pre-processor is a memory-mapped device, which is mapped to this range. When the pre-processor is addressed it reads a Warren instruction (of the translated Prolog program) from its own RAM, adaptively synthesizes a sequence of MC68000 instructions and constants and sends these directly to the CPU for execution. The MC68000 instructions for each Warren instruction are stored in ROM of the pre-processor. In general, the pre-processor translates one Warren instruction into a sequence of MC68000 instructions. The pre-processor contains its own RAM controller and ROM controller, which generate the addresses for the RAM and ROM of the pre-processor. The RAM controller manages the RAM instruction pointer. Each successive read operation of the MC68000 results in the pre-processor sending the next instruction (and optional constants) of the sequence to the CPU. If the sequence has been completed, a next read operation results in the first instruction of the sequence corresponding to the next Warren instruction of the program being send to the CPU. The known pre-processor supports one virtual machine (the Warren machine).
SUMMARY OF THE INVENTION
It is an object of the invention to provide a method and processing unit of the kind set forth which is more flexible. It is a further object of the invention to provide a method and processing unit of the kind set forth wherein the program is represented in a more compact form.
To meet the object of the invention, the method is characterised in that the method comprises the steps of defining for the program statements of the source program a program-specific virtual machine with a corresponding set of virtual machine instructions, such that the expression of the program statements in the sequence of instructions requires less storage space in the instruction memory compared to using only native instructions for expressing the program statements;
defining for the program-specific virtual machine an associated conversion means for converting virtual machine instructions of the program-specific virtual machine into native instructions of the microcontroller core; and
representing the associated conversion means in the processing unit. According to the invention, a program-specific virtual machine is defined for a program such that the program can be expressed in a form which is more compact than if the program was expressed in native instructions of the core. Also an associated conversion means is defined. The conversion means may for instance be implemented using a conversion table or microcode stored in ROM or dedicated logic, such as a PLD. The defined conversion means is represented in the processing unit. In this way, fast execution of the program is maintained, whereas at the same time a compact representation is achieved. This method is particularly suitable for use with embedded applications. In this case, the source program relates to all program statements initially represented in the embedded system (for instance, the program present in the system when the user purchases the system). The program may be stored in a permanent memory, such as ROM, or stored in a reprogrammable memory, such as EEPROM. For embedded applications it is highly desired that the code used to represent the embedded application program is compact and that the performance in executing the code is good. Typically, processing units used for embedded applications are based on a family concept, where for a specific application a processing unit is created f

LandOfFree

Say what you really think

Search LandOfFree.com for the USA inventors and patents. Rate them and share your experience with other people.

Rating

Converting program-specific virtual machine instructions... does not yet have a rating. At this time, there are no reviews or comments for this patent.

If you have personal experience with Converting program-specific virtual machine instructions..., we encourage you to share that experience with our LandOfFree.com community. Your opinion is very important and Converting program-specific virtual machine instructions... will most certainly appreciate the feedback.

Rate now

     

Profile ID: LFUS-PAI-O-2466117

  Search
All data on this website is collected from public sources. Our data reflects the most accurate information available at the time of publication.