CN116048735B - Information processing method and object sharing method - Google Patents

Information processing method and object sharing method Download PDF

Info

Publication number
CN116048735B
CN116048735B CN202310319099.0A CN202310319099A CN116048735B CN 116048735 B CN116048735 B CN 116048735B CN 202310319099 A CN202310319099 A CN 202310319099A CN 116048735 B CN116048735 B CN 116048735B
Authority
CN
China
Prior art keywords
module
instruction
target
code object
file
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202310319099.0A
Other languages
Chinese (zh)
Other versions
CN116048735A (en
Inventor
郁磊
郑孝林
李三红
陈刚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Alibaba Cloud Computing Ltd
Original Assignee
Alibaba Cloud Computing Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Alibaba Cloud Computing Ltd filed Critical Alibaba Cloud Computing Ltd
Priority to CN202310319099.0A priority Critical patent/CN116048735B/en
Publication of CN116048735A publication Critical patent/CN116048735A/en
Application granted granted Critical
Publication of CN116048735B publication Critical patent/CN116048735B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45575Starting, stopping, suspending or resuming virtual machine instances
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45583Memory management, e.g. access or allocation
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The embodiment of the specification provides an information processing method and an object sharing method, wherein the information processing method comprises the following steps: obtaining virtual machine configuration information, and generating module identification information corresponding to a target module based on the virtual machine configuration information; loading a code object file according to the module identification information, and determining a target code object corresponding to the target module by analyzing the code object file; converting the target code object into a storage structure corresponding to a memory mirror image file; and writing a key value pair into the memory mirror image file by taking the module identification information as a storage key and taking an object code object of the storage structure as a storage value, wherein the key value pair is used for executing a task instruction by the target module.

Description

Information processing method and object sharing method
Technical Field
The embodiment of the specification relates to the technical field of virtual machines, in particular to an information processing method and an object sharing method.
Background
With the development of internet technology, cloud computing is applied in more and more scenes, and as a basis for supporting service operation, the computing power provided by the cloud computing determines the stability of service operation. And Serverless is an important technology of cloud computing, and can accelerate the starting speed of an application program in a cloud computing scene, so that a user can be quickly served. In the prior art, in a cloud computing scenario, writing of corresponding functional modules is usually completed by using a language with one-time writing and running everywhere, although the code writing stage is more convenient, the writing is needed to be completed by attaching to a language virtual machine, so that in the implementation process based on the language virtual machine technology, the virtual machine needs to load programs from byte codes or source code files, which causes the side effect of slow starting speed of the virtual machine, and therefore an effective scheme is needed to solve the problem.
Disclosure of Invention
In view of this, the present embodiment provides an information processing method. One or more embodiments of the present specification relate to an information processing apparatus, an object sharing method, an object sharing apparatus, an information processing system, a computing device, a computer-readable storage medium, and a computer program that solve the technical drawbacks existing in the prior art.
According to a first aspect of embodiments of the present specification, there is provided an information processing method including:
obtaining virtual machine configuration information, and generating module identification information corresponding to a target module based on the virtual machine configuration information;
loading a code object file according to the module identification information, and determining a target code object corresponding to the target module by analyzing the code object file;
converting the target code object into a storage structure corresponding to a memory mirror image file;
and writing a key value pair into the memory mirror image file by taking the module identification information as a storage key and taking an object code object of the storage structure as a storage value, wherein the key value pair is used for executing a task instruction by the target module.
According to a second aspect of the embodiments of the present specification, there is provided an information processing apparatus including:
The acquisition module is configured to acquire virtual machine configuration information and generate module identification information corresponding to a target module based on the virtual machine configuration information;
the analysis module is configured to load a code object file according to the module identification information and determine an object code object corresponding to the object module by analyzing the code object file;
the conversion module is configured to convert the target code object into a storage structure corresponding to the memory mirror image file;
and the storage module is configured to write a key value pair into the memory mirror image file by taking the module identification information as a storage key and taking a target code object of the storage structure as a storage value, wherein the key value pair is used for executing a task instruction by the target module.
According to a third aspect of embodiments of the present specification, there is provided an object sharing method, including:
receiving a target instruction of an associated target module;
determining target module identification information according to the target instruction, and constructing a target storage key based on the target module identification information;
inquiring a memory mirror image file according to the target storage key, and obtaining a target code object according to an inquiry result;
and calling the target module to execute the target instruction by using the target code object.
According to a fourth aspect of embodiments of the present specification, there is provided an object sharing apparatus including:
the receiving module is configured to receive a target instruction of the associated target module;
a construction module configured to determine target module identification information according to the target instruction, and construct a target storage key based on the target module identification information;
the query module is configured to query the memory mirror image file according to the target storage key and obtain a target code object according to a query result;
and the execution module is configured to call the target module to execute the target instruction by using the target code object.
According to a fifth aspect of embodiments of the present specification, there is provided an information processing system including:
the virtual machine control end and the virtual machine;
the virtual machine control end is used for managing the virtual machine and storing an information processing executable instruction, and the information processing executable instruction realizes the steps of the information processing method or the object sharing method when being executed by the virtual machine control end.
According to a sixth aspect of embodiments of the present specification, there is provided a computing device comprising:
a memory and a processor;
the memory is configured to store computer executable instructions that when executed by the processor perform steps of any of the information processing methods or object sharing methods described above.
According to a seventh aspect of the embodiments of the present specification, there is provided a computer-readable storage medium storing computer-executable instructions which, when executed by a processor, implement the steps of the above-described information processing method or object sharing method.
According to an eighth aspect of the embodiments of the present specification, there is provided a computer program, wherein the computer program, when executed in a computer, causes the computer to execute the steps of the above-described information processing method or object sharing method.
In order to avoid that the starting speed of the virtual machine is affected by using the language written everywhere in a large scale, the information processing method provided by the embodiment supports the module application program on the virtual machine in a mode of sharing the code object, so that the virtual machine can directly load the code object to be used in the memory mirror image file. In order to support the reading and use of the code objects of the virtual machine in the memory image file, after the configuration information of the virtual machine is acquired, module identification information of a target module corresponding to the application program is generated based on the configuration information of the virtual machine, and then the code object file is loaded according to the module identification information, so that the target code objects corresponding to the target module are obtained by analyzing the code object file, and the support of the target module in the virtual machine can be ensured. In order to accelerate the starting speed of the virtual machine, the code objects can be shared among application programs corresponding to the multiple modules, the object code objects can be converted into a storage structure corresponding to the memory mirror image file, then the module identification information is used as a storage key, the object code objects of the storage structure are used as storage values, key value pairs are written into the memory mirror image file, and the object code objects are stored in the memory mirror image file, so that the application programs corresponding to the multiple modules can read the corresponding code objects in the memory mirror image file when executing instructions, the problem that the starting speed of the object modules is low is solved, and the corresponding functional service is rapidly provided for the service.
Drawings
Fig. 1 is a schematic diagram of an information processing method according to an embodiment of the present disclosure;
FIG. 2 is a flow chart of a method of information processing provided in one embodiment of the present disclosure;
FIG. 3 is a flowchart of a processing procedure of an information processing method according to an embodiment of the present disclosure;
fig. 4 is a schematic structural view of an information processing apparatus provided in one embodiment of the present specification;
FIG. 5 is a flow chart of an object sharing method provided by one embodiment of the present disclosure;
FIG. 6 is a schematic diagram of an object sharing apparatus according to an embodiment of the present disclosure;
FIG. 7 is a block diagram of a computing device provided in one embodiment of the present description.
Detailed Description
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present description. This description may be embodied in many other forms than described herein and similarly generalized by those skilled in the art to whom this disclosure pertains without departing from the spirit of the disclosure and, therefore, this disclosure is not limited by the specific implementations disclosed below.
The terminology used in the one or more embodiments of the specification is for the purpose of describing particular embodiments only and is not intended to be limiting of the one or more embodiments of the specification. As used in this specification, one or more embodiments and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used in one or more embodiments of the present specification refers to and encompasses any or all possible combinations of one or more of the associated listed items.
It should be understood that, although the terms first, second, etc. may be used in one or more embodiments of this specification to describe various information, these information should not be limited by these terms. These terms are only used to distinguish one type of information from another. For example, a first may also be referred to as a second, and similarly, a second may also be referred to as a first, without departing from the scope of one or more embodiments of the present description. The word "if" as used herein may be interpreted as "at … …" or "at … …" or "responsive to a determination", depending on the context.
First, terms related to one or more embodiments of the present specification will be explained.
Programming language virtual machine: (Managed Runtime Environment, MRE) running the application on the host operating system. The main purpose is to provide a platform-independent programming language operating environment and allow applications to execute with the same behavior on different platforms.
Code object: the representation of code instructions in a virtual machine is typically obtained by compilation of a source code file or directly from a bytecode file, as code objects contain abstract high-level instructions, and thus an instruction (e.g., creating an object) may refer to a new code object.
Loader: the component that loads the code object may be in a disk directory, a compressed package, a network, etc. depending on the design of the virtual machine, the loader will read the persisted code object according to rules and parse it into code objects that can be used by the execution engine.
In the present specification, an information processing method, the present specification relates to an information processing apparatus, an object sharing method, an object sharing apparatus, an information processing system, a computing device, a computer-readable storage medium, and a computer program at the same time, and the following embodiments are described in detail one by one.
Referring to the schematic diagram shown in fig. 1, in order to avoid that the starting speed of the virtual machine is affected by using a language written everywhere in a large scale, the information processing method provided in this embodiment supports a module application program on the virtual machine by sharing a code object, so that the virtual machine can directly load the code object to be used in the memory image file. In order to support the reading and use of the code objects of the virtual machine in the memory image file, after the configuration information of the virtual machine is acquired, module identification information of a target module corresponding to the application program is generated based on the configuration information of the virtual machine, and then the code object file is loaded according to the module identification information, so that the target code objects corresponding to the target module are obtained by analyzing the code object file, and the support of the target module in the virtual machine can be ensured. In order to accelerate the starting speed of the virtual machine, the code objects can be shared among application programs corresponding to the multiple modules, the object code objects can be converted into a storage structure corresponding to the memory mirror image file, then the module identification information is used as a storage key, the object code objects of the storage structure are used as storage values, key value pairs are written into the memory mirror image file, and the object code objects are stored in the memory mirror image file, so that the application programs corresponding to the multiple modules can read the corresponding code objects in the memory mirror image file when executing instructions, the problem that the starting speed of the object modules is low is solved, and the corresponding functional service is rapidly provided for the service.
Fig. 2 shows a flowchart of an information processing method according to an embodiment of the present disclosure, which specifically includes the following steps.
Step S202, virtual machine configuration information is obtained, and module identification information corresponding to a target module is generated based on the virtual machine configuration information.
The information processing method provided by the embodiment is applied to a virtual machine execution engine, the virtual machine execution engine operates in a host machine, and virtual machines in the host machine are all programming language virtual machines and are used for realizing that application programs are executed on different platforms in the same behavior.
Specifically, the virtual machine configuration information is information configured by a user when the virtual machine in the programming language is used, and a functional module required to be used by the virtual machine in the programming language can be determined based on the information, so that a code object is stored in advance for an application program corresponding to a target module, the code object can be conveniently read from a memory mirror image file when the application program corresponding to the target module is started, and the starting speed of the application program is accelerated.
Correspondingly, the target module is a functional module associated with an application program to be run in the virtual machine and is used for executing a corresponding execution instruction to realize quick starting of the application program; and the target module can be constructed according to the use requirement of a user, and can also be a default module of the system. Correspondingly, the module identification information specifically refers to identification information corresponding to the target module, and the identification information can be an ID, a name, a character string playing a role in identification, or the like corresponding to the target module. And the module identification information and the target module have unique corresponding relation, so that when the code object is stored, the code object can be completed based on the module identification information with the unique corresponding relation, and the code object which does not correspond to the target module is prevented from being read from the memory mirror image file, and the target module cannot be started to execute the corresponding instruction.
Based on this, in order to enable the starting speed of the application module to be increased in the programming language virtual machine, an environment supporting the increased starting may be constructed in advance. In the process, the configuration information of the virtual machine can be firstly obtained so as to realize that the module identification information corresponding to the target module is firstly generated according to the configuration information of the virtual machine, the code object can be conveniently loaded and converted by combining the module identification information, and the unique corresponding relation with the module identification information is established so as to form the corresponding relation with the target module, and when the target module is called by any virtual machine on a host machine, the prestored code object can be read based on the storage relation so as to finish the starting of the application program, thereby accelerating the starting speed of the application program.
Further, considering that the configuration information of the virtual machine is configured by the user by using the programming language virtual machine, the configuration content of the virtual machine can be adjusted according to requirements, so that the configuration information can be combined with the content in the configuration information of the virtual machine when the module identification information uniquely corresponding to the target module is generated; in this embodiment, the specific implementation manner is as follows:
obtaining virtual machine configuration information comprising virtual machine service information and a code object file directory, and determining a target module; and under the condition that the target module is determined to be a non-default module, generating module name information corresponding to the target module according to the virtual machine service information or the code object file directory as the module identification information.
Specifically, the virtual machine service information specifically refers to information configured by a user controlling the virtual machine according to requirements, and the information can be used for determining functions of an application program to be run by the virtual machine; correspondingly, the code object file directory specifically refers to a directory corresponding to the code object file, and the formation of the directory is also obtained according to the code object file created by the user, and the code objects in the code object file are written by the user. Correspondingly, the default module specifically refers to a default and preset functional module of the system, which can be understood as a basic module. Correspondingly, the module name information specifically refers to the module name corresponding to the target module.
Based on the above, in order to obtain the module identification information of the unique corresponding target module, the loading and storage of the code object can be conveniently carried out later, the virtual machine configuration information comprising the virtual machine service information and the code object file directory can be obtained first, and the target module can be determined; and then under the condition that the target module is determined to be a non-default module, the fact that the target module does not have a module name is indicated, and then the module name information corresponding to the target module can be generated according to the virtual machine service information or the code object file catalog and used as the module identification information so as to facilitate subsequent use.
In practical application, when determining the module name information, considering that more modules are included in the virtual machine and different modules are used for executing different types of instructions, after determining the target module, it is required to determine whether the currently determined target module is a default module, that is, whether the currently determined target module is a default module of the system; if yes, the process is finished, namely that the code object is not needed to be loaded; if not, the code object is required to be loaded, and then the module name information corresponding to the target module can be constructed according to the service information of the virtual machine or the file catalogue of the code object, so that the subsequent use is convenient.
For example, a user configures service information and a code object file directory for a programming language virtual machine, when a code object corresponding to a target module needs to be stored in a memory mirror file, so that the memory mirror file is convenient for other modules to share, when the starting speed of other application programs is high, whether the target module is a default module preset by the programming language virtual machine can be determined first, if not, the service information or the code object file directory can be combined, and module name information N1 corresponding to the target module can be constructed, so that the subsequent use is convenient.
In summary, by constructing module identification information corresponding to the target module by combining service information or a code object file directory, a unique corresponding relationship between the module identification information and the target module can be ensured, and when a code object is written into a memory mirror file in the following process, a key value pair with a unique relationship can be established, so that the code object can be shared by other modules conveniently.
Step S204, loading a code object file according to the module identification information, and determining an object code object corresponding to the target module by analyzing the code object file.
Specifically, after the module identification information corresponding to the target module is obtained, further, in order to enable the target module to be called to execute the corresponding instruction in the following process, the code object file supporting the operation of the target module can be loaded at this stage so as to be resolved into the target code object corresponding to the target module through the virtual machine, so that the following use is convenient.
The code object file specifically refers to a file in the virtual machine for storing code instruction representations, and the corresponding target code object specifically refers to a code instruction representation corresponding to a target module in the virtual machine, so as to support the target module to run, realize execution of corresponding execution instructions, and start an application program to facilitate subsequent use.
Furthermore, when the code object file is loaded, the programming language virtual machine may have a corresponding code object file based on the configuration information or have not configured a related code object file, so that when the code object file is loaded, the programming language virtual machine may be completed in combination with the module identification information; in this embodiment, the specific implementation manner is as follows:
determining a file path corresponding to the module identification information by traversing the code object file directory, and reading the code object file based on the file path; or constructing a file acquisition request according to the module identification information, sending the file acquisition request to a file inquiry server, and receiving the code object file returned by the file inquiry server for the file acquisition request.
Specifically, the file path specifically refers to a read path for determining a stored code object according to a code object file directory; correspondingly, the file acquisition request specifically refers to a request for acquiring a code object file; correspondingly, the file query server specifically refers to a server capable of providing the code object file, and the server can be a server corresponding to any query platform and can feed back the code object file based on the file acquisition request.
Based on the above, in order to realize the loading of the code object file, the application program corresponding to the target module can be operated in a normal flow, and the code object can be stored after being loaded so as to be shared in an application stage; when the application program runs, considering that a plurality of code object files are already recorded in the stage of configuring the virtual machine by a previous user, and code objects needed to be used by a target module exist in the code object files, firstly traversing the code object file catalogue at the moment to firstly determine a file path corresponding to the module identification information according to the traversing result, and then storing the code object files in the space of the code objects based on the file path. The space may be a disk or memory, etc.
In addition, considering that the target module is a newly built module and no code object exists locally, a file acquisition request can be constructed based on the module identification information, so that a code object file can be requested to be downloaded from a file query server according to the file acquisition request, namely, the file acquisition request is sent to the file query server, and the code object file returned by the file query server for the file acquisition request is received, so that the subsequent use is convenient.
In practical application, when the code object file is loaded, the current virtual machine execution engine is considered to relate to a new code object, and the code object needs to be associated with a target module, so that the code object file directory can be traversed according to the module name information, or the corresponding code object file is searched from a network, so that after the code object file is obtained, the code object file can be stored in a subsequent mode, and the code object can be shared among a plurality of modules. In addition, since the loading mode of the code object file is based on the running of the application program, the code object file needs to be installed on the virtual machine after being obtained, so that the code objects corresponding to all programs are generated in the virtual machine and then stored.
That is, the construction stage can run the application program with a normal flow, trigger normal code loading, generate code objects required by all programs in the virtual machine memory after the program is run, and then combine the storage key and the storage value to realize writing the code objects into the memory sharing file so as to share the code objects in the virtual machine instance running subsequently.
In summary, by loading the code object file in the application program operation stage in different manners, the code object file can be conveniently restored later, so that the code object file can be shared among multiple instances of the virtual machine, and the code object file can be conveniently used in the application stage.
Further, after the code object file is obtained, considering that the virtual machine execution engine at the current stage may not be able to confirm the module identification information of the target module, the code object file is not able to be stored, so that subsequent processing needs to be performed in combination with the determined module identification information; in this embodiment, the specific implementation manner is as follows:
analyzing the code object file, and obtaining an executable code object as a target code object according to an analysis result; executing the step of converting the target code object into a storage structure corresponding to a memory mirror file under the condition that the target module is a default module; or executing the step of converting the target code object into a storage structure corresponding to the memory mirror file under the condition that the target module is a non-default module and has module identification information.
Based on the above, considering that the code object needs to be completed in the form of key value pairs when being transferred, the module identification information of the target module needs to be determined to be completed, after the code object file is obtained, the code object file can be analyzed first to obtain the executable code object as the target code object according to the analysis result; thereafter, if the target module is the default module, it is indicated that the target module has explicit module identification information, step S206 may be executed, that is, the step of converting the target code object into a storage structure corresponding to a memory image file is executed; or, if the target module is a non-default module and has module identification information, that is, it has explicit module identification information, step S206 may be executed, that is, the step of converting the target code object into a storage structure corresponding to the memory image file is executed.
Along the above example, after obtaining the module name N1 corresponding to the target module, the application program corresponding to the target module may be run in a normal flow, and in the running process, the code object file may be determined in the code object file directory by the module name N1, or the code object file may be directly searched from the network, so as to facilitate the subsequent storage of the code object associated with the target module in the code object file in the memory mirror file, so that the code object file may be shared between the modules. Further, after the code object file corresponding to the target module is obtained, the code object file can be resolved into an executable target code object through the virtual machine, and the executable target code object is installed on the virtual machine and used for running an application program. Meanwhile, in order to realize the sharing of the target code object in the subsequent stage, the detection target module is a default module, or the detection target module is not a default module but can determine that the module name is the default module, the detection target module can be used for the subsequent storage of key value pairs, and the code object can be shared between the realization modules.
In summary, whether the target module can clearly determine the module identification information is detected by different detection modes, so that the key value pairs meeting the requirements can be established in the storage stage, and the code objects can be shared among the modules.
Step S206, converting the target code object into a storage structure corresponding to the memory mirror file.
Specifically, after the module identification information corresponding to the target module and the target code object corresponding to the target module are obtained, it is explained that the programming language virtual machine can use the target module to run the corresponding instruction to start the application program; in order to realize that the code object can be shared among a plurality of modules of the virtual machine, the code object can be directly read for use in an application stage, so that the speed of starting the application program is accelerated, the target code object can be firstly converted into a storage structure corresponding to the memory mirror image file, and then the target code object corresponding to the storage structure of the memory mirror image file can be written into the memory mirror image file, so that other modules can directly read the target code object from the memory mirror image file for use without reloading the code object, and the starting speed of the application program corresponding to the modules can be effectively improved.
The memory mirror image file specifically refers to a memory for storing code objects to be used in the programming language virtual machine, and different modules can access the memory mirror image file to read the code objects during running; the data structure of the code object loaded is a writing structure, and cannot be persisted in the memory image file, so before the memory image file is written, conversion is required according to the storage structure of the memory image file. In practical applications, when the object code object is converted into the storage structure corresponding to the memory image file, the object code object may be implemented by using OpenJDK (software running on a machine), which is not limited in this embodiment.
And step S208, taking the module identification information as a storage key, taking a target code object of the storage structure as a storage value, and writing a key value pair into the memory mirror image file, wherein the key value pair is used for executing a task instruction by the target module.
Specifically, in the case that the module identification information uniquely corresponding to the target module and the target code object of the target module are obtained and the target code object is a storage structure corresponding to the memory mirror file, in order to realize sharing of the code object between the modules, the code object may be written into the memory mirror file in a key value pair manner, that is, the module identification information is taken as a storage key, the target code object of the storage structure is taken as a storage value, and the key value pair corresponding to the target code object of the target module is written into the memory mirror file. In the sharing stage, the target code object corresponding to the task instruction can be read by combining the key value pair in the memory mirror image file, and then the target code object can be used for supporting the target module to run and executing the task instruction, so that the corresponding application program is started. The storage key is a key, and the storage value is a value.
Further, after obtaining the module identification information and the target code object corresponding to the target module, in order to enable sharing of the code object among the plurality of modules, so as to accelerate starting of the application program, the code object may be written into the memory mirror image file in a key-value pair manner, so as to be used in an application stage conveniently, and in this embodiment, the specific implementation manner is as follows:
constructing the storage key according to the module identification information, and taking an object code object corresponding to the storage structure as the storage value; and constructing the key value pair according to the storage key and the storage value, and writing the key value pair into the memory mirror file.
Based on the above, after obtaining the module identification information and the object code object corresponding to the memory mirror image file storage structure, a storage key can be constructed according to the module identification information, and the object code object corresponding to the storage structure is used as a storage value; and constructing a key value pair according to the storage key and the storage value, and writing the key value pair into the memory mirror image file. The storage key may be constructed by an encryption algorithm or hash calculation, which is not limited in this embodiment.
In practical application, after the object code object in the memory is processed into a structure in the form of being transferred to the memory mirror image file, in order to be capable of being quickly queried and used in an application stage, the memory mirror image file can be written in the form of a key value pair by taking the object code object as a value according to a module name or a code object name, and the use in a subsequent sharing stage is facilitated.
According to the above example, after the target code object corresponding to the target module is obtained, the target code object can be converted into a storage structure corresponding to the memory mirror image file, then the code object of the storage structure is used as a value by taking the module name N1 corresponding to the target module as a key, and the key value pair is formed to write into the memory mirror image file, so that the memory mirror image file can be directly read in the sharing stage to complete the reading and use of the code object.
In addition, in the code object sharing stage, the execution strategy is to call the target module to execute the instruction to be executed, and in the process, in order to improve the starting speed of the application program corresponding to the target module, the stored code object can be directly read and used according to the module identification information corresponding to the instruction to be executed in the memory mirror image file, so that the acquisition time of the code object is saved, the starting is quickened, and the code object is used for realizing the execution of the instruction to be executed; in this embodiment, the specific implementation manner is as in step S2082 to step S2088.
Step S2082, receiving an instruction to be executed associated with the target module.
Specifically, the instruction to be executed specifically refers to an instruction which needs to be executed by the target module, and when the instruction is executed, an application program needs to be started to realize a corresponding function, so that after the instruction to be executed is received, identification information needs to be determined, a code object file corresponding to the identification information is read in a memory mirror image file, the target module is supported to run so as to execute the instruction to be executed, the response function of the application program is realized, and the starting speed can be increased by directly using a shared code object in the memory mirror image file, so that the instruction is responded and executed quickly.
In the implementation, since the instruction to be executed is triggered when the application program corresponding to the target module needs to be started, the instruction needs to be loaded first for subsequent processing, and in this embodiment, the implementation manner is as follows:
receiving a target instruction address, and acquiring the instruction to be executed based on the target instruction address; and under the condition that the to-be-executed instruction is associated with the target module, executing the steps of determining instruction module identification information according to the to-be-executed instruction and constructing an instruction storage key based on the instruction module identification information.
Specifically, the target instruction address is specifically an address of a stored instruction when an instruction to be executed needs to be executed, and is used for realizing that after the instruction to be executed is read, a target module can be called and a code object can be read subsequently, and an application program is started to execute the instruction, so that corresponding functions are realized.
Based on the above, after determining the target instruction address, the instruction to be executed may be acquired based on the target instruction address; under the condition that the instruction to be executed is associated with the target module, the instruction needs to be executed through the target module, the implementation of related functions in the application program is realized, and then the step S2084 is executed; and executing the steps of determining the instruction module identification information according to the instruction to be executed and constructing an instruction storage key based on the instruction module identification information.
And step S2084, determining instruction module identification information according to the instruction to be executed, and constructing an instruction storage key based on the instruction module identification information.
And S2086, inquiring the memory mirror image file according to the instruction storage key to obtain the target code object, and calling the target module to execute the instruction to be executed by using the target code object.
Specifically, the instruction module identification information specifically refers to module identification information corresponding to a module executing an instruction to be executed, and in the case that the instruction to be executed is associated with a target module, the instruction module identification information is the module identification information of the target module; correspondingly, the instruction storage key specifically refers to a storage key constructed based on the instruction module identification information.
Based on the above, under the condition that the to-be-executed instruction of the associated target module is obtained, the instruction module identification information can be determined according to the to-be-executed instruction, and the instruction storage key can be constructed based on the instruction module identification information; and then inquiring the memory mirror image file according to the instruction storage key to obtain a target code object according to the inquiry result, and calling the target module to execute the instruction to be executed by utilizing the target code object after the target code object is obtained, so that the application program in the supporting virtual machine provides the related function corresponding to the instruction to be executed.
In practical application, when the execution engine of the programming language virtual machine executes the instruction to be executed by the shared code object, firstly, the program command line designates the name of the entry function, and secondly, the virtual machine loads the code object where the name of the entry function is located; designating the current code of the execution engine as the first instruction of the entry function again, and entering the execution engine circulation at the moment, namely reading the code object for the target module to execute the instruction to be executed; in the process, a current instruction is acquired according to a target instruction address, then, when the current instruction is judged to relate to a new code, the module corresponding to the current instruction is judged to be a default module, or when the module name information is not the default module but can be determined, a storage key is constructed by combining the determined module name information, then, a memory mirror image file is queried based on the constructed storage key, so that a code object corresponding to the storage key is read from the memory mirror image file, then, the code object is installed on a corresponding virtual machine, and the current instruction can be executed by a calling module.
For example, after the instruction to be executed is obtained, the module name N2 corresponding to the instruction to be executed may be determined first, then a key2 is constructed based on the module name N2, then a memory mirror image file is queried based on the key2, a value2 is obtained according to the query result, and then the value2 is converted into a code object and is installed on the virtual machine, so that the instruction can be executed by the virtual machine calling module.
In summary, by reading the code object from the memory image file, the code object supporting target module executing instruction can be quickly obtained, so that the starting speed of the application program is increased, and the corresponding service function is provided for the user.
In addition, considering that the code object of the module that needs to execute the instruction to be executed does not exist in the memory image file, in order to be able to successfully execute the instruction to be executed, loading and application of the instruction code object may be completed in combination with the instruction module identification information, in this embodiment, the specific implementation manner is as follows:
under the condition that the to-be-executed instruction meets a code object acquisition condition, loading an instruction code object file based on the instruction module identification information corresponding to the to-be-executed instruction; determining an instruction code object of an instruction module corresponding to the instruction identification information by analyzing the instruction code object file; and calling the instruction module to execute the instruction to be executed by using the instruction code object.
Specifically, the instruction code object file specifically refers to a code object file corresponding to the instruction module identification information. Based on the above, when the instruction to be executed meets the code object acquiring condition, it is indicated that the execution module of the instruction to be executed does not exist at this time, and the corresponding code object does not exist in the memory mirror image file, and in order to enable execution of the instruction, the code object may be temporarily loaded, that is, the instruction code object file is loaded based on the instruction module identification information corresponding to the instruction to be executed; then determining an instruction code object of an instruction module corresponding to the instruction identification information by analyzing the instruction code object file; and finally, the instruction module can be called to execute the instruction to be executed by utilizing the instruction code object.
It should be noted that, in this embodiment, both the process of loading the instruction code object file and the process of analyzing the instruction code object may refer to the process of loading the code object file and analyzing the target code object in the above embodiment, and this embodiment is not described herein in detail.
That is, when the instruction code object file is loaded, the code object file directory may be traversed according to the instruction module name information, or the corresponding instruction code object file may be searched from the network, so as to obtain the instruction code object file, and after the instruction code object file is obtained, the instruction code object file may be resolved into the instruction code object by the virtual machine, and then installed onto the virtual machine, so that the call target module may execute the instruction by using the instruction code object, so as to achieve the relevant function of supporting the application program in the virtual machine to provide the corresponding instruction.
In summary, under the condition that the code objects cannot be read from the memory mirror image file, in order to ensure that the instructions can be executed, the code objects can be loaded by combining the identification information corresponding to the instructions, so that the loaded code objects are installed and used in a virtual mode, and therefore the instructions can be executed, and corresponding functions are realized.
Furthermore, considering that the instruction code object obtained at this time is the code object of the latest version compared with the memory mirror file, in order to be able to be shared for other modules in the following, it may be structured into the memory mirror file, and in this embodiment, the specific implementation manner is as follows:
Converting the instruction code object into a storage structure corresponding to the memory mirror image file; and writing a target key value pair into the memory mirror image file by taking the instruction module identification information as a storage key and taking an instruction code object of the storage structure as a storage value, wherein the target key value pair is used for the instruction module to execute the instruction to be executed.
Based on the above, after the new code object is directly loaded in the sharing stage, the code object can be stored in the memory mirror image file in consideration of the fact that the code object can be obtained possibly later and the part of the code object does not exist in the memory mirror image file, and the instruction code object is firstly converted into a storage structure corresponding to the memory mirror image file; and secondly, taking the identification information of the instruction module as a storage key and taking an instruction code object of a storage structure as a storage value, namely writing a target key value pair into the memory mirror image file, wherein the target key value pair is used for executing an instruction to be executed by the instruction module.
It should be noted that, the above-mentioned conversion and the process of writing the memory image file may be referred to the same or corresponding descriptions in the above-mentioned embodiments, and this embodiment is not repeated here.
In order to avoid that the starting speed of the virtual machine is affected by using the language written everywhere in a large scale, the information processing method provided by the embodiment supports the module application program on the virtual machine in a mode of sharing the code object, so that the virtual machine can directly load the code object to be used in the memory mirror image file. In order to support the reading and use of the code objects of the virtual machine in the memory image file, after the configuration information of the virtual machine is acquired, module identification information of a target module corresponding to the application program is generated based on the configuration information of the virtual machine, and then the code object file is loaded according to the module identification information, so that the target code objects corresponding to the target module are obtained by analyzing the code object file, and the support of the target module in the virtual machine can be ensured. In order to accelerate the starting speed of the virtual machine, the code objects can be shared among application programs corresponding to the multiple modules, the object code objects can be converted into a storage structure corresponding to the memory mirror image file, then the module identification information is used as a storage key, the object code objects of the storage structure are used as storage values, key value pairs are written into the memory mirror image file, and the object code objects are stored in the memory mirror image file, so that the application programs corresponding to the multiple modules can read the corresponding code objects in the memory mirror image file when executing instructions, the problem that the starting speed of the object modules is low is solved, and the corresponding functional service is rapidly provided for the service.
The following describes an example of an application of the information processing method provided in the present specification in a virtual machine start acceleration scenario, with reference to fig. 3. Fig. 3 shows a flowchart of a processing procedure of an information processing method according to an embodiment of the present disclosure, which specifically includes the following steps.
Step S302, virtual machine configuration information containing virtual machine service information and a code object file directory is obtained, and a target module is determined.
Step S304, under the condition that the target module is determined to be a non-default module, generating module name information corresponding to the target module as module identification information according to the virtual machine service information or the code object file directory.
In step S306, when it is determined that the target module satisfies the object creation condition, the file path corresponding to the identification information of the module is determined by traversing the code object file directory, and the code object file is read based on the file path.
In step S308, the code object file is parsed, and an executable code object is obtained as a target code object according to the parsing result.
In step S310, if the target module is a default module or the target module is a non-default module and has module identification information, the target code object is converted into a storage structure corresponding to the memory mirror file.
Step S312, a storage key is constructed according to the module identification information, and the object code object corresponding to the storage structure is used as a storage value.
Step S314, a key value pair is constructed according to the storage key and the storage value, and the key value pair is written into the memory mirror file.
In step S316, the target instruction address is received, and the instruction to be executed is obtained based on the target instruction address.
Step S318, under the condition that the to-be-executed instruction is associated with the target module, determining the instruction module identification information according to the to-be-executed instruction, and constructing an instruction storage key based on the instruction module identification information.
Step S320, inquiring the memory mirror image file according to the instruction storage key to obtain an object code object, and calling the object module to execute the instruction to be executed by using the object code object.
In summary, in order to avoid that the starting speed of the virtual machine is affected by using the language written everywhere in a large scale, the module application program on the virtual machine is supported by sharing the code object, so that the virtual machine can directly load the code object to be used in the memory mirror image file. In order to support the reading and use of the code objects of the virtual machine in the memory image file, after the configuration information of the virtual machine is acquired, module identification information of a target module corresponding to the application program is generated based on the configuration information of the virtual machine, and then the code object file is loaded according to the module identification information, so that the target code objects corresponding to the target module are obtained by analyzing the code object file, and the support of the target module in the virtual machine can be ensured. In order to accelerate the starting speed of the virtual machine, the code objects can be shared among application programs corresponding to the multiple modules, the object code objects can be converted into a storage structure corresponding to the memory mirror image file, then the module identification information is used as a storage key, the object code objects of the storage structure are used as storage values, key value pairs are written into the memory mirror image file, and the object code objects are stored in the memory mirror image file, so that the application programs corresponding to the multiple modules can read the corresponding code objects in the memory mirror image file when executing instructions, the problem that the starting speed of the object modules is low is solved, and the corresponding functional service is rapidly provided for the service.
Corresponding to the above method embodiments, the present disclosure further provides an embodiment of an information processing apparatus, and fig. 4 shows a schematic structural diagram of an information processing apparatus provided in one embodiment of the present disclosure. As shown in fig. 4, the apparatus includes:
an obtaining module 402, configured to obtain virtual machine configuration information, and generate module identification information corresponding to a target module based on the virtual machine configuration information;
the parsing module 404 is configured to load a code object file according to the module identification information, and determine an object code object corresponding to the object module by parsing the code object file;
a conversion module 406, configured to convert the target code object into a storage structure corresponding to a memory mirror file;
the storage module 408 is configured to write a key value pair into the memory mirror file with the module identification information as a storage key and the object code object of the storage structure as a storage value, where the key value pair is used for executing a task instruction by the target module.
In an alternative embodiment, the acquisition module 402 is further configured to:
obtaining virtual machine configuration information comprising virtual machine service information and a code object file directory, and determining a target module; and under the condition that the target module is determined to be a non-default module, generating module name information corresponding to the target module according to the virtual machine service information or the code object file directory as the module identification information.
In an alternative embodiment, in a case where it is determined that the target module meets the object creation condition, the parsing module 404 is further configured to:
determining a file path corresponding to the module identification information by traversing the code object file directory, and reading the code object file based on the file path; or constructing a file acquisition request according to the module identification information, sending the file acquisition request to a file inquiry server, and receiving the code object file returned by the file inquiry server for the file acquisition request.
In an alternative embodiment, the parsing module 404 is further configured to:
analyzing the code object file, and obtaining an executable code object as a target code object according to an analysis result; after the step of determining the target code object corresponding to the target module by analyzing the code object file is executed, the method further comprises the following steps: executing the step of converting the target code object into a storage structure corresponding to a memory mirror file under the condition that the target module is a default module; or executing the step of converting the target code object into a storage structure corresponding to the memory mirror file under the condition that the target module is a non-default module and has module identification information.
In an alternative embodiment, the memory module 408 is further configured to:
constructing the storage key according to the module identification information, and taking an object code object corresponding to the storage structure as the storage value; and constructing the key value pair according to the storage key and the storage value, and writing the key value pair into the memory mirror file.
In an alternative embodiment, the apparatus further comprises:
the calling module is configured to receive an instruction to be executed associated with the target module; determining instruction module identification information according to the instruction to be executed, and constructing an instruction storage key based on the instruction module identification information; and inquiring the memory mirror image file according to the instruction storage key to obtain the target code object, and calling the target module to execute the instruction to be executed by using the target code object.
In an alternative embodiment, the calling module is further configured to:
receiving a target instruction address, and acquiring the instruction to be executed based on the target instruction address; and under the condition that the to-be-executed instruction is associated with the target module, executing the steps of determining instruction module identification information according to the to-be-executed instruction and constructing an instruction storage key based on the instruction module identification information.
In an alternative embodiment, the apparatus further comprises:
the loading file module is configured to load an instruction code object file based on the instruction module identification information corresponding to the instruction to be executed under the condition that the instruction to be executed meets a code object acquisition condition; determining an instruction code object of an instruction module corresponding to the instruction identification information by analyzing the instruction code object file; and calling the instruction module to execute the instruction to be executed by using the instruction code object.
In an alternative embodiment, the apparatus further comprises:
the writing file module is configured to convert the instruction code object into a storage structure corresponding to the memory mirror image file;
and writing a target key value pair into the memory mirror image file by taking the instruction module identification information as a storage key and taking an instruction code object of the storage structure as a storage value, wherein the target key value pair is used for the instruction module to execute the instruction to be executed.
In summary, in order to avoid that the starting speed of the virtual machine is affected by using the language written everywhere in a large scale, the module application program on the virtual machine is supported by sharing the code object, so that the virtual machine can directly load the code object to be used in the memory mirror image file. In order to support the reading and use of the code objects of the virtual machine in the memory image file, after the configuration information of the virtual machine is acquired, module identification information of a target module corresponding to the application program is generated based on the configuration information of the virtual machine, and then the code object file is loaded according to the module identification information, so that the target code objects corresponding to the target module are obtained by analyzing the code object file, and the support of the target module in the virtual machine can be ensured. In order to accelerate the starting speed of the virtual machine, the code objects can be shared among application programs corresponding to the multiple modules, the object code objects can be converted into a storage structure corresponding to the memory mirror image file, then the module identification information is used as a storage key, the object code objects of the storage structure are used as storage values, key value pairs are written into the memory mirror image file, and the object code objects are stored in the memory mirror image file, so that the application programs corresponding to the multiple modules can read the corresponding code objects in the memory mirror image file when executing instructions, the problem that the starting speed of the object modules is low is solved, and the corresponding functional service is rapidly provided for the service.
The above is a schematic scheme of an information processing apparatus of the present embodiment. It should be noted that, the technical solution of the information processing apparatus and the technical solution of the information processing method belong to the same concept, and details of the technical solution of the information processing apparatus, which are not described in detail, can be referred to the description of the technical solution of the information processing method.
The embodiment also provides an object sharing method, and fig. 5 shows a flowchart of the object sharing method according to an embodiment of the present disclosure, which specifically includes the following steps.
Step S502, a target instruction associated with a target module is received.
Step S504, determining target module identification information according to the target instruction, and constructing a target storage key based on the target module identification information.
And step S506, inquiring the memory mirror image file according to the target storage key, and obtaining a target code object according to the inquiring result.
Step S508, calling the target module to execute the target instruction by using the target code object.
Corresponding to the method embodiment, the present disclosure further provides an object sharing device embodiment, and fig. 6 shows a schematic structural diagram of an object sharing device provided in one embodiment of the present disclosure. As shown in fig. 6, the apparatus includes:
A receiving module 602 configured to receive a target instruction associated with a target module;
a construction module 604 configured to determine target module identification information according to the target instruction, and construct a target storage key based on the target module identification information;
a query module 606 configured to query the memory image file according to the target storage key, and obtain a target code object according to a query result;
an execution module 608 configured to invoke the target module to execute the target instruction using the target code object.
The above is a schematic scheme of an object sharing apparatus of the present embodiment. It should be noted that, the technical solution of the object sharing apparatus and the technical solution of the object sharing method belong to the same concept, and details of the technical solution of the object sharing apparatus, which are not described in detail, can be referred to the description of the technical solution of the object sharing method.
Fig. 7 illustrates a block diagram of a computing device 700 provided in accordance with one embodiment of the present description. The components of computing device 700 include, but are not limited to, memory 710 and processor 720. Processor 720 is coupled to memory 710 via bus 730, and database 750 is used to store data.
Computing device 700 also includes access device 740, access device 740 enabling computing device 700 to communicate via one or more networks 760. Examples of such networks include public switched telephone networks (PSTN, public Switched Telephone Network), local area networks (LAN, local Area Network), wide area networks (WAN, wide Area Network), personal area networks (PAN, personal Area Network), or combinations of communication networks such as the internet. The access device 740 may include one or more of any type of network interface, wired or wireless, such as a network interface card (NIC, network interface controller), such as an IEEE802.11 wireless local area network (WLAN, wireless Local Area Network) wireless interface, a worldwide interoperability for microwave access (Wi-MAX, worldwide Interoperability for Microwave Access) interface, an ethernet interface, a universal serial bus (USB, universal Serial Bus) interface, a cellular network interface, a bluetooth interface, a near field communication (NFC, near Field Communication) interface, and so forth.
In one embodiment of the application, the above-described components of computing device 700, as well as other components not shown in FIG. 7, may also be connected to each other, such as by a bus. It should be understood that the block diagram of the computing device illustrated in FIG. 7 is for exemplary purposes only and is not intended to limit the scope of the present application. Those skilled in the art may add or replace other components as desired.
Computing device 700 may be any type of stationary or mobile computing device, including a mobile computer or mobile computing device (e.g., tablet, personal digital assistant, laptop, notebook, netbook, etc.), mobile phone (e.g., smart phone), wearable computing device (e.g., smart watch, smart glasses, etc.), or other type of mobile device, or a stationary computing device such as a desktop computer or personal computer (PC, personal Computer). Computing device 700 may also be a mobile or stationary server.
The processor 720 is configured to execute computer-executable instructions that, when executed by the processor, implement the steps of the information processing method or the object sharing method described above.
The foregoing is a schematic illustration of a computing device of this embodiment. It should be noted that, the technical solution of the computing device and the technical solution of the information processing method or the object sharing method belong to the same concept, and details of the technical solution of the computing device, which are not described in detail, can be referred to the description of the technical solution of the information processing method or the object sharing method.
An embodiment of the present disclosure further provides an information processing system, including: the virtual machine control end and the virtual machine; the virtual machine control end is used for managing the virtual machine and storing an information processing executable instruction, and the information processing executable instruction realizes the steps of an information processing method or an object sharing method when being executed by the virtual machine control end.
The above is a schematic scheme of an information processing system of the present embodiment. It should be noted that, the technical solution of the information processing system and the technical solution of the information processing method or the object sharing method belong to the same concept, and details of the technical solution of the information processing system, which are not described in detail, can be referred to the description of the technical solution of the information processing method or the object sharing method.
An embodiment of the present disclosure also provides a computer-readable storage medium storing computer-executable instructions that, when executed by a processor, implement the steps of the above-described information processing method or object sharing method.
The above is an exemplary version of a computer-readable storage medium of the present embodiment. It should be noted that, the technical solution of the storage medium and the technical solution of the information processing method or the object sharing method belong to the same concept, and details of the technical solution of the storage medium, which are not described in detail, can be referred to the description of the technical solution of the information processing method or the object sharing method.
An embodiment of the present specification also provides a computer program, wherein the computer program, when executed in a computer, causes the computer to execute the steps of the above-described information processing method or object sharing method.
The above is an exemplary version of a computer program of the present embodiment. It should be noted that, the technical solution of the computer program and the technical solution of the information processing method or the object sharing method belong to the same concept, and details of the technical solution of the computer program, which are not described in detail, can be referred to the description of the technical solution of the information processing method or the object sharing method.
The foregoing describes specific embodiments of the present disclosure. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims can be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
The computer instructions include computer program code that may be in source code form, object code form, executable file or some intermediate form, etc. The computer readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a U disk, a removable hard disk, a magnetic disk, an optical disk, a computer Memory, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), an electrical carrier signal, a telecommunications signal, a software distribution medium, and so forth. It should be noted that the computer readable medium contains content that can be appropriately scaled according to the requirements of jurisdictions in which such content is subject to legislation and patent practice, such as in certain jurisdictions in which such content is subject to legislation and patent practice, the computer readable medium does not include electrical carrier signals and telecommunication signals.
It should be noted that, for simplicity of description, the foregoing method embodiments are all expressed as a series of combinations of actions, but it should be understood by those skilled in the art that the embodiments are not limited by the order of actions described, as some steps may be performed in other order or simultaneously according to the embodiments of the present disclosure. Further, those skilled in the art will appreciate that the embodiments described in the specification are all preferred embodiments, and that the acts and modules referred to are not necessarily all required for the embodiments described in the specification.
In the foregoing embodiments, the descriptions of the embodiments are emphasized, and for parts of one embodiment that are not described in detail, reference may be made to the related descriptions of other embodiments.
The preferred embodiments of the present specification disclosed above are merely used to help clarify the present specification. Alternative embodiments are not intended to be exhaustive or to limit the invention to the precise form disclosed. Obviously, many modifications and variations are possible in light of the teaching of the embodiments. The embodiments were chosen and described in order to best explain the principles of the embodiments and the practical application, to thereby enable others skilled in the art to best understand and utilize the invention. This specification is to be limited only by the claims and the full scope and equivalents thereof.

Claims (13)

1. An information processing method, comprising:
obtaining virtual machine configuration information of a programming language virtual machine, and generating module identification information corresponding to a target module based on the virtual machine configuration information, wherein the virtual machine configuration information comprises virtual machine service information and a code object file directory, and the target module is a functional module of an application program;
Loading a code object file according to the module identification information, and determining a target code object corresponding to the target module by analyzing the code object file;
converting the target code object into a storage structure corresponding to a memory mirror image file;
and writing a key value pair into the memory mirror image file by taking the module identification information as a storage key and taking an object code object of the storage structure as a storage value, wherein the key value pair is used for executing a task instruction by the target module.
2. The method of claim 1, wherein the obtaining virtual machine configuration information, generating module identification information corresponding to a target module based on the virtual machine configuration information, comprises:
obtaining virtual machine configuration information comprising virtual machine service information and a code object file directory, and determining a target module;
and under the condition that the target module is determined to be a non-default module, generating module name information corresponding to the target module according to the virtual machine service information or the code object file directory as the module identification information.
3. The method according to claim 2, wherein in a case where it is determined that the target module satisfies an object creation condition, the loading the code object file according to the module identification information includes:
Determining a file path corresponding to the module identification information by traversing the code object file directory, and reading the code object file based on the file path; or alternatively, the process may be performed,
and constructing a file acquisition request according to the module identification information, sending the file acquisition request to a file inquiry server, and receiving the code object file returned by the file inquiry server for the file acquisition request.
4. The method of claim 1, wherein the determining, by parsing the code object file, the target code object corresponding to the target module includes:
analyzing the code object file, and obtaining an executable code object as a target code object according to an analysis result;
after the step of determining the target code object corresponding to the target module by analyzing the code object file is executed, the method further comprises the following steps:
executing the step of converting the target code object into a storage structure corresponding to a memory mirror file under the condition that the target module is a default module; or alternatively, the process may be performed,
and executing the step of converting the target code object into a storage structure corresponding to the memory mirror file under the condition that the target module is a non-default module and has module identification information.
5. The method of claim 1, wherein the writing the key value pair into the memory mirror file with the module identification information as a storage key and the object code object of the storage structure as a storage value comprises:
constructing the storage key according to the module identification information, and taking an object code object corresponding to the storage structure as the storage value;
and constructing the key value pair according to the storage key and the storage value, and writing the key value pair into the memory mirror file.
6. The method according to any one of claims 1-5, wherein the step of writing a key value pair into the memory mirror file using the module identification information as a storage key and the object code object of the storage structure as a storage value further comprises:
receiving an instruction to be executed associated with the target module;
determining instruction module identification information according to the instruction to be executed, and constructing an instruction storage key based on the instruction module identification information;
and inquiring the memory mirror image file according to the instruction storage key to obtain the target code object, and calling the target module to execute the instruction to be executed by using the target code object.
7. The method of claim 6, the receiving an instruction to be executed associated with the target module, comprising:
receiving a target instruction address, and acquiring the instruction to be executed based on the target instruction address;
and under the condition that the to-be-executed instruction is associated with the target module, executing the steps of determining instruction module identification information according to the to-be-executed instruction and constructing an instruction storage key based on the instruction module identification information.
8. The method of claim 6, after the step of receiving instructions to be executed associated with the target module, further comprising:
under the condition that the to-be-executed instruction meets a code object acquisition condition, loading an instruction code object file based on the instruction module identification information corresponding to the to-be-executed instruction;
determining an instruction code object of an instruction module corresponding to the instruction module identification information by analyzing the instruction code object file;
and calling the instruction module to execute the instruction to be executed by using the instruction code object.
9. The method according to claim 8, further comprising, after the step of determining, by parsing the instruction code object file, the instruction code object of the instruction module corresponding to the instruction module identification information is performed:
Converting the instruction code object into a storage structure corresponding to the memory mirror image file;
and writing a target key value pair into the memory mirror image file by taking the instruction module identification information as a storage key and taking an instruction code object of the storage structure as a storage value, wherein the target key value pair is used for the instruction module to execute the instruction to be executed.
10. An object sharing method applied to a programming language virtual machine comprises the following steps:
receiving a target instruction associated with a target module, wherein the target module is a functional module of an application program;
determining target module identification information according to the target instruction, and constructing a target storage key based on the target module identification information;
inquiring a memory mirror image file according to the target storage key, and obtaining a target code object according to an inquiry result;
and calling the target module to execute the target instruction by using the target code object.
11. An information processing system, comprising:
the virtual machine control end and the virtual machine;
the virtual machine control side is configured to manage the virtual machine and store information processing executable instructions that, when executed by the virtual machine control side, implement the steps of the method of any one of claims 1 to 10.
12. A computing device, comprising:
a memory and a processor;
the memory is configured to store computer executable instructions, the processor being configured to execute the computer executable instructions, which when executed by the processor, implement the steps of the method of any one of claims 1 to 10.
13. A computer readable storage medium storing computer executable instructions which when executed by a processor implement the steps of the method of any one of claims 1 to 10.
CN202310319099.0A 2023-03-23 2023-03-23 Information processing method and object sharing method Active CN116048735B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310319099.0A CN116048735B (en) 2023-03-23 2023-03-23 Information processing method and object sharing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310319099.0A CN116048735B (en) 2023-03-23 2023-03-23 Information processing method and object sharing method

Publications (2)

Publication Number Publication Date
CN116048735A CN116048735A (en) 2023-05-02
CN116048735B true CN116048735B (en) 2023-08-29

Family

ID=86124059

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310319099.0A Active CN116048735B (en) 2023-03-23 2023-03-23 Information processing method and object sharing method

Country Status (1)

Country Link
CN (1) CN116048735B (en)

Citations (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103092618A (en) * 2013-01-15 2013-05-08 东南大学 Dalvik virtual machine just-in-time compilation (JIT) acceleration method based on software Cache
CN103645945A (en) * 2013-11-04 2014-03-19 天津汉柏信息技术有限公司 Automatic probing and drive loading method of virtual network interface card
CN110727504A (en) * 2019-10-21 2020-01-24 百度在线网络技术(北京)有限公司 Code execution method and device and rendering equipment
CN110764779A (en) * 2019-10-21 2020-02-07 百度在线网络技术(北京)有限公司 Packaging method, registration method, device and rendering equipment
CN110874468A (en) * 2018-08-31 2020-03-10 华为技术有限公司 Application program safety protection method and related equipment
WO2020207087A1 (en) * 2019-04-11 2020-10-15 创新先进技术有限公司 Information read and write method and device based on blockchain
CN112379973A (en) * 2020-12-01 2021-02-19 腾讯科技(深圳)有限公司 Heavy loading method and device
CN112463303A (en) * 2020-12-01 2021-03-09 中国工商银行股份有限公司 JAVA virtual machine class loading method and system
CN112685141A (en) * 2021-03-12 2021-04-20 北京易捷思达科技发展有限公司 Virtual machine starting method, device, equipment and storage medium
CN113282377A (en) * 2021-07-23 2021-08-20 阿里云计算有限公司 Code loading method, equipment, system and storage medium under server-free architecture
CN113297057A (en) * 2020-03-26 2021-08-24 阿里巴巴集团控股有限公司 Memory analysis method, device and system
CN113448722A (en) * 2020-03-28 2021-09-28 阿里巴巴集团控股有限公司 Mapping method of process memory and instance processing method based on serverless architecture
CN114217878A (en) * 2021-12-23 2022-03-22 中国建设银行股份有限公司 Object loading method and system
CN114443229A (en) * 2022-01-29 2022-05-06 苏州浪潮智能科技有限公司 Mirror image file mounting method and device, electronic equipment and storage medium
CN115422270A (en) * 2022-08-25 2022-12-02 珠海金山数字网络科技有限公司 Information processing method and device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8505003B2 (en) * 2010-04-28 2013-08-06 Novell, Inc. System and method for upgrading kernels in cloud computing environments

Patent Citations (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103092618A (en) * 2013-01-15 2013-05-08 东南大学 Dalvik virtual machine just-in-time compilation (JIT) acceleration method based on software Cache
CN103645945A (en) * 2013-11-04 2014-03-19 天津汉柏信息技术有限公司 Automatic probing and drive loading method of virtual network interface card
CN110874468A (en) * 2018-08-31 2020-03-10 华为技术有限公司 Application program safety protection method and related equipment
WO2020207087A1 (en) * 2019-04-11 2020-10-15 创新先进技术有限公司 Information read and write method and device based on blockchain
CN110727504A (en) * 2019-10-21 2020-01-24 百度在线网络技术(北京)有限公司 Code execution method and device and rendering equipment
CN110764779A (en) * 2019-10-21 2020-02-07 百度在线网络技术(北京)有限公司 Packaging method, registration method, device and rendering equipment
CN113297057A (en) * 2020-03-26 2021-08-24 阿里巴巴集团控股有限公司 Memory analysis method, device and system
CN113448722A (en) * 2020-03-28 2021-09-28 阿里巴巴集团控股有限公司 Mapping method of process memory and instance processing method based on serverless architecture
CN112379973A (en) * 2020-12-01 2021-02-19 腾讯科技(深圳)有限公司 Heavy loading method and device
CN112463303A (en) * 2020-12-01 2021-03-09 中国工商银行股份有限公司 JAVA virtual machine class loading method and system
CN112685141A (en) * 2021-03-12 2021-04-20 北京易捷思达科技发展有限公司 Virtual machine starting method, device, equipment and storage medium
CN113282377A (en) * 2021-07-23 2021-08-20 阿里云计算有限公司 Code loading method, equipment, system and storage medium under server-free architecture
CN114217878A (en) * 2021-12-23 2022-03-22 中国建设银行股份有限公司 Object loading method and system
CN114443229A (en) * 2022-01-29 2022-05-06 苏州浪潮智能科技有限公司 Mirror image file mounting method and device, electronic equipment and storage medium
CN115422270A (en) * 2022-08-25 2022-12-02 珠海金山数字网络科技有限公司 Information processing method and device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
M. Šipek ; B. Mihaljević ; A. Radovan.Exploring Aspects of Polyglot High-Performance Virtual Machine GraalVM.《2019 42nd International Convention on Information and Communication Technology, Electronics and Microelectronics (MIPRO)》.2019,全文. *

Also Published As

Publication number Publication date
CN116048735A (en) 2023-05-02

Similar Documents

Publication Publication Date Title
CN110569250B (en) Management method and device for analysis library of Internet of things network element
CN113190254A (en) Updating method and device
CN115421764A (en) Method, device, equipment and storage medium for identifying module to be upgraded
CN116089542A (en) JDBC-based database adaptation method and device
CN116048735B (en) Information processing method and object sharing method
CN115586872A (en) Container mirror image management method, device, equipment and storage medium
CN113590179B (en) Plug-in detection method and device, electronic equipment and storage medium
CN115525396A (en) Application management method and device based on cloud protogenesis
CN112286947B (en) Method and device for keeping data consistency of different storage systems
CN112148318B (en) Application package release method, application method, device, medium, server and equipment
CN114201174A (en) Construction method and device of hybrid mobile application, electronic equipment and storage medium
CN111669423B (en) Batch processing method and system of network isolation space based on user mode protocol stack
CN114237736A (en) Page resource loading method, system, device, computer equipment and storage medium
CN113805854A (en) Method, system and device for realizing Hook of application layer based on Linux system and storage medium
CN113157348A (en) Game starting method and device, computer equipment and storage medium
CN109840156B (en) Data caching method and equipment, storage medium and terminal thereof
CN112491956A (en) Method and device for upgrading communication module in Internet of things equipment and computer equipment
CN111090854A (en) Target program execution and conversion method, device, terminal and storage medium
CN117883789B (en) Data acquisition method, apparatus, device, readable storage medium, and program product
CN116974653B (en) Class loading method and system
CN117785228B (en) Application deployment method and device
CN117724726B (en) Data processing method and related device
US20230205494A1 (en) Resource file loading method, apparatus, electronic device and storage medium
US20230385075A1 (en) Networked Universal Code Package Provider
CN114139149A (en) Detection method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant