Application running method and device, server and storage medium

CN114443177BActive Publication Date: 2026-09-08TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202011186489.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-10-30
Publication Date
2026-09-08
Estimated Expiration
2040-10-30

AI Technical Summary

Technical Problem

[0004]上述技术方案存在的问题是,终端基于客户端从云端获取游戏相关的视频流之前,需要由部署在云端的游戏服务器,在接收到终端发送的游戏启动指令后,从存储游戏数据的磁盘中加载游戏数据,对于大型游戏程序而言,该记载时间可能会达到分钟级别,使得用户需要等待数分钟的时间才能进行游玩,导致人机交互效率低,从而影响用户的游戏体验

Benefits of technology

[0029] In this application embodiment, an application running method is provided. By creating a child process based on the parent process of the application, since the child process shares the loaded resource data and code data with the parent process, the application can be run directly without having to start from scratch. Users do not need to wait for resources to load, which improves human-computer interaction efficiency and enhances the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114443177B_ABST
    Figure CN114443177B_ABST
Patent Text Reader

Abstract

The application provides an application running method and device, a server and a storage medium, and belongs to the technical field of computer. The method comprises the following steps: loading resource data and code data of an application program according to a parent process of the application program; in response to an application starting instruction of any terminal, creating a child process of the application program according to the parent process, and the child process and the parent process share the resource data and the code data; and returning a running result of the application program to the terminal according to the child process. According to the technical scheme, a child process is created according to a parent process of an application program, the child process and the parent process share loaded resource data and code data, so that the running result of the application program can be directly obtained without starting the application program from the beginning, the user does not need to wait for resource loading, the human-computer interaction efficiency is improved, and the use experience of the user is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to an application running method, apparatus, server, and storage medium. Background Technology

[0002] With the development of computer technology, application programs are becoming increasingly large. Large games, for example, can reach several gigabytes (GB), tens of gigabytes (GB), or even larger sizes, consuming significant amounts of terminal storage resources. Furthermore, running such large games places a heavy burden on the terminal's computing power, which is often beyond the capabilities of low- to mid-range devices. Therefore, there is an urgent need for a method that allows users to play large games on low- to mid-range devices.

[0003] Currently, in order to enable the playing of large-scale games on low- to medium-configuration terminals, cloud technology is used to run these large-scale games in the cloud. Users only need to install a small client on their terminal to play the game. The terminal can then obtain the game-related video stream from the cloud based on this client, thus enabling the playing of large-scale games. This method consumes less storage resources on the terminal and does not require the terminal to have high computing power.

[0004] The problem with the above technical solution is that before the terminal obtains the game-related video stream from the cloud based on the client, the game server deployed in the cloud needs to load the game data from the disk storing the game data after receiving the game start command sent by the terminal. For large game programs, this loading time may reach the level of minutes, which makes users have to wait for several minutes before they can play, resulting in low human-computer interaction efficiency and thus affecting the user's game experience. Summary of the Invention

[0005] This application provides an application running method, apparatus, server, and storage medium that allows users to directly obtain application results without having to run the application from scratch. Users do not need to wait for resources to load, improving human-computer interaction efficiency and enhancing the user experience. The technical solution is as follows:

[0006] On the one hand, an application running method is provided, the method comprising:

[0007] Load the application's resource data and code data based on the application's parent process;

[0008] In response to an application launch command from any terminal, a child process of the application is created based on the parent process, and the child process shares the resource data and code data with the parent process;

[0009] Based on the subprocess, the running results of the application are returned to the terminal.

[0010] On the other hand, an application running device is provided, the device comprising:

[0011] The data loading module is used to load the application's resource data and code data based on the application's parent process;

[0012] The child process creation module is used to respond to the application launch command of any terminal and create a child process of the application based on the parent process. The child process shares the resource data and code data with the parent process.

[0013] The execution result return module is used to return the execution result of the application to the terminal based on the subprocess.

[0014] In one optional implementation, the child process creation module is used to replicate the parent process in response to an application launch command from any terminal to obtain a child process of the application. The child process and the parent process correspond to different virtual spaces but the same physical space.

[0015] In one alternative implementation, the apparatus further includes:

[0016] The status data modification module is used to respond to the user status modification command of the terminal, and modify the user status data of the target user account according to the subprocess based on the copy-on-write mechanism. The target user account is the user account logged in on the terminal.

[0017] In one alternative implementation, the apparatus further includes:

[0018] The address sending module is used to return the network address of the content distribution server to the terminal, so that the terminal can obtain multimedia data from the content distribution server. The multimedia data is used to display the user status according to the user account logged in by the terminal.

[0019] In one optional implementation, loading the application's resource data and code data according to the application's parent process includes:

[0020] Obtain the application's resource data and code data;

[0021] During the execution of the parent process, the resource data is loaded to achieve the synthesis of audio and video data;

[0022] During the execution of the parent process, the code data is loaded to enable the internal interaction of the application.

[0023] In one alternative implementation, the application is a game application deployed on a cloud server based on cloud technology.

[0024] In one optional implementation, the child process creation module is used to create a sandbox environment in response to an application launch command from any terminal; and to replicate the parent process in the sandbox environment to obtain the child process of the game application.

[0025] On the other hand, a server is provided, the server including a processor and a memory, the memory being used to store at least one computer program, the at least one computer program being loaded and executed by the processor to implement the operations performed in the application running method of the present application embodiments.

[0026] On the other hand, a computer-readable storage medium is provided, wherein at least one computer program is stored in the computer-readable storage medium, the at least one computer program being loaded and executed by a processor to perform the operations performed as in the application running method in the embodiments of this application.

[0027] On the other hand, a computer program product or computer program is provided, which includes computer program code stored in a computer-readable storage medium. The server's processor reads the computer program code from the computer-readable storage medium, executes the computer program code, and causes the server to perform the application execution method provided in the foregoing aspects or various alternative implementations of the foregoing aspects.

[0028] The beneficial effects of the technical solutions provided in this application are:

[0029] In this application embodiment, an application running method is provided. By creating a child process based on the parent process of the application, since the child process shares the loaded resource data and code data with the parent process, the application can be run directly without having to start from scratch. Users do not need to wait for resources to load, which improves human-computer interaction efficiency and enhances the user experience. Attached Figure Description

[0030] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0031] Figure 1 This is a schematic diagram of the implementation environment of the application running method provided in the embodiments of this application;

[0032] Figure 2 This is a flowchart of an application running method provided according to an embodiment of this application;

[0033] Figure 3 This is a flowchart of another application operation method provided according to an embodiment of this application;

[0034] Figure 4 This is a schematic diagram of a copy-on-write mechanism provided according to an embodiment of this application;

[0035] Figure 5 This is a flowchart of another application operation method provided according to an embodiment of this application;

[0036] Figure 6 This is a block diagram of an application running device according to an embodiment of this application;

[0037] Figure 7 This is a structural block diagram of a terminal provided according to an embodiment of this application;

[0038] Figure 8 This is a schematic diagram of the structure of a server according to an embodiment of this application. Detailed Implementation

[0039] To make the objectives, technical solutions, and advantages of this application clearer, the embodiments of this application will be described in further detail below with reference to the accompanying drawings.

[0040] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.

[0041] The following is a brief introduction to the technologies that may be used in the embodiments of this application.

[0042] Cloud technology refers to a hosting technology that unifies a series of resources such as hardware, software, and networks within a wide area network or local area network to achieve data computing, storage, processing, and sharing.

[0043] Cloud technology is a collective term for network technologies, information technologies, integration technologies, management platform technologies, and application technologies applied to the cloud computing business model. It can form resource pools, providing flexible and convenient on-demand access. Cloud computing technology will become a crucial support. Backend services of technical network systems require substantial computing and storage resources, such as video websites, image websites, and many portal websites. With the rapid development and application of the internet industry, every item may have its own identification mark in the future, requiring transmission to backend systems for logical processing. Data at different levels will be processed separately, and various industry data will all require robust system support, which can only be achieved through cloud computing.

[0044] Cloud computing refers to the delivery and usage model of IT (Internet Technology) infrastructure, meaning obtaining necessary resources in an on-demand and easily scalable manner through a network. In a broader sense, cloud computing also refers to the delivery and usage model of services, meaning obtaining necessary services in an on-demand and easily scalable manner through a network. These services can be IT and software related, internet-related, or other services. Cloud computing is a product of the development and integration of traditional computer and network technologies such as grid computing, distributed computing, parallel computing, utility computing, network storage technologies, virtualization, and load balancing.

[0045] With the development of the internet, real-time data streams, and the diversification of connected devices, as well as the demands for search services, social networks, mobile commerce, and open collaboration, cloud computing has rapidly developed. Unlike previous parallel distributed computing, cloud computing will fundamentally revolutionize the entire internet model and enterprise management model.

[0046] A database, simply put, can be viewed as an electronic filing cabinet—a place to store electronic files, where users can perform operations such as adding, querying, updating, and deleting data. A "database" is a collection of data stored together in a certain way, capable of being shared by multiple users, with minimal redundancy, and independent of application programs.

[0047] Cloud gaming, also known as gaming on demand, is an online gaming technology based on cloud computing. It enables thin clients with relatively limited graphics processing and data processing capabilities to run high-quality games. In cloud gaming, the game does not reside on the player's terminal but runs on a cloud server. The cloud server renders the game scene as a video and audio stream, which is then transmitted to the player's terminal via the network. The player's terminal does not need powerful graphics processing and data processing capabilities; it only needs basic streaming media playback capabilities and the ability to receive player input commands and send them to the cloud server.

[0048] Copy-on-Write (COW) is an optimization strategy in computer programming. Its core idea is that if multiple callers simultaneously request the same resource (such as data storage in memory or on disk), they will all obtain the same pointer pointing to the same resource. Only when a caller attempts to modify the resource's contents will the system actually create a private copy for that caller, while the original resource seen by other callers remains unchanged.

[0049] A virtual address space is assigned to each process. For a 32-bit operating system (whose instruction size is at most 32 bits, so the address code is at most 32 bits), the size of the virtual address space is B, which is 0 to 4 GB, of which the kernel space is 1 GB.

[0050] The `fork` function in UNIX or UNIX-like systems splits a running program into two (almost) identical processes, each starting a thread that executes from the same location in the code. The threads in these two processes continue execution, as if two users had simultaneously launched two copies of the application. `fork` creates a new process, called a child process, which runs concurrently with the process that called the system call (the parent process). After creating the child process, both processes execute the instruction following `fork()`. The child process uses the same program counter, the same CPU registers (Central Processing Unit), and the same open files as in the parent process. `fork()` takes no arguments and returns an integer value. Below are the different values ​​returned by `fork()`: Negative value: Child process creation failed. Zero: Returns to the newly created child process. Positive value: Returns to the parent process or the caller. This value contains the process ID (Identity Document) of the newly created child process.

[0051] ELF (Executable and Linkable Format) is a file format used in computer science for binary files, executable files, object code, shared libraries, and kernel dumps. It is the primary executable file format for Linux.

[0052] A sandbox is a virtual system program that allows browsers or other programs, such as games, to run in a sandbox environment, where any data changes can be subsequently deleted. It creates a sandbox-like isolated operating environment where programs running within it do not have a permanent impact on the hard drive. In network security, a sandbox refers to a tool used in an isolated environment to test the behavior of untrusted files or applications. In this application embodiment, a sandbox refers to providing game services to game users in an isolated environment.

[0053] The following describes the implementation environment of the application running method provided in the embodiments of this application. Figure 1 This is a schematic diagram illustrating the implementation environment of the application running method provided in the embodiments of this application. See also... Figure 1 The implementation environment includes terminal 101 and server 102.

[0054] Terminal 101 and server 102 can be connected directly or indirectly via wired or wireless communication, and this application does not impose any restrictions on this.

[0055] Optionally, terminal 101 can be a smartphone, tablet, laptop, desktop computer, smart speaker, smartwatch, etc., but is not limited to these. Terminal 101 has a client application installed and running. This application can be any of the following: First-Person Shooter (FPS), Third-Person Shooter, Multiplayer Online Battle Arena (MOBA), Massive Multiplayer Online Role-Playing Game (MMORPG), Military Simulation Program, or Multiplayer Gunfight Survival Game. Illustratively, terminal 101 is a user-used terminal logged into with the user's account. The user uses terminal 101 to manipulate virtual objects located in a virtual scene, including but not limited to: adjusting body posture, crawling, walking, running, riding, jumping, driving, picking up, shooting, attacking, and throwing at least one of these activities. Illustratively, the virtual object is a virtual character, such as a realistic or anime character.

[0056] Optionally, server 102 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms. Server 102 is used to provide background services for applications supporting virtual scenarios. Optionally, server 102 undertakes the main computing work, and terminal 101 undertakes the secondary computing work; or, server 102 undertakes the secondary computing work, and terminal 101 undertakes the main computing work; or, server 102 and terminal 101 collaborate on computing using a distributed computing architecture.

[0057] Optionally, the virtual object controlled by terminal 101 (hereinafter referred to as the controlled virtual object) and other virtual objects controlled by terminal 101 (hereinafter referred to as other virtual objects) are in the same virtual scene. In this case, the controlled virtual object can interact with other virtual objects in the virtual scene. In some embodiments, the controlled virtual object and other virtual objects can be in an adversarial relationship. For example, the controlled virtual object and other virtual objects can belong to different teams and organizations. Adversarial virtual objects can engage in combative interaction by releasing skills to each other.

[0058] Those skilled in the art will understand that the number of terminals described above can be more or less. For example, there may be only one terminal, or there may be dozens or hundreds of terminals, or even more. This application does not limit the number of terminals or the type of device.

[0059] Optionally, the aforementioned wireless or wired networks use standard communication technologies and / or protocols. The network is typically the Internet, but can be any network, including but not limited to Local Area Networks (LANs), Metropolitan Area Networks (MANs), Wide Area Networks (WANs), mobile, wired or wireless networks, private networks, or any combination of virtual private networks. In some embodiments, technologies and / or formats, including Hyper Text Markup Language (HTML), Extensible Markup Language (XML), etc., are used to represent data exchanged over the network. Furthermore, conventional encryption technologies such as Secure Socket Layer (SSL), Transport Layer Security (TLS), Virtual Private Networks (VPNs), and Internet Protocol Security (IPsec) can be used to encrypt all or some links. In other embodiments, customized and / or dedicated data communication technologies can be used to replace or supplement the aforementioned data communication technologies.

[0060] Figure 2 This is a flowchart of an application running method provided according to an embodiment of this application, such as... Figure 2 As shown, this application embodiment uses a server applied in the cloud as an example for illustration. The application operation method includes the following steps:

[0061] 201. The server loads the application's resource data and code data based on the application's parent process.

[0062] In this embodiment, the application is any application deployed on a server in the cloud based on cloud technology. The application's resource data, code data, and user state data are stored in the server's storage medium, such as one or more disks or flash memory. Different user accounts have the same resource data and code data, but different user state data. Therefore, the server can preload the application's resource data and code data through the application's parent process, thereby achieving resource persistence.

[0063] 202. In response to an application launch command from any terminal, the server creates a child process of the application based on the parent process. The child process shares the resource data and code data with the parent process.

[0064] In this embodiment, the terminal is any terminal connected to server 102, as described above. Figure 1 The terminal 101 shown is an example. Users can send an application launch command to the server by triggering the client of an application installed on the terminal. Upon receiving the launch command, the server forks the parent process to obtain a child process that shares the loaded resource and code data with the parent process. This child process corresponds to the terminal and provides services to it. Thus, the terminal does not need to wait for the server to run the application from scratch; it can use the loaded resource and code data through the child process.

[0065] 203. The server returns the application's execution result to the terminal based on the subprocess.

[0066] In this embodiment of the application, when the server runs the subprocess, it can synthesize resource data based on code data to obtain the running result of the application and return the running result to the terminal corresponding to the subprocess.

[0067] In this application embodiment, an application running method is provided. By creating a child process based on the parent process of the application, since the child process shares the loaded resource data and code data with the parent process, the application can be run directly without having to start from scratch. Users do not need to wait for resources to load, which improves human-computer interaction efficiency and enhances the user experience.

[0068] above Figure 2 This is the main flow of the application running method provided in the embodiments of this application. The following description is based on an application scenario. In this application scenario, the application is a large-scale game program deployed in the cloud, and the server is a cloud server, such as... Figure 1 Server 102 shown in the image, see [link / reference]. Figure 3 As shown.

[0069] Figure 3 This is a flowchart of another application operation method provided according to an embodiment of this application, such as... Figure 3 As shown, this embodiment of the application uses a server corresponding to a large-scale game as an example for explanation. The method of running this application includes the following steps:

[0070] 301. The server loads the application's resource data and code data based on the application's parent process.

[0071] In this embodiment, the application is a large-scale game program deployed on a cloud server based on cloud technology. The resource data, code data, and user status data of the large-scale game program are stored in the server's storage medium. The server first obtains the application's resource data and code data, and then loads the resource data during the execution of the parent process to achieve the synthesis of audio and video data. Then, during the execution of the parent process, it loads the code data to achieve the internal interaction of the application.

[0072] Once the game program is compiled, the game's code data remains unchanged. The server loads the game's code data into a read-only memory segment, meaning that the code data can only be read and cannot be modified. For example, if the code data is in ELF file format, an ELF file typically includes a code segment and a data segment. During the ELF file loading phase, the operating system marks the memory pages corresponding to the code segment as read-only, thereby ensuring that the code data cannot be arbitrarily modified.

[0073] Game resource data serves as the raw material for synthesizing audio and video data such as visuals and sounds, including video data, sound data, image data, and various 3D (3D) model resources. The server allocates space for game resource data in the process's heap memory, and the game program can only read from this resource data, not write to it.

[0074] Each user account has different user status data, and this data changes as the game progresses. The server isolates the user status data by creating a separate game sub-process for each user account. Each sub-process is allocated an independent virtual address space, thus achieving mutual isolation (see step 302).

[0075] For example, a large game of several gigabytes in size would require several gigabytes of storage space on a mobile device if installed on the terminal. Furthermore, such large games require the terminal to process a significant amount of data in real time, placing considerable demands on its computing power. However, if only a client of a few tens or hundreds of megabytes is installed on the terminal, while the game server (several gigabytes in size) is deployed on a cloud gaming server, neither a large storage space nor high computing power is required, allowing users to play the game directly on their devices. The cloud gaming server continuously runs a parent process that pre-loads the code and resources needed to run the game to render the game visuals. Users can then access the game after logging in through the game client.

[0076] It should be noted that for different user accounts, the corresponding resource data and code data are the same, but the corresponding user status data are different. Therefore, the server can preload the game program's resource data and code data from storage media such as disks that store the game's resource data and code data through the application's parent process, thereby achieving resource persistence.

[0077] 302. In response to an application launch command from any terminal, the server creates a child process of the application based on the parent process. The child process shares the resource data and code data with the parent process.

[0078] In this embodiment, the user's terminal has a client of the aforementioned large game program installed, and this client is relatively small in size. The user logs into their user account through this client, and then the terminal sends a game launch request to the server through the client. This game launch request carries the terminal's identifier, the user's account identifier, and the application launch command. The server parses the application launch command from the game launch request and then forks the aforementioned parent process to obtain a child process of the application. This child process shares the loaded resource data and code data with the parent process. Since it does not need to reload the resource data and code data, the child process does not consume much memory. In addition, this child process corresponds to the terminal and is used to provide services to the terminal. Since the resource data and code data of the game program do not change frequently, by forking the parent process to obtain the corresponding child process, resource data and code data can be reused between user accounts, saving server memory resources. Furthermore, the terminal does not need to wait for the server to run the application from scratch; it can use the loaded resource data and code data through the child process, saving the server's time in loading resource data and code data.

[0079] For example, when a user logs into the game through the game client, the cloud gaming server replicates a dedicated child process for that user from the parent process. This child process then provides services to the user, so the cloud gaming server does not need to rerun the game program for that user, and the user does not need to wait for the game to load; they can directly access the game screen.

[0080] It should be noted that, to achieve isolation between user accounts, in response to the application launch command from any terminal, the server creates a sandbox environment, and then replicates the parent process within this sandbox environment to obtain the child process of the game application. That is, the server forks the game child process from the game's parent process within the sandbox environment, while the game's parent process, along with its loaded resource and code data, resides outside the sandbox environment. Furthermore, user state data, the parent process's user state data, also resides outside the sandbox environment. When a user's state changes, the server modifies the copy of the user state data within the sandbox environment using a copy-on-write mechanism, as described in step 303.

[0081] 303. In response to the user status modification command of the terminal, the server, based on the copy-on-write mechanism, modifies the user status data of the target user account according to the subprocess. The target user account is the user account logged in on the terminal.

[0082] In this embodiment, the user can control virtual objects to move within a virtual scene through the game program's client. Correspondingly, the user's account game state changes based on the user's actions. At this time, the terminal sends a user state modification request to the server through the client. This request carries the terminal identifier, the target user account's account identifier, and a user state modification instruction. The server parses the user state modification request, obtains the child process corresponding to the terminal identifier, and then copies the user state data using a copy-on-write mechanism. The server then modifies this copy of the user state data according to the user state modification instruction. The server's modification of the copy of the user state data does not affect the user state data corresponding to the parent process.

[0083] For example, when a user issues game commands through the client, it causes changes to the user's status data, such as changes in the location of virtual objects, changes in the assets of virtual objects, changes in the level of virtual objects, and changes in the appearance of virtual objects. When the server assigns a value to a variable or uses the `memcpy()` function to copy data, based on the copy-on-write mechanism, after a memory page is marked as COPY-ON-WRITE, the server allocates a new memory page (usually 4KB in size), copies the original memory page to the new address, and then performs the assignment or copy operation again. This does not affect the data in the original memory page, thus achieving isolation of user status data between different user accounts. See also Figure 4 As shown, Figure 4 This is a schematic diagram of a write-on-demand mechanism provided according to an embodiment of this application. For example... Figure 4As shown, before the server modifies the user account's state data, it forks a child process from the parent process. The resource data, code data, and user state data of both the parent and child processes point to the same memory page. When modifying the user account's state data, the server copies memory page C using a copy-on-write mechanism, obtaining a copy of memory page C. Then, it modifies this copy of memory page C within the sandbox environment. At this point, the resource data and code data of the parent and child processes still point to the same memory page, achieving resource and code data reuse.

[0084] 304. The server returns the application's execution result to the terminal based on the subprocess.

[0085] In this embodiment of the application, when the server runs the subprocess, it can synthesize the resource data based on the code data to obtain the running result of the application, and return the running result to the terminal corresponding to the subprocess, such as returning the rendered real-time game screen to the terminal for display.

[0086] For example, the server sends the rendered game screen to the terminal for display.

[0087] It's important to note that for a single user account, the server simply forks a child process for that account. Furthermore, after obtaining a copy of the user's state data, the server modifies the user state data within that copy each time a modification command is executed, rather than creating a new copy each time. Additionally, when a user exits the game, the server reclaims the game's child process.

[0088] It should be noted that large-scale game programs also include multimedia data such as game CG (Computer Graphics) animations. CG animations are often quite large, and loading them can cause users to wait, affecting their gaming experience. Optionally, the server can use CDN technology to store CG animations on various content distribution servers (CDN servers). Based on the user's game progress, the server can pre-return the network address of the content distribution server to the terminal. The terminal then retrieves the CG animations and other multimedia data from that content distribution server and displays the corresponding CG animations based on the user's account status.

[0089] It should be noted that, to make the application operation method shown in steps 301 to 304 above easier to understand, please refer to... Figure 5 As shown, Figure 5 This is a flowchart of another application operation method provided according to an embodiment of this application. For example... Figure 5As shown, this server is a cloud gaming server deployed in the cloud. Game resource data, code data, and user state data are stored on a disk used for storing game data. The cloud gaming server pre-loads the game's code data, resource data, and user state data into its memory through the game's parent process (also called the mother process). At this point, the code data can be called code memory data, the resource data resource memory data, and the user state data user state memory data. Then, when a new user starts the game, the cloud gaming server forks a child game process from the parent process in a sandbox environment. This child process reuses the aforementioned resource memory data and user state memory data. Then, when the user's state changes, the cloud gaming server, based on a copy-on-write mechanism, copies the user state memory data in the sandbox environment and modifies this copy.

[0090] In this application embodiment, an application running method is provided. By creating a child process based on the parent process of the application, since the child process shares the loaded resource data and code data with the parent process, the application can be run directly without having to start from scratch. Users do not need to wait for resources to load, which improves human-computer interaction efficiency and enhances the user experience.

[0091] Figure 6 This is a block diagram of an application running apparatus according to an embodiment of this application. The apparatus is used to perform the steps of the application running method described above. (See also...) Figure 6 The device includes: a data loading module 601, a subprocess creation module 602, and a running result return module 603.

[0092] The data loading module 601 is used to load the application's resource data and code data according to the application's parent process;

[0093] The child process creation module 602 is used to create a child process of the application based on the parent process in response to an application startup command from any terminal. The child process shares the resource data and code data with the parent process.

[0094] The execution result return module 603 is used to return the execution result of the application to the terminal based on the subprocess.

[0095] In one alternative implementation, the child process creation module 602 is used to replicate the parent process in response to an application startup command from any terminal to obtain a child process of the application. The child process corresponds to a different virtual space than the parent process, but to the same physical space.

[0096] In one alternative implementation, the device further includes:

[0097] The status data modification module 604 is used to respond to the user status modification command of the terminal and, based on the copy-on-write mechanism, modify the user status data of the target user account according to the subprocess. The target user account is the user account logged in to the terminal.

[0098] In one alternative implementation, the device further includes:

[0099] Address sending module 605 is used to return the network address of the content distribution server to the terminal, so that the terminal can obtain multimedia data from the content distribution server. The multimedia data is used to display the user status according to the user account logged in by the terminal.

[0100] In one alternative implementation, the application's resource data and code data are loaded based on the application's parent process, including:

[0101] Obtain the application's resource data and code data;

[0102] During the execution of the parent process, the resource data is loaded to achieve the synthesis of audio and video data;

[0103] During the execution of the parent process, the code data is loaded to enable the internal interactions of the application.

[0104] In one alternative implementation, the application is a game application deployed on a server in the cloud using cloud technology.

[0105] In one alternative implementation, the child process creation module 602 is used to create a sandbox environment in response to an application launch command from any terminal; and to replicate the parent process in the sandbox environment to obtain the child process of the game application.

[0106] In this application embodiment, an application running method is provided. By creating a child process based on the parent process of the application, since the child process shares the loaded resource data and code data with the parent process, the application can be run directly without having to start from scratch. Users do not need to wait for resources to load, which improves human-computer interaction efficiency and enhances the user experience.

[0107] It should be noted that the application running device provided in the above embodiments is only illustrated by the division of the above functional modules when running the application. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the application running device and the application running method embodiments provided in the above embodiments belong to the same concept, and the specific implementation process can be found in the method embodiments, which will not be repeated here.

[0108] Figure 7 This is a structural block diagram of a terminal 700 provided according to an embodiment of this application. The terminal 700 can be a portable mobile terminal, such as a smartphone, tablet computer, MP3 player (Moving Picture Experts Group Audio Layer III), MP4 player (Moving Picture Experts Group Audio Layer IV), laptop computer, or desktop computer. The terminal 700 may also be referred to as a user device, portable terminal, laptop terminal, desktop terminal, or other names.

[0109] Typically, terminal 700 includes a processor 701 and a memory 702.

[0110] Processor 701 may include one or more processing cores, such as a quad-core processor, an octa-core processor, etc. Processor 701 may be implemented using at least one hardware form selected from DSP (Digital Signal Processing), FPGA (Field-Programmable Gate Array), and PLA (Programmable Logic Array). Processor 701 may also include a main processor and a coprocessor. The main processor, also known as a CPU (Central Processing Unit), is used to process data in the wake-up state; the coprocessor is a low-power processor used to process data in the standby state. In some embodiments, processor 701 may integrate a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the screen. In some embodiments, processor 701 may also include an AI (Artificial Intelligence) processor, which is used to handle computational operations related to machine learning.

[0111] The memory 702 may include one or more computer-readable storage media, which may be non-transitory. The memory 702 may also include high-speed random access memory and non-volatile memory, such as one or more disk storage devices or flash memory devices. In some embodiments, the non-transitory computer-readable storage media in the memory 702 are used to store at least one computer program, which is executed by the processor 701 to implement the application running method provided in the method embodiments of this application.

[0112] In some embodiments, the terminal 700 may also optionally include a peripheral device interface 703 and at least one peripheral device. The processor 701, memory 702, and peripheral device interface 703 can be connected via a bus or signal line. Each peripheral device can be connected to the peripheral device interface 703 via a bus, signal line, or circuit board. Specifically, the peripheral device includes at least one of the following: a radio frequency circuit 704, a display screen 705, a camera assembly 706, an audio circuit 707, a positioning assembly 708, and a power supply 709.

[0113] Peripheral device interface 703 can be used to connect at least one I / O (Input / Output) related peripheral device to processor 701 and memory 702. In some embodiments, processor 701, memory 702 and peripheral device interface 703 are integrated on the same chip or circuit board; in some other embodiments, any one or two of processor 701, memory 702 and peripheral device interface 703 can be implemented on separate chips or circuit boards, which is not limited in this embodiment.

[0114] The radio frequency (RF) circuit 704 is used to receive and transmit RF (Radio Frequency) signals, also known as electromagnetic signals. The RF circuit 704 communicates with communication networks and other communication devices via electromagnetic signals. The RF circuit 704 converts electrical signals into electromagnetic signals for transmission, or converts received electromagnetic signals back into electrical signals. Optionally, the RF circuit 704 includes: an antenna system, an RF transceiver, one or more amplifiers, a tuner, an oscillator, a digital signal processor, a codec chipset, a user identity module card, etc. The RF circuit 704 can communicate with other terminals through at least one wireless communication protocol. This wireless communication protocol includes, but is not limited to: the World Wide Web, metropolitan area networks, intranets, various generations of mobile communication networks (2G, 3G, 4G, and 5G), wireless local area networks, and / or WiFi (Wireless Fidelity) networks. In some embodiments, the RF circuit 704 may also include circuitry related to NFC (Near Field Communication), which is not limited in this application.

[0115] Display screen 705 is used to display a UI (User Interface). This UI may include graphics, text, icons, videos, and any combination thereof. When display screen 705 is a touch display screen, it also has the ability to collect touch signals on or above its surface. These touch signals can be input as control signals to processor 701 for processing. In this case, display screen 705 can also be used to provide virtual buttons and / or a virtual keyboard, also known as soft buttons and / or a soft keyboard. In some embodiments, there may be one display screen 705, disposed on the front panel of terminal 700; in other embodiments, there may be at least two display screens, disposed on different surfaces of terminal 700 or in a folded design; in still other embodiments, display screen 705 may be a flexible display screen, disposed on a curved or folded surface of terminal 700. Furthermore, display screen 705 may be configured as a non-rectangular irregular shape, i.e., a non-rectangular screen. Display screen 705 may be made of materials such as LCD (Liquid Crystal Display) or OLED (Organic Light-Emitting Diode).

[0116] The camera assembly 706 is used to acquire images or videos. Optionally, the camera assembly 706 includes a front-facing camera and a rear-facing camera. Typically, the front-facing camera is located on the front panel of the terminal, and the rear-facing camera is located on the back of the terminal. In some embodiments, there are at least two rear-facing cameras, which are any one of a main camera, a depth-sensing camera, a wide-angle camera, and a telephoto camera, to achieve background blurring by fusion of the main camera and the depth-sensing camera, panoramic shooting by fusion of the main camera and the wide-angle camera, VR (Virtual Reality) shooting, or other fusion shooting functions. In some embodiments, the camera assembly 706 may also include a flash. The flash can be a single-color temperature flash or a dual-color temperature flash. A dual-color temperature flash refers to a combination of a warm-light flash and a cool-light flash, which can be used for light compensation at different color temperatures.

[0117] The audio circuit 707 may include a microphone and a speaker. The microphone is used to collect sound waves from the user and the environment, converting the sound waves into electrical signals that are input to the processor 701 for processing, or input to the radio frequency circuit 704 for voice communication. For stereo sound acquisition or noise reduction purposes, multiple microphones may be used, each located at a different part of the terminal 700. The microphone may also be an array microphone or an omnidirectional microphone. The speaker is used to convert the electrical signals from the processor 701 or the radio frequency circuit 704 into sound waves. The speaker may be a conventional diaphragm speaker or a piezoelectric ceramic speaker. When the speaker is a piezoelectric ceramic speaker, it can convert electrical signals not only into audible sound waves but also into inaudible sound waves for purposes such as distance measurement. In some embodiments, the audio circuit 707 may also include a headphone jack.

[0118] The positioning component 708 is used to determine the current geographic location of the terminal 700 in order to enable navigation or LBS (Location Based Service). The positioning component 708 can be a positioning component based on the US GPS (Global Positioning System), China's BeiDou system, or Russia's Galileo system.

[0119] Power supply 709 is used to supply power to the various components in terminal 700. Power supply 709 can be AC ​​power, DC power, a disposable battery, or a rechargeable battery. When power supply 709 includes a rechargeable battery, the rechargeable battery can be a wired rechargeable battery or a wireless rechargeable battery. A wired rechargeable battery is a battery that is charged via a wired line, and a wireless rechargeable battery is a battery that is charged via a wireless coil. The rechargeable battery can also be used to support fast charging technology.

[0120] In some embodiments, the terminal 700 further includes one or more sensors 710. The one or more sensors 710 include, but are not limited to: an accelerometer 711, a gyroscope 712, a pressure sensor 713, a fingerprint sensor 714, an optical sensor 715, and a proximity sensor 716.

[0121] Accelerometer 711 can detect the magnitude of acceleration along the three coordinate axes of a coordinate system established by terminal 700. For example, accelerometer 711 can be used to detect the components of gravitational acceleration along the three coordinate axes. Processor 701 can control display screen 705 to display the user interface in either a landscape or portrait view based on the gravitational acceleration signal acquired by accelerometer 711. Accelerometer 711 can also be used for games or for acquiring user motion data.

[0122] The gyroscope sensor 712 can detect the orientation and rotation angle of the terminal 700. The gyroscope sensor 712, in conjunction with the accelerometer sensor 711, can collect 3D motion data from the user on the terminal 700. Based on the data collected by the gyroscope sensor 712, the processor 701 can perform the following functions: motion sensing (e.g., changing the UI based on the user's tilt), image stabilization during shooting, game control, and inertial navigation.

[0123] The pressure sensor 713 can be disposed on the side bezel of the terminal 700 and / or the lower layer of the display screen 705. When the pressure sensor 713 is disposed on the side bezel of the terminal 700, it can detect the user's grip signal on the terminal 700, and the processor 701 can perform left / right hand recognition or quick operation based on the grip signal collected by the pressure sensor 713. When the pressure sensor 713 is disposed on the lower layer of the display screen 705, the processor 701 can control the operable controls on the UI interface based on the user's pressure operation on the display screen 705. The operable controls include at least one of button controls, scroll bar controls, icon controls, and menu controls.

[0124] The fingerprint sensor 714 is used to collect a user's fingerprint. The processor 701 identifies the user based on the fingerprint collected by the fingerprint sensor 714, or vice versa. When the user's identity is identified as trusted, the processor 701 authorizes the user to perform relevant sensitive operations, including unlocking the screen, viewing encrypted information, downloading software, making payments, and changing settings. The fingerprint sensor 714 can be located on the front, back, or side of the terminal 700. When the terminal 700 has a physical button or manufacturer logo, the fingerprint sensor 714 can be integrated with the physical button or manufacturer logo.

[0125] An optical sensor 715 is used to collect ambient light intensity. In one embodiment, the processor 701 can control the display brightness of the display screen 705 based on the ambient light intensity collected by the optical sensor 715. Specifically, when the ambient light intensity is high, the display brightness of the display screen 705 is increased; when the ambient light intensity is low, the display brightness of the display screen 705 is decreased. In another embodiment, the processor 701 can also dynamically adjust the shooting parameters of the camera assembly 706 based on the ambient light intensity collected by the optical sensor 715.

[0126] The proximity sensor 716, also known as a distance sensor, is typically located on the front panel of the terminal 700. The proximity sensor 716 is used to detect the distance between the user and the front of the terminal 700. In one embodiment, when the proximity sensor 716 detects that the distance between the user and the front of the terminal 700 is gradually decreasing, the processor 701 controls the display screen 705 to switch from a screen-on state to a screen-off state; when the proximity sensor 716 detects that the distance between the user and the front of the terminal 700 is gradually increasing, the processor 701 controls the display screen 705 to switch from a screen-off state to a screen-on state.

[0127] Those skilled in the art will understand that Figure 7 The structure shown does not constitute a limitation on terminal 700, and may include more or fewer components than shown, or combine certain components, or use different component arrangements.

[0128] Figure 8 This is a schematic diagram of a server structure according to an embodiment of this application. The server 800 can vary considerably due to different configurations or performance. It may include one or more Central Processing Units (CPUs) 801 and one or more memories 802. The memory 802 stores at least one computer program, which is loaded and executed by the processor 801 to implement the application running methods provided in the above-described method embodiments. Of course, the server may also have wired or wireless network interfaces, a keyboard, and input / output interfaces for input and output. The server may also include other components for implementing device functions, which will not be elaborated here.

[0129] This application also provides a computer-readable storage medium applied to a server. The computer-readable storage medium stores at least one computer program, which is loaded and executed by a processor to implement the operations performed by the server in the application running method of the above embodiments.

[0130] This application also provides a computer program product or computer program, which includes computer program code stored in a computer-readable storage medium. The server's processor reads the computer program code from the computer-readable storage medium and executes the computer program code, causing the server to perform the application execution methods provided in the various optional implementations described above.

[0131] Those skilled in the art will understand that all or part of the steps of the above embodiments can be implemented by hardware or by a program instructing related hardware. The program can be stored in a computer-readable storage medium, such as a read-only memory, a disk, or an optical disk.

[0132] The above description is merely an optional embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the protection scope of this application.

Claims

1. An application running method, characterized in that, The method, applied to a cloud-based server, includes: Based on the parent process of the game application, load the resource data and code data of the game application, which is deployed on a server in the cloud based on cloud technology; In response to an application launch command from any terminal, a sandbox environment is created. The sandbox environment is used to isolate user accounts. For different user accounts, their corresponding resource data and code data are the same, but their user status data is different. The parent process is replicated in the sandbox environment to obtain the child process of the game application. The child process shares the resource data and code data with the parent process. The resource data and code data loaded by the parent process are both located outside the sandbox environment. Receive a user status modification request, the user status modification request carrying a terminal identifier, an account identifier of the target user account, and a user status modification instruction, the target user account being the user account logged in on the terminal; Obtain the sub-process corresponding to the terminal identifier; Based on the copy-on-write mechanism, the user status data of the target user account is copied to obtain a copy of the user status data. According to the user state modification instruction, the copy of the user state data is modified in the sandbox environment where the subprocess corresponding to the terminal identifier resides; wherein, after the server obtains the copy of the user state data, for each newly received user state modification instruction, the newly received user state modification instruction is used to modify the copy of the user state data. Based on the subprocess, the running results of the game application are returned to the terminal.

2. The method according to claim 1, characterized in that, The child process and the parent process correspond to different virtual spaces, but the same physical space.

3. The method according to claim 1, characterized in that, Before returning the running result of the game application to the terminal according to the subprocess, the method further includes: The network address of the content distribution server is returned to the terminal, and the terminal obtains multimedia data from the content distribution server. The multimedia data is used to display the user status according to the user account logged in by the terminal.

4. The method according to claim 1, characterized in that, The step of loading the resource data and code data of the game application according to its parent process includes: Obtain the resource data and code data of the game application; During the execution of the parent process, the resource data is loaded to achieve the synthesis of audio and video data; During the execution of the parent process, the code data is loaded to enable the internal interaction of the game application.

5. An application operating device, characterized in that, The apparatus includes a method for executing an application running method applied to a server in the cloud. The data loading module is used to load the resource data and code data of the game application according to the parent process of the game application, wherein the game application is deployed on the server in the cloud based on cloud technology; A child process creation module is used to create a sandbox environment in response to an application launch command from any terminal. The sandbox environment is used to isolate user accounts. For different user accounts, their corresponding resource data and code data are the same, but their user state data is different. The parent process is replicated in the sandbox environment to obtain the child process of the game application. The child process shares the resource data and code data with the parent process. The resource data and code data loaded by the parent process are all located outside the sandbox environment. The status data modification module is used to obtain the sub-process corresponding to the terminal identifier; based on the copy-on-write mechanism, it copies the user status data of the target user account to obtain a copy of the user status data; according to the user status modification instruction, it modifies the copy of the user status data in the sandbox environment where the sub-process corresponding to the terminal identifier is located; wherein, after the server obtains the copy of the user status data, for each newly received user status modification instruction, the newly received user status modification instruction is used to modify the copy of the user status data. The execution result return module is used to return the execution result of the application to the terminal based on the subprocess.

6. A server, characterized in that, The server includes a processor and a memory, the memory being used to store at least one computer program, the at least one computer program being loaded by the processor and executing the application running method according to any one of claims 1 to 4.

7. A storage medium, characterized in that, The storage medium is used to store at least one computer program, which is used to execute the application running method according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Application starting method and device and intelligent terminal

    CN107193577A