Executable Image for Dynamic Code Patching in Constrained Memory

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing technologies face challenges in dynamically generating and patching computer code in computing environments with restricted executable memory writing, leading to inefficiencies and incompatibility with immutable operating systems like iOS.

Innovation Solution

A method utilizing a process virtual machine to generate and update executable images, employing a JIT compiler and interpreter to modify code on the target device, enabling dynamic code generation and patching within constrained environments.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Adaptability or versatility

If dynamic code generation is used to enable rapid adjustments to computer programs, then adaptability is improved, but compatibility with constrained operating systems is worsened

Engineering Contradiction:
ImproveadaptabilityVSAvoidcompatibility
Core Design Contradiction:
Adaptability or versatilityVSReliability

Solution Approach 1:

The patent introduces an intermediary executable image that acts as a bridge between the constrained operating system and the dynamic code generation process. The executable image contains the interpreter or JIT compiler code, allowing dynamic code generation to occur within the constraints of the operating system by mediating between the two incompatible requirements

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The system segments the computer program into multiple components: the executable image containing the interpreter/JIT compiler, and the dynamically generated code. This segmentation allows the executable image to be loaded and executed in a constrained environment while enabling dynamic code generation through the interpreter or JIT compiler component

Inventive Principle:
Principle #1Segmentation

2Reliability

If remote servers are used to enable dynamic code generation, then compatibility with constrained operating systems is improved, but execution speed is worsened

Engineering Contradiction:
ImprovecompatibilityVSAvoidexecution speed
Core Design Contradiction:
ReliabilityVSSpeed

Solution Approach 1:

The system enables self-service by embedding the interpreter or JIT compiler within the executable image that runs locally on the constrained operating system. This eliminates the need for remote server communication, allowing the system to perform dynamic code generation autonomously and improving execution speed while maintaining compatibility

Inventive Principle:
Principle #25Self-service

3Adaptability or versatility

If cross-compilation is used to account for different target platform characteristics, then adaptability to different platforms is improved, but compilation time is worsened

Engineering Contradiction:
ImproveadaptabilityVSAvoidcompilation time
Core Design Contradiction:
Adaptability or versatilityVSLoss of time

Solution Approach 1:

The system performs preliminary action by including the interpreter or JIT compiler in the executable image before runtime. This preliminary preparation allows the system to adapt to different target platform characteristics dynamically during execution without requiring time-consuming cross-compilation processes

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The system utilizes parameter changes by allowing the interpreter or JIT compiler to adjust its behavior based on detected target platform characteristics at runtime. The executable image can modify execution parameters to account for different CPU features, operating system endianness, and other platform-specific attributes without requiring recompilation

Inventive Principle:
Principle #35Parameter changes

Data Source

PatentEP3084596B1Executable code for constrained computing environments
Publication Date: 2018.06.20 ORACLE INT CORP
  • EP3084596B1 patent drawingFigure 1
  • EP3084596B1 patent drawingFigure 2
  • EP3084596B1 patent drawingFigure 3

AI summary

A system and method for facilitating adjusting computer code running in computing environments where writing of executable memory is restricted. An example method includes using a virtual machine to generate a first executable image from software code, and employing the first executable image to selectively modify the virtual machine and the first executable image, resulting in an updated virtual machine and a second executable image. The second executable image represents an updated version of the first executable image. To transform dynamic code, such as natively produced computer code, into one or more executable images for running on constrained devices, embodiments may leverage existing dynamic code generators (e.g., within Java HotSpot Performance Engine, also simply called HotSpot), selectively modifying them to generate different, i.e., updated code that is usable on subsequent runs of the associated software application, thereby effectively enabling modification of executable code used to run the software.