Search

CN-121996325-A - Method, device, equipment and medium for optimizing starting speed of vehicle-mounted system and application

CN121996325ACN 121996325 ACN121996325 ACN 121996325ACN-121996325-A

Abstract

The invention discloses a method, a device, equipment and a medium for optimizing the starting speed of a vehicle-mounted system and an application, wherein the method comprises triggering pre-reading service according to system events of different sub-stages in the system starting stage, and loading the resource files corresponding to different sub-stages into a cache in an asynchronous loading mode, and in an application starting stage, responding to clicking operation of a user on a target application icon, and starting a main process of the target application while asynchronously triggering the pre-reading service to load the installation package resources of the target application. In the system starting stage, resources are preloaded into a memory cache through segmented triggering of a pre-reading service, so that the problem that a subsequent process is blocked due to synchronous IO waiting when the resources are needed is avoided, and IO bandwidth saturation caused by traditional one-time preloading is avoided through segmented preloading. When a user clicks an application icon, the application related resources are preloaded through asynchronous triggering of the pre-reading service, and the situation that the application is blocked to start a main thread in the preloading process is avoided.

Inventors

  • ZHANG SHIPENG
  • LI JIAO

Assignees

  • 北斗智联科技有限公司

Dates

Publication Date
20260508
Application Date
20260123

Claims (10)

  1. 1. A method for optimizing a start-up speed of an on-board system and an application, the method being applied to an on-board system start-up phase and an application start-up phase, the application start-up phase being subsequent to the on-board system start-up phase, the on-board system start-up phase comprising a plurality of successive sub-phases, the method comprising: In the starting stage of the vehicle-mounted system, the pre-reading service is triggered according to the system events of different sub-stages, the resource files corresponding to the different sub-stages are loaded into the memory cache in an asynchronous loading mode, In an application starting stage, responding to clicking operation of a user on a target application icon, and asynchronously triggering the pre-reading service to load the installation package resource of the target application while starting a main process of the target application.
  2. 2. The method for optimizing the starting speed of the vehicle-mounted system and the application according to claim 1, wherein the triggering the pre-reading service according to the system events of different sub-phases loads the resource files corresponding to the different sub-phases into the memory cache in an asynchronous loading manner, comprises: triggering the pre-reading service to load starting animation resources and system core library resources when the operating system completes the mounting of the basic file system; And triggering the pre-reading service to load the resources of the desktop application when the initialization of the system core service is completed.
  3. 3. The method for optimizing the starting speed of the vehicle-mounted system and the application according to claim 2, wherein the triggering the pre-reading service according to the system events of different sub-phases loads the resource files corresponding to the different sub-phases into the memory cache in an asynchronous loading manner, and further comprises: after desktop starting is completed, triggering the pre-reading service to load the data resources of the preset high-frequency application, and limiting the occupation of input and output resources of a loading task of the data resources of the high-frequency application; After the system is started and enters an interactable state, the applications declared as persistent in the system are orderly scheduled and started according to a preset strategy through a self-defined system management service.
  4. 4. The method for optimizing a starting speed of an on-vehicle system and an application according to claim 3, wherein the limiting the occupation of input/output resources of a loading task of a data resource of the high-frequency application includes: A limited input-output bandwidth is allocated for executing a process of loading data resources of a preset high frequency application.
  5. 5. The method for optimizing a startup speed of an on-board system and an application according to claim 3, wherein the sequentially scheduling the applications declared as persistent in the startup system according to a preset policy by a custom system management service includes: Modifying system framework code through the custom system management service to disable a default self-starting function for the persistence attribute of the non-system application; Reading a configuration file, wherein the configuration file comprises a white list application list allowing starting and a black list application list prohibiting starting; The system management service priority order starts the application in the white list application list; and monitoring a system load index, and starting the application which is not listed in the blacklist and is declared to be persistent when the system load index is lower than a threshold value.
  6. 6. The method for optimizing the start-up speed of an on-board system and application according to claim 5, wherein the system load indicator comprises one or more of cpu utilization, memory pressure status, and i/o latency.
  7. 7. The method for optimizing a starting speed of an on-vehicle system and an application according to claim 1, wherein responding to a clicking operation of a target application icon by a user, and asynchronously triggering the pre-reading service to load an installation package resource of the target application while a main process of the target application is started, comprises: when the fact that the user clicks the application icon is detected, acquiring an installation package path of the target application; Sending the installation package path to the pre-read service to trigger asynchronous pre-loading of the installation package; If the main process of the target application needs to access the part of the installation package which is not preloaded, the main process loads the part of the resource synchronously.
  8. 8. A start-up speed optimizing apparatus for an in-vehicle system and an application for executing the start-up speed optimizing method for an in-vehicle system and an application according to any one of claims 1 to 7, the method being applied to an in-vehicle system start-up phase and an application start-up phase, the application start-up phase being subsequent to the in-vehicle system start-up phase, the in-vehicle system start-up phase including a plurality of successive sub-phases, characterized in that the apparatus includes: The system starting preloading unit is used for triggering the pre-reading service according to system events of different sub-phases in the vehicle-mounted system starting phase and loading resource files corresponding to the different sub-phases into the memory cache in an asynchronous loading mode; And the application starting preloading unit is used for responding to the click operation of a user on a target application icon in an application starting stage, and asynchronously triggering the pre-reading service to load the installation package resource of the target application while the main process of the target application is started.
  9. 9. A computer device, comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; A memory for storing a computer program; A processor for implementing the steps of the method for optimizing the start-up speed of the vehicle-mounted system and application according to any one of claims 1 to 7 when executing a program stored on a memory.
  10. 10. A computer-readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method for optimizing the start-up speed of an in-vehicle system and an application according to any one of claims 1-7.

Description

Method, device, equipment and medium for optimizing starting speed of vehicle-mounted system and application Technical Field The present invention relates to the field of vehicle technologies, and in particular, to a method, an apparatus, a device, and a medium for optimizing a starting speed of a vehicle-mounted system and an application. Background The starting speed of the vehicle-mounted system is one of key indexes affecting the user experience. In vehicle-mounted system development, optimization of the start-up process has become an important issue. The traditional starting optimization method mainly reduces the initialization load by cutting unnecessary system services and other components, thereby shortening the starting time. However, with the increasing richness and complexity of the functions of the vehicle-mounted system, the optimization mode simply relying on component clipping approaches the performance bottleneck, and further significant reduction of the starting time is difficult to achieve. This problem is particularly pronounced on low-power hardware platforms. Taking a platform with a full-lineage T527 application processor and running an Android 13 system as an example, a significant gap exists between computing resources and high-end mobile devices. On such a platform, the system starting process faces multiple challenges, namely, firstly, the CPU computing power is limited, a plurality of system services and application processes are started concurrently to cause intense CPU resource competition, secondly, memory resources are tense, frequent memory allocation requests in the starting stage are easy to cause conflict, furthermore, input/output (IO) resources become key bottlenecks, a large amount of data are required to be loaded from storage equipment when the system is started, and the traditional IO scheduling and management mechanism is difficult to process high-concurrency reading requests efficiently, and system blocking is easy to cause. After the system is started due to the comprehensive effect of the resource bottleneck, even if a user interface is presented, the underlying service and the application program still can not be ready due to resource contention, so that the system can not respond to user operation in time temporarily, and the user experience is seriously affected. Disclosure of Invention The embodiment of the invention solves the problem of providing a vehicle-mounted system, a method, a device, equipment and a medium for optimizing the starting speed of an application. In a first aspect, an embodiment of the present invention provides a method for optimizing a start speed of a vehicle-mounted system and an application, where the method is applied to a vehicle-mounted system start stage and an application start stage, and the application start stage is after the vehicle-mounted system start stage, and the vehicle-mounted system start stage includes a plurality of continuous sub-stages, and the method includes: In the starting stage of the vehicle-mounted system, the pre-reading service is triggered according to the system events of different sub-stages, the resource files corresponding to the different sub-stages are loaded into the memory cache in an asynchronous loading mode, In an application starting stage, responding to clicking operation of a user on a target application icon, and asynchronously triggering the pre-reading service to load the installation package resource of the target application while starting a main process of the target application. In a second aspect, an embodiment of the present invention provides a device for optimizing a start-up speed of a vehicle-mounted system and an application, for executing the method for optimizing a start-up speed of a vehicle-mounted system and an application according to the first aspect, where the method is applied to a vehicle-mounted system start-up stage and an application start-up stage, and the application start-up stage is after the vehicle-mounted system start-up stage, and the vehicle-mounted system start-up stage includes a plurality of consecutive sub-stages, and the device includes: The system starting preloading unit is used for triggering the pre-reading service according to system events of different sub-phases in the vehicle-mounted system starting phase and loading resource files corresponding to the different sub-phases into the memory cache in an asynchronous loading mode; And the application starting preloading unit is used for responding to the click operation of a user on a target application icon in an application starting stage, and asynchronously triggering the pre-reading service to load the installation package resource of the target application while the main process of the target application is started. In a third aspect, an embodiment of the present invention provides a computer device, where the device includes a processor, a communication interface, a memory, and a communic