Class pre-loading method and device based on embedded real-time Java virtual machine

A technology of java virtual machine and java class, which is applied in the field of class loading, can solve problems such as not being able to meet real-time requirements, not being able to apply class loading methods, and loading time uncertainty, so as to achieve the effect of avoiding uncertainty

Active Publication Date: 2012-07-11
PEKING UNIV
View PDF3 Cites 15 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

But the existing class loading method, on the one hand, because other classes need to be loaded in the program execution process except the basic class, resulting in the uncertainty of the loading time, can not meet the real-time requirements; on the other hand, the class The resources of the loader and core library classes are extremely large, and the resources of the embedded system are limited, which cannot carry the existing class loader and core library classes.
Therefore, in the prior art, the class loading method cannot be applied to a real-time embedded computing environment

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Class pre-loading method and device based on embedded real-time Java virtual machine
  • Class pre-loading method and device based on embedded real-time Java virtual machine
  • Class pre-loading method and device based on embedded real-time Java virtual machine

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0018] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the accompanying drawings.

[0019] figure 1 The present invention is based on the pre-class loading method of the embedded real-time Java virtual machine. Such as figure 1 As shown, the pre-loading method includes the following steps:

[0020] Step S100, modifying the java class file of the class loader, and setting a loading method for class loading according to the class list.

[0021] Step S200, modifying the jni class of the virtual machine kernel, setting a pre-loading method for calling the loading method to pre-load all classes required by the application;

[0022] Step S300, obtaining a class list including all classes required by the application;

[0023] Step S400, according to the class preloading method, preload all the classes required by the ...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention provides a class pre-loading method and device based on embedded real-time Java virtual machine. The method comprises modifying Java class files of a class loader, and setting a loading method for class loading according to class lists; modifying the jni class of a virtual machine kernel, and setting a class pre-loading method for calling the loading method to pre-load all classes required by application programs; acquiring the class list containing all classes required by the application programs; and pre-loading all classes required by the application programs based on the class list according to the class pre-loading method. The inventive method and device can avoid the defects of time jitter and embedded system resource limitation, and realize class pre-loading in an embedded real-time Java virtual machine.

Description

technical field [0001] The invention relates to class loading technology, in particular to a pre-class loading method and device based on an embedded real-time Java virtual machine. Background technique [0002] The Java platform has already had a large base of developers so far, and its application fields have expanded from the initial server and desktop fields to real-time and embedded fields. However, different from the traditional computing environment, embedded real-time computing is a kind of computing with limited computing resources, and at the same time requires a high degree of certainty in the operation of virtual machines. [0003] Currently, there are two mechanisms for class loading: pre-loading and on-demand loading. In order to optimize the system and improve the execution speed of the program, the Java runtime environment will load all the basic classes required for Java runtime into the memory at the beginning of the JRE (Java Runtime Environment, Java run...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G06F9/445
CPCG06F9/44521
Inventor 曹东刚荀娜梅宏
Owner PEKING UNIV
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products