JAVA intelligent card and virtual machine component optimization method thereof
A technology of a virtual machine component and an optimization method, applied in the field of smart cards, can solve the problems of high complexity of the query address and cumbersome solution process, and achieve the effect of simplifying the process of finding the method address and improving the execution efficiency.
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0031] like figure 1 As shown, when the JAVA smart card virtual machine calls a method, the calling method format used includes a virtual reference opcode of one byte and an index byte of two bytes:
[0032] (1) Virtual reference opcode: Set the corresponding virtual reference opcode for different calling methods in the JAVA smart card virtual machine in advance. For example, the virtual reference opcode of the static reference calling method is 0x8D, and the virtual reference operation of the special reference calling method The code is 0x8C;
[0033] (2) Index byte: The index byte indicates the location address of the method, specifically the index combination of the relative address, including the package index (Package index) and the constant pool address index (Constant Pool index); two-byte index bytes Represented as 0x0000~0xFFFF;
[0034] Specifically, the constant pool list can be found through the package address index, and the information of all packages is listed...
example
[0038] Among them, the specific method called by the JAVA smart card virtual machine is a collection of code blocks that implement a specific function, such as a special reference (invokespecial, used to call some instance methods that require special processing, such as instance initialization methods, private methods, parent class methods, etc.) , static reference (invokestatic, used to call class methods);
[0039] For example, if the JAVA smart card virtual machine wants to call a static reference calling method, the calling method format used includes a one-byte virtual reference opcode 0x8D and a two-byte index byte 0x6666. The calling method format is as follows:
[0040]
[0041]
[0042] Find the real address where the static reference calling method is located according to the two-byte index byte 0x6666 in the calling method format, specifically: the first 7 bits of the first 0x66 byte in the index byte 0x6666 indicate the package address index, the first 0x66 Th...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 


