Patent ID: 8856769

Claim:
An apparatus for reducing code fraction comprising: an instruction conversion and reversion method; an adaptive instruction memory system; and an adaptive instruction memory controller wherein the apparatus for reducing code fraction is operable to: convert a single or a plurality of native instructions from compiled code, such as assembly code, to mixed packed normative and non-packed native instructions (PANIs), and native instructions and associative information of the packed normative instructions (NIPIs) in compilation time via the instruction conversion method; allocate PANIs and NIPIs of converted code to the dedicated, separate regions of distinct addresses in a single or a plurality of instruction memories; eliminate and hide qualified branch instructions that appear in the program from the NIPIs; revert the PANIs with the NIPIs stored in the dedicated, separate regions of distinct addresses in instruction caches and/or main memories to purely native instructions at runtime for compatible or identical execution via a single or a plurality of microprocessors; revert the PANIs to only native instructions for equivalent operation to the operation of the original program at runtime by identifying the PANIs and by accessing native instructions of the NIPIs from a single or a plurality of the PANI and the NIPI main instruction and the cache memories; prefetch both PANIs/NIPIs and/or fetch purely native instructions that will be executed by a single or a plurality of microprocessors by transmitting native instructions; stop and resume the PANIs/NIPIs prefetch and fetch operations in order to prevent a single or a plurality of microprocessors from discarding the instructions already fetched; perform dynamic inline expansions of subroutine caller instructions by neither employing subroutine call and return instructions nor duplicating the instructions of the subroutines during the PANIs/NIPIs prefetch and/or fetch operations; perform dynamic loop reversion of the packed loops until the microprocessors complete the associated loop operations; and protect original program from malicious and illegal copying, modification, usage of the program.