File reading method, electronic equipment, chip system, storage medium and program product
By selecting the appropriate pointer offset method according to the specific parameters of the target file, the problem of slow reading of the electronic equipment file system is solved, and the file reading efficiency and user experience are improved.
Patent Information
- Application Number
- CN202411205455.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-29
- Publication Date
- 2025-01-28
- Estimated Expiration
- 2044-08-29
AI Technical Summary
When the file system of existing electronic devices reads files, there are problems such as slow reading speed and long reading time.
By determining the file size, file pointer offset, file pointer offset frequency, and/or file opening duration, choose a more suitable pointer offset method, including the first pointer deviation method (FAST SEEK) and the first. Normal seek.
Improved file reading efficiency, reduced the occupation of electronic equipment memory, and enhanced the user experience.
Smart Images

Figure CN119377172A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of terminal technology, and in particular to a file reading method, electronic device, chip system, storage medium and program product. Background Art
[0002] The file system of some electronic devices can be used to manage and read various files, such as fonts, user interface (UI) resources, configuration files, log files, etc.
[0003] However, in some scenarios, the file system may have slow reading speed and long reading time when reading files. Summary of the invention
[0004] The embodiments of the present application provide a file reading method, an electronic device, a chip system, a storage medium and a program product, which are applied to the field of terminal technology and can enable the electronic device to select a more appropriate pointer offset method when reading a target file, thereby improving the file reading efficiency and thus improving the user experience.
[0005] In the first aspect, the embodiment of the present application proposes a file reading method. The method includes: when the target parameter of the target file meets the first condition, the target file is read by a first pointer offset method; when the target parameter of the target file does not meet the first condition, the target file is read by a second pointer offset method; wherein, compared with the second pointer offset method, the first pointer offset method has the following characteristics: long time to open the file, large memory usage and fast reading speed, and the target parameter includes one or more of the following: the size of the target file, the pointer offset of the target file, the offset frequency of the target file, and the use frequency of the target file. By judging one or more of the file size, file pointer offset size, file pointer offset frequency and / or the single opening time of the target file, the file pointer offset method used when reading the target file is determined. In this way, the file system can select a suitable file reading method according to the actual situation of each file, which can reduce the memory usage of the electronic device, and can read the file content faster, improve the efficiency of reading files, and thus improve the user experience.
[0006] In conjunction with the first aspect, in some implementations of the first aspect, the first condition includes one or more of the following: the size of the target file is greater than or equal to a first threshold, the pointer offset of the target file is greater than or equal to a second threshold, the offset frequency of the target file is greater than or equal to a third threshold, and the use frequency of the target file is greater than or equal to a fourth threshold. When the electronic device determines that the target file meets the first condition, it can be understood that it is more appropriate to use a fast seek method when reading the target file, which can improve the efficiency of reading the file, thereby improving the user experience.
[0007] In combination with the first aspect, in some implementations of the first aspect, a first configuration file is configured in the electronic device, and when the target parameter of the target file meets the first condition, the target file is read in a first pointer offset manner, including: when the first configuration file includes an identifier of the target file, the target file is read in a first pointer offset manner; wherein the first configuration file includes identifiers of L files, the target parameters of the L files meet the first condition, the L files include the target file, L is a positive integer, and the first configuration file is fixed. By presetting the first configuration file in the electronic device, and determining whether to use the first pointer offset manner or the second pointer offset manner to read the target file based on the first configuration file when reading the file, it is more in line with the use requirements of the file, thereby improving the efficiency of reading the file and enhancing the user experience.
[0008] In combination with the first aspect, in some implementations of the first aspect, a second configuration file is configured in the electronic device, and when the target parameter of the target file meets the first condition, the target file is read in the first pointer offset mode, including: when the second configuration file includes the identifier of the target file, the target file is read in the first pointer offset mode; wherein the second configuration file includes the identifiers of M files, the target parameters of each of the M files meet the first condition, the M files include the target file, M is a positive integer, and the second configuration file is updated by the electronic device at a preset time. By presetting the second configuration file in the electronic device, and determining to use the first pointer offset mode or the second pointer offset mode to read the target file based on the second configuration file when reading the file, or by selecting a method based on the combination of the first configuration file and the second configuration file to determine to use the first pointer offset mode or the second pointer offset mode to read the target file, it is more in line with user needs, thereby improving the efficiency of reading files and enhancing user experience.
[0009] In combination with the first aspect, in certain implementations of the first aspect, before the electronic device updates the second configuration file, it also includes: counting the target parameters of each of N files, where N is a positive integer. The electronic device updates the second configuration file, including: when the target parameters of P files meet the first condition, the electronic device updates the second configuration file, wherein P is a positive integer, the N files include P files, the second configuration file includes the identifiers of the P files, and the P files are different from the M files. Before the electronic device updates the second configuration file, the target parameters of each of the N files are counted, and when P files among the N files meet the first condition, the second configuration file is updated according to the identifiers of the P files, so that the second configuration file can dynamically adjust the pointer offset method based on the actual usage of the user, which has higher flexibility and improves the user experience.
[0010] In combination with the first aspect, in certain implementations of the first aspect, before the target file is read using the first pointer offset method, it also includes: counting the target parameters of one or more files, the one or more files including the target file; and ranking the one or more files based on the target parameters. When the target parameter of the target file meets the first condition, the target file is read using the first pointer offset method, including: when the target file is within a preset ranking range, the target file is read using the first pointer offset method. The method provided in the embodiment of the present application can select files ranked within a preset range to use the first pointer offset method when the memory space of the electronic device is insufficient, thereby reducing the situation where the file reading fails due to excessive memory usage when reading the file, and improving the stability of the file system.
[0011] In combination with the first aspect, in certain implementations of the first aspect, ranking one or more files based on the target parameters includes: summing the calculation results of each parameter in the target parameters and sorting them to obtain one or more file rankings; wherein the calculation results of each parameter include one or more of the following: the product of the size of the file and the first weight, the product of the pointer offset of the file and the second weight, the product of the offset frequency of the file and the third weight, and the product of the use frequency of the file and the fourth weight. By summing the target parameters of the file and their respective corresponding weights, comprehensively considering multiple parameters such as file size, pointer offset, offset frequency and use frequency, and based on the respective corresponding weights, selecting one or more target files that are more suitable for the first pointer offset method, the stability of the file system of the electronic device is improved.
[0012] In conjunction with the first aspect, in some implementations of the first aspect, the first pointer offset mode includes a fast seek mode, and the second pointer offset mode includes a normal seek mode. In the embodiment of the present application, for a target file, selecting a pointer offset mode that is more suitable for the target file between the fastseek mode and the normal seek mode can significantly improve the efficiency of the file system in reading files and improve the user experience.
[0013] In a second aspect, an embodiment of the present application provides a file reading device, which may be an electronic device, or a chip or chip system in an electronic device. The file reading device may include a processing unit. The processing unit may be a processor. The device may also include a storage unit, which may be a memory. The storage unit is used to store instructions, and the processing unit executes the instructions stored in the storage unit so that the electronic device implements a file reading method described in the first aspect or any possible implementation of the first aspect. When the device is a chip or chip system in an electronic device, the processing unit may be a processor. The processing unit executes the instructions stored in the storage unit so that the electronic device implements a file reading method described in the first aspect or any possible implementation of the first aspect. The storage unit may be a storage unit in the chip (for example, a register, a cache, etc.), or a storage unit in the electronic device located outside the chip (for example, a read-only memory, a random access memory, etc.).
[0014] In a third aspect, an embodiment of the present application provides an electronic device, including a processor and a memory, the memory being used to store code instructions, and the processor being used to run the code instructions to execute the method described in the first aspect or any possible implementation of the first aspect.
[0015] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, in which a computer program or instructions are stored. When the computer program or instructions are run on a computer, the computer executes the method described in the first aspect or any possible implementation of the first aspect.
[0016] In a fifth aspect, an embodiment of the present application provides a computer program product including a computer program. When the computer program runs on a computer, the computer executes the method described in the first aspect or any possible implementation manner of the first aspect.
[0017] In a sixth aspect, the present application provides a chip or a chip system, the chip or chip system comprising at least one processor and a communication interface, the communication interface and the at least one processor are interconnected by a line, and the at least one processor is used to run a computer program or instruction to execute the method described in the first aspect or any possible implementation of the first aspect. The communication interface in the chip can be an input / output interface, a pin or a circuit, etc.
[0018] In a possible implementation, the chip or chip system described above in the present application further includes at least one memory, in which instructions are stored. The memory may be a storage unit inside the chip, such as a register, a cache, etc., or a storage unit of the chip (e.g., a read-only memory, a random access memory, etc.).
[0019] It should be understood that the second to sixth aspects of the present application correspond to the technical solutions of the first aspect of the present application, and the beneficial effects achieved by each aspect and the corresponding feasible implementation methods are similar and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application;
[0021] Figure 2 A software structure block diagram of an electronic device according to an embodiment of the present application;
[0022] Figure 3 A schematic diagram of a cluster chain provided in an embodiment of the present application;
[0023] Figure 4 A schematic diagram of a file index table provided in an embodiment of the present application;
[0024] Figure 5 A flowchart of a file reading method provided in an embodiment of the present application;
[0025] Figure 6 A schematic diagram of a method for updating a file operation table provided in an embodiment of the present application;
[0026] Figure 7 A flowchart of another file reading method provided in an embodiment of the present application;
[0027] Figure 8 A schematic diagram of the structure of a chip provided in an embodiment of the present application. DETAILED DESCRIPTION
[0028] In order to clearly describe the technical solutions of the embodiments of the present application, some terms and technologies involved in the embodiments of the present application are briefly introduced below:
[0029] 1. File pointer: A pointer used to indicate the current file operation location. For example, when a file is opened using a file system, the file system creates a file pointer, which can be used to indicate the current location of reading or writing the file.
[0030] 2. File pointer offset: used to indicate the operation of moving the file pointer from the current position to another position in the file. For example, in the file system, the file pointer offset can be implemented by a normal seek mode or a fast seek mode.
[0031] It should be understood that for a larger file, such as a font file or a UI resource file, the file may be divided into multiple clusters when stored, each cluster storing a portion of the data of the file. In a possible scenario, multiple clusters of a file may be distributed in different locations in the storage space.
[0032] The normal seek method is a cluster-by-cluster traversal offset method. The file system can achieve the offset of the file pointer by cluster-by-cluster traversal.
[0033] The fast seek method is a fast positioning offset method. When an electronic device performs a file opening or file initialization operation, the fast seek method will pre-read and cache the cluster list information of the file, which may include the starting position and length of each cluster chain of the file. When the file pointer needs to be moved, the fast seek method can use the cached cluster list information to quickly locate the cluster at the target position.
[0034] 3. Other terms
[0035] In the embodiments of the present application, words such as "first" and "second" are used to distinguish the same or similar items with substantially the same functions and effects. For example, the first chip and the second chip are only used to distinguish different chips, and their order is not limited. Those skilled in the art can understand that words such as "first" and "second" do not limit the quantity and execution order, and words such as "first" and "second" do not necessarily limit them to be different.
[0036] It should be noted that in the embodiments of the present application, words such as "exemplarily" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplarily" or "for example" in the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplarily" or "for example" is intended to present related concepts in a specific way.
[0037] In the embodiments of the present application, "at least one" refers to one or more, and "more than one" refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b, or c can represent: a, b, c, ab, a--c, bc, or abc, where a, b, c can be single or multiple.
[0038] 4. Electronic equipment
[0039] The electronic devices of the embodiments of the present application may include handheld devices, vehicle-mounted devices, etc. with face recognition functions. For example, some electronic devices are: mobile phones, tablet computers, PDAs, laptop computers, mobile internet devices (MIDs), wearable devices, virtual reality (VR) devices, augmented reality (AR) devices, wireless terminals in industrial control, wireless terminals in self driving, wireless terminals in remote medical surgery, wireless terminals in smart grids, wireless terminals in transportation safety, wireless terminals in smart cities, wireless terminals in smart homes, cellular phones, cordless phones, session initiation protocol (SIP) phones, wireless local loop (WLL) stations, personal digital assistants (PDAs), handheld devices with wireless communication capabilities, computing devices or other processing devices connected to wireless modems, vehicle-mounted devices, wearable devices, terminal devices in 5G networks or future evolved public land mobile communication networks (PLANs), and wireless terminals in smart cities. The embodiments of the present application do not limit this.
[0040] As an example but not limitation, in the embodiments of the present application, the electronic device may also be a wearable device. Wearable devices may also be referred to as wearable smart devices, which are a general term for wearable devices that are intelligently designed and developed using wearable technology for daily wear, such as glasses, gloves, watches, clothing, and shoes. A wearable device is a portable device that is worn directly on the body or integrated into the user's clothes or accessories. Wearable devices are not only hardware devices, but also powerful functions achieved through software support, data interaction, and cloud interaction. Broadly speaking, wearable smart devices include full-featured, large-sized, and fully or partially independent of smartphones, such as smart watches or smart glasses, as well as devices that only focus on a certain type of application function and need to be used in conjunction with other devices such as smartphones, such as various types of smart bracelets and smart jewelry for vital sign monitoring.
[0041] In addition, in the embodiments of the present application, the electronic device can also be a terminal device in the Internet of Things (IoT) system. IoT is an important part of the future development of information technology. Its main technical feature is to connect objects to the network through communication technology, thereby realizing an intelligent network that interconnects people and machines and things.
[0042] The electronic devices in the embodiments of the present application may also be referred to as: terminal equipment, user equipment (UE), mobile station (MS), mobile terminal (MT), access terminal, user unit, user station, mobile station, mobile station, remote station, remote terminal, mobile device, user terminal, terminal, wireless communication equipment, user agent or user device, etc.
[0043] In an embodiment of the present application, the electronic device or each network device includes a hardware layer, an operating system layer running on the hardware layer, and an application layer running on the operating system layer. The hardware layer includes hardware such as a central processing unit (CPU), a memory management unit (MMU), and a memory (also called main memory). The operating system can be any one or more computer operating systems that implement business processing through processes, such as Linux operating system, Unix operating system, Android operating system, iOS operating system, or Windows operating system. The application layer includes applications such as browsers, address books, word processing software, and instant messaging software.
[0044] The file system of an electronic device can be used to store, manage and read various files, such as font files, UI resource files, configuration files, log files, etc. A font file may include a collection of multiple strings. A UI resource file may include various materials and resources required for the electronic device interface display, such as icons, pictures, colors, fonts, etc. When reading a file, the file system can use the normal seek method or the fast seek method to offset the file pointer.
[0045] It is understandable that when the file system uses the normal seek method to read files, the time to open and initialize the file is shorter and the memory usage is smaller. However, if the normal seek method is used to offset the file pointer of a larger file, since multiple clusters in the file are distributed in different locations in the storage space, the file system needs to traverse multiple clusters distributed in different locations, and the normal seek method traverses cluster by cluster, resulting in a larger file pointer offset, which may take a longer time to read the file, slow down the file reading, and reduce the reading efficiency of the file system.
[0046] When the file system uses the fast seek method to read files, the reading speed is faster. However, since the electronic device will pre-read and cache the cluster list information of the file when opening or initializing the file using the fast seek method, the time for opening and initializing the file is longer and the memory is larger. If the frequency of file reading is high, the file needs to be opened or closed frequently, and each time the file is read, the cluster list information of the file needs to be cached, which may cause the file to be read more slowly in this case, and the memory resources of the electronic device are too high, reducing the reading efficiency of the file system.
[0047] In order to solve the above technical problems, the embodiment of the present application provides a file reading method, which determines the file pointer offset mode used when reading the file by judging the file size, file pointer offset size, file pointer offset frequency and / or the single opening time of the file to be read. In this way, the file system selects the appropriate file reading mode according to the actual situation of each file, which can reduce the memory usage of the electronic device, and can read the file content faster, improve the efficiency of reading files, and thus improve the user experience.
[0048] Figure 1 Schematic diagram of the structure of the electronic device 100 provided in the embodiment of the present application. Figure 1As shown, the electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.
[0049] It is to be understood that the structure illustrated in the embodiment of the present application does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown in the figure, or combine some components, or split some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.
[0050] The processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (AP) and a coprocessor (CP). The application processor includes an application framework layer, a hardware abstraction layer, a kernel layer, etc. of the software architecture adopted by the electronic device 100; the coprocessor includes a sensor hub, etc. Among them, different processing units may be independent devices or integrated in one or more processors.
[0051] The internal memory 121 can be used to store computer executable program codes, which include instructions. The internal memory 121 may include a program storage area and a data storage area. Among them, the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc. The data storage area may store data created during the use of the electronic device 100 (such as audio data, a phone book, etc.), etc. In addition, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc. The processor 110 executes various functional applications and data processing of the electronic device 100 by running instructions stored in the internal memory 121, and / or instructions stored in a memory provided in the processor.
[0052] It is understandable that if the electronic device uses the fast seek method to perform file pointer offset, the processor 110 will pre-cache the cluster link list information stored in the internal memory 121 when reading the file during the file opening or file initialization stage. Further, based on the cached cluster link list information, the processor 110 can quickly offset the file pointer to the cluster containing the target location when the file pointer is offset.
[0053] A memory may also be provided in the processor 110 for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may be used to store cluster linked list information.
[0054] It should be understood that Figure 1 The connection relationship between the modules shown is only a schematic illustration and does not constitute a limitation on the connection relationship between the modules of the electronic device 100. Optionally, the modules of the electronic device 100 may also adopt a combination of multiple connection modes in the above embodiments.
[0055] Figure 2 FIG. 1 is a software structure diagram of the electronic device 100 according to an embodiment of the present application. Figure 2 As shown, the layered architecture divides the software into several layers, each with clear roles and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom, namely, the application layer, the application framework layer, the Android runtime (Android runtime) and the system library, and the kernel layer.
[0056] The application layer can include a series of application packages. Figure 2As shown, the application package may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message, etc.
[0057] The application framework layer provides application programming interface (API) and programming framework for the applications in the application layer. The application framework layer includes some predefined functions. Figure 2 As shown, the application framework layer may include a window manager, a resource manager, a notification manager, a content provider, a file system, and the like.
[0058] The file system provides the electronic device 100 with interfaces for basic file operations, for example, including an open file interface, a close file interface, a read and write file interface, and a delete file interface.
[0059] Optionally, the file system may further include a cluster linked list interface, and the cluster linked list interface may be used to obtain cluster linked list information of the file from the storage space.
[0060] Android runtime includes core libraries and virtual machines. Android runtime is responsible for the control and management of the Android system.
[0061] The core library consists of two parts: one part is the function that needs to be called by the Java language, and the other part is the Android core library.
[0062] The application layer and the framework layer run in a virtual machine. The virtual machine executes the java files of the application layer and the framework layer as binary files. The virtual machine is used to perform functions such as object life cycle management, stack management, thread management, security and exception management, and garbage collection. For example, in an embodiment of the present application, the virtual machine can determine the offset mode used by the file based on indicators such as file pointer offset frequency, file open cycle or file size.
[0063] The system library can also be called the Native layer, which can include multiple functional modules, such as media libraries, function libraries, and graphics processing libraries (such as OpenGL ES).
[0064] HAL is an abstract structure between the kernel layer and Android runtime. The hardware abstraction layer can be a package of hardware drivers, providing a unified interface for upper-layer applications to call.
[0065] The kernel layer is the layer between hardware and software. The kernel layer may include display driver, camera driver, audio driver, battery driver, Bluetooth driver, CPU driver, USB driver, etc.
[0066] It should be noted that the embodiments of the present application are only illustrated by using the Android system as an example. In other operating systems (such as Windows system, real-time operating system (RTOS), IOS system, etc.), as long as the functions implemented by each functional module are similar to those in the embodiments of the present application, the solutions of the present application can also be implemented.
[0067] The following specific embodiments are used to describe the method of the present application in detail. The following embodiments may be combined with each other or implemented independently, and the same or similar concepts or processes may not be described in detail in some embodiments.
[0068] In combination with the above embodiments, it can be understood that in the process of operating files using electronic devices, the file pointer offset methods applicable to different files may also be different due to factors such as file size and file usage frequency. Based on this, before introducing the specific method of this application, the scenarios applicable to the normal seek method and the fast seek method for file pointer offset are first analyzed. The specific process is as follows.
[0069] It should be understood that when a file system stores or manages files, in order to save storage space, a file may be stored in multiple clusters of the storage space in a fragmented manner, each cluster stores a portion of the file's data, and the partial data stored in multiple clusters constitute the complete data of a file. Therefore, when the file system reads a file, it needs to read the file based on the link relationship between the multiple clusters of the corresponding file. In the file system, the link relationship between multiple clusters of a file can also be called a cluster chain.
[0070] For example, Figure 3 A schematic diagram of a cluster chain provided in an embodiment of the present application. Figure 3 As shown, if the cluster chain of file A is cluster chain A, the cluster chain A is 1, 2, 3, 4, 45, 46. It can be understood that the data in the file are fragmented and stored in clusters with cluster numbers 1, 2, 3, 4, 45, 46 in the order of the file. It should be understood that Figure 3 The pointer in points to the location where the processor 110 currently reads the file.
[0071] If the normal seek method is used to read file A, the pointer is offset backwards in sequence according to the order of clusters in cluster chain A from front to back during the reading of file A by processor 110, and during the offset process, processor 110 continuously performs input / output operations with the storage space. For example, if the target position of the pointer offset is the cluster with cluster number 45, then the pointer needs to start from the starting cluster, that is, the cluster with cluster number 1, and traverse the clusters with cluster numbers 1, 2, 3, 4, and 45 in sequence until it offsets to the target position.
[0072] It is understandable that when the file system uses the normal seek method to read a file, if the file is small, the data of each part of the file is distributed in a small number of clusters, and it will not take a lot of time to traverse the clusters in sequence until the cluster at the target location is found. However, if the file is large, the data of each part of the file is distributed in a large number of clusters, and the multiple clusters are distributed in various locations of the storage space in a relatively scattered manner, because the processor 110 and the storage space need to perform multiple input / output operations during the file pointer offset process, it will take a lot of time to traverse the clusters in sequence until the cluster at the target location is found.
[0073] If the fast seek method is used to read file A, the processor 110 will cache the cluster list information of file A in advance, and then obtain the cluster where the target position of the file pointer offset is located based on the cluster list information, so as to realize fast positioning of the file pointer.
[0074] Optionally, in a file system, the cluster link list information of a file may be stored in a file index table. Figure 4 Schematic diagram of the file index table provided in the embodiment of the present application. It can be understood that the file index table corresponding to cluster chain A is as follows Figure 4 The file index table in is shown.
[0075] The cluster number in the file index table is used to indicate the starting cluster number in a segment of continuous cluster numbers, and the length is used to indicate the number of consecutive cluster numbers in a segment of continuous cluster numbers. For example, for cluster chain A, its continuous cluster numbers are 1, 2, 3, 4, 45, 46.
[0076] It can be understood that for the continuous cluster numbers 1, 2, 3, 4, the starting cluster number is 1, and the number of continuous clusters is 4, then the corresponding file index table stores 1 and 4. Similarly, for the continuous cluster numbers 45, 46, the starting cluster number is 45, and the number of continuous clusters is 2, then 45 and 2 are stored in the file index table.
[0077] Combination Figure 4Taking the processor 110 reading file A as an example, if the fast seek method is used to offset the file pointer, when the processor 110 receives the instruction to read file A, it will obtain the file index table based on the cluster list information of file A in advance, and store the file index table in the cache of the processor 110. If the file pointer is offset during the reading process, the processor 110 can obtain the cluster where the target position is located based on the file index table in the cache.
[0078] It is understandable that when the file system uses the fast seek method to read files, the processor 110 needs to store the cluster list information of the file in the cache in advance, so the time of the file opening and initialization phase will be longer. In addition, since the cluster list information needs to be cached, more memory of the processor 110 will be occupied.
[0079] Based on the above analysis process, by comparing the normal seek mode and the fast seek mode, we can get the following analysis results.
[0080] Since the normal seek method does not need to cache the cluster list information, the time for opening and initializing the file is short, and the memory usage is small, so it is suitable for files with a large number of switches. However, when reading a large file, the multiple clusters of the file are relatively scattered in various locations of the storage space. In the process of traversing the clusters, the frequent input / output operations between the processor 110 and the storage space will consume a lot of time in the process of file pointer offset.
[0081] The fast seek method needs to cache the cluster list information, so it takes a long time to open and initialize the file, and it needs to occupy the memory space of the processor 110, so it is not suitable for files with a large number of switching times. However, since the cluster where the target position is located can be quickly located when the pointer is offset, frequent input / output operations are not required during the file pointer offset process, so it takes less time to read larger files or files with a large number of offsets.
[0082] On the other hand, the fast seek method can pre-cache the cluster list information during the file opening and initialization stage, and can be used all the time while the file is open. Therefore, the fast seek method can also be applied to files that are opened for a long time.
[0083] Therefore, it can be understood that the normal seek method is suitable for reading files with small size, files with high file opening and closing times, or files with low offset times, while the fast seek method is suitable for reading files with large size, files with long-term opening, or files with high offset times.
[0084] Based on the above analysis process, it can be understood that factors affecting the selection of the file pointer offset method include: file size, file pointer offset difference, file pointer offset frequency and / or single file opening duration.
[0085] The file size refers to the total number of bytes in the file. The larger the file, the more clusters its data may be distributed in, resulting in the need to traverse more clusters for the file pointer offset operation. For smaller files, fewer clusters are traversed, and the normal seek method can be used to offset the file pointer. For larger files, more clusters are traversed, and the fast seek method can significantly reduce the time for pointer offset.
[0086] For example, for a small file such as a 10KB log file, its data may be distributed in only a small number of clusters. The normal seek method can quickly complete the pointer offset, but if the fast seek method is used, it will consume time during the file opening and initialization phases, and its efficiency in reading files may not be as good as using the normal seek method. For a large file such as a 2GB video file, its data is distributed in a large number of clusters. The fast seek method can quickly locate the target location and reduce the pointer offset time.
[0087] The file pointer offset difference refers to the distance the file pointer moves from the current position to the target position, which can be expressed as the number of bytes in the offset process. For a smaller offset difference, fewer clusters are traversed, and the normal seek method can be used to offset the file pointer. For a larger offset difference, more clusters are traversed, and the fast seek method can significantly reduce the time for pointer offset.
[0088] For example, a file with a smaller offset difference is a text file. When the offset is from the beginning of the file to the position of a paragraph, the offset difference is, for example, 2KB. It can be understood that the offset difference of reading the text file is small, and the normalseek method can be used to quickly complete the pointer offset. A file with a larger offset difference is a video file. When the offset is from the beginning of the file to the middle of the video, the offset difference can be, for example, 1GB. It can be understood that the offset difference of reading the video file is large. The fast seek method can be used to quickly locate the target position and reduce the pointer offset time.
[0089] The file pointer offset frequency refers to the frequency at which the file pointer moves in the file, which can also be understood as the number of file pointer offset operations per unit time. For files with a low offset frequency, there are fewer pointer offset operations, and the normal seek method can be used to offset the file pointer. For files with a high offset frequency, there are more pointer offset operations, and the fast seek method can be used to reduce the time for each offset and improve the efficiency of reading files.
[0090] For example, a file with a low offset frequency may be a configuration file of an application, which is read once when the application is started. The offset frequency is low, so the normal seek method can be used. An electronic device reads a file with a high offset frequency, such as a video editing application reading video software. During the video editing process, pointer offset operations may be frequently performed. Using the fast seek method can significantly improve the file reading efficiency.
[0091] The single file opening time can be used to indicate whether the file remains open for a long time during the operation of the electronic device. For files that have been open for a long time, the fast seek method can cache the cluster list information during the file opening and initialization phases, and the cluster list information in the cache can be used all the time during the file opening, reducing the time of pointer offset. For example, if a database file remains open for a long time during the system operation, the use of the fast seek method can significantly reduce the time of pointer offset and improve the efficiency of reading files.
[0092] In the embodiment of the present application, a configuration file may be pre-set in the electronic device, and the configuration file may include a file identifier of the file and a file pointer offset mode applicable thereto. When reading a file, the file system of the electronic device may determine the file pointer offset mode based on the configuration file. The file identifier is a mark or information used to uniquely identify a file, and optionally, the file identifier may be a file name, etc.
[0093] In some scenarios, the configuration file may also be referred to as a whitelist. Optionally, the whitelist may be a fast seek whitelist, or the whitelist may be a normal seek whitelist. It should be understood that if the whitelist is a fast seek whitelist, the fast seek whitelist may include a set of predefined file identifiers, and the files corresponding to these file identifiers are determined to use the fast seek method for file pointer offset.
[0094] Correspondingly, if the whitelist is a normal seek whitelist, the normal seek whitelist may also include a group of predefined file identifiers, and the files corresponding to these file identifiers are determined to use the normal seek method for file pointer offset.
[0095] In a possible implementation, a first configuration file may be pre-installed in the electronic device.
[0096] Optionally, the first configuration file can be a file pointer offset mode applicable to each file determined by the developer through analysis and evaluation according to the usage of each file, wherein the usage of the file can be, for example, the frequency of user reading the file, the opening time, etc.
[0097] It should be understood that the electronic device may include files in various applications, such as social applications, text editing applications, video applications, etc. Different types of applications may have different usage situations when using files. For example, some files will be read frequently, while some files will be opened for a long time at a time. For example, taking desktop applications as an example, there may be UI resource files such as icons or pictures that occupy a large amount of memory in desktop applications. When users frequently switch to the desktop, the UI resource files of the desktop application will be read repeatedly, which can also be understood as the file pointer offset frequency of the UI resource file is high.
[0098] Therefore, based on the file size and the usage of the file, the file pointer offset mode applicable to the files of different applications can be set. For example, a large UI resource file with a high file pointer offset frequency is determined to use the fast seek mode for file pointer offset.
[0099] Optionally, the first configuration file can also be used by the electronic device or the cloud server to collect statistics on file usage information to determine the file pointer offset mode applicable to each file. The file usage information may include the file size, file pointer offset frequency, file pointer offset difference and / or the single opening time of the file.
[0100] Exemplarily, after the electronic device or cloud server obtains the file identifier and the corresponding file size, file pointer offset frequency, file pointer offset difference and / or file single opening duration and other data, if the file size, file pointer offset frequency, file pointer offset difference and / or file single opening duration corresponding to the file exceed their respective corresponding thresholds, it can be determined that the file is suitable for fast seek method to perform file pointer offset.
[0101] Optionally, the above two implementation methods can be used in combination. It should be understood that when the two methods are used to determine the file pointer offset mode, if the file pointer offset modes determined by the two methods are different, the file pointer offset mode determined in the first implementation method can be used preferentially, or the file pointer offset mode determined in the second implementation method can be used preferentially, and the embodiments of the present application do not limit this.
[0102] It is understandable that, since the developers of each application may be more familiar with the usage of each application when using files, giving priority to using the file pointer offset method determined by the first implementation method may be more in line with the developers' expectations, improve the operating efficiency of the application, and make file reading more reliable.
[0103] It is understandable that since the usage of files in various applications may be different, the file pointer offset method determined based on the usage information of the file in the actual application process of the electronic device can better reflect the usage of the file in the actual application process. Therefore, the file pointer offset method determined by the second implementation method may be more in line with the user's usage of the file and can improve the user experience.
[0104] In another possible implementation, a second configuration file may be pre-set in the electronic device. The second configuration file may be generated based on a file operation table stored locally in the electronic device. The file operation table may store a file identifier of the file and a mapping relationship between the file size, file pointer offset difference, file pointer offset frequency, and / or single file opening duration of the file when the file was last read.
[0105] It should be understood that the file size, file pointer offset difference, file pointer offset frequency and / or single file opening duration in the file operation table stored locally on the electronic device are updated in real time based on the user's actual use of the electronic device, and the second configuration file generated based on the file operation table will also be updated as the file operation table changes.
[0106] Optionally, the second configuration file may be loaded into the electronic device each time the electronic device is turned on, or according to a preset period.
[0107] Optionally, when reading a file, one of the first configuration file and the second configuration file may be used, or the first configuration file and the second configuration file may be used in combination to determine a file pointer offset mode.
[0108] When the first configuration file and the second configuration file are used in combination to determine the file pointer offset method, if there is a conflict in the file pointer offset methods determined by the two configuration files, the file pointer offset method determined by the first configuration file or the file pointer offset method determined by the second configuration file may be selected as the basis, and the embodiments of the present application do not limit this.
[0109] It is understandable that the first configuration file is a file pointer offset method determined by the developer based on a comprehensive analysis and evaluation of file usage of each application, combined with file usage in different electronic devices and / or by different users in actual application processes.
[0110] Therefore, choosing the file pointer offset method determined by the first configuration file may be more in line with the usage requirements of the application, and can reduce the possibility that the file pointer offset method is incorrectly adjusted due to the user's accidental reading of a file that is different from normal usage, thereby ensuring the stability of the file pointer offset method and improving the user experience.
[0111] It is understandable that since the second configuration file is a file pointer offset mode determined by the file size, file pointer offset difference, file pointer offset frequency and / or file single opening duration of the file obtained when the electronic device reads the file during actual operation, therefore, the file pointer offset mode determined by the second configuration file is selected as the standard, and the file pointer offset mode can be updated in real time according to the actual usage of the user, so that the determination of the file pointer offset mode has higher flexibility, which can speed up the file reading efficiency and improve the user experience.
[0112] For ease of understanding, the following is based on the file pointer offset mode confirmed by the first configuration file, combined with the second configuration file, and the first configuration file and the second configuration file are both fast seek whitelists as an example to introduce the file reading method provided by the embodiment of the present application. It should be understood that if the file pointer offset mode confirmed by the second configuration file is used as the standard, or the first configuration file and / or the second configuration file are fast seek whitelists or normal seek whitelists, the implementation method is similar to the method used in this embodiment, and will not be repeated here one by one. The process is described below.
[0113] For example, Figure 5 The following is a flowchart of a file reading method 500 provided in an embodiment of the present application. The method 500 may be executed by a file system of an electronic device, and the method 500 includes the following steps:
[0114] S501: In response to an instruction from an application program to read a target file, a file system initiates a task of reading the target file.
[0115] For example, an application may call Figure 2 Instructs the file system to read the target file.
[0116] The application can be Figure 2 Various applications in the application package in the embodiment. In the process of a user using an electronic device, in response to the user's operation on the electronic device, the application initiates a task of reading a target file based on the user operation. The target file is a file that the application needs to read, and the target file can be stored in the internal memory 121 of the electronic device.
[0117] Optionally, the user's operation on the electronic device may include turning on the device, starting an application, or clicking a file read button.
[0118] For example, the user's operation on the electronic device may be a power-on operation, the application is a desktop application, and the target file is a UI resource file. After the user's power-on operation is triggered, during the power-on process of the electronic device, the desktop application needs to read the UI resource file to draw the user interface, and the desktop application initiates a task of reading the UI resource file during the power-on process, so that the desktop application can load UI resource files such as icons or pictures in the user interface of the electronic device.
[0119] S502: The file system determines whether the file identifier of the target file exists in the first configuration file.
[0120] If the file identifier of the target file exists in the first configuration file, the file system executes S504, that is, determining that the file pointer offset mode of the target file is a fast seek mode.
[0121] If the file identifier of the target file does not exist in the first configuration file, the file system executes S503.
[0122] It can be understood that the first configuration file is a set of pre-set file identifiers, and the files corresponding to these file identifiers are determined to use the fast seek method for file pointer offset during the development stage of the electronic device. It can also be understood that when the application reads the files in the first configuration file, the fast seek method for file pointer offset is faster than the normal seek method.
[0123] Therefore, if the file identifier of the target file that the application needs to read exists in the first configuration file, it can be confirmed that the file pointer offset mode of the target file is the fast seek mode.
[0124] S503: The file system determines whether the file identifier of the target file exists in the second configuration file.
[0125] If the file identifier of the target file exists in the second configuration file, the file system executes S504, that is, determining that the file pointer offset mode of the target file is the fast seek mode.
[0126] If the file identifier of the target file does not exist in the second configuration file, the file system executes S505, that is, determining that the file pointer offset mode of the target file is the normal seek mode.
[0127] It should be understood that the usage of files may change constantly. In order to adapt to the changes in usage, the second configuration file can be updated in time based on the usage information of the files actually read by the electronic device. For example, during the startup of the electronic device, or according to a preset period, the files using the fast seek method can be determined based on the latest file size, file pointer offset difference, file pointer offset frequency and / or file single opening duration stored locally in the electronic device, so that the file system can determine a more appropriate file pointer offset method.
[0128] S504: The file system determines that the file pointer offset mode of the target file is a fast seek mode.
[0129] It should be understood that based on the analysis results of the fast seek method in the above text, when reading a target file that is larger, or has a larger file pointer offset difference, or has a higher file pointer offset frequency, the fast seek method can quickly locate the cluster where the target position is located based on the cached cluster linked list information, saving the time consumed in the file pointer offset process.
[0130] In addition, when reading a target file that has been opened for a long time, the fast seek method can be used to pre-cache the cluster list information during the file opening and initialization stages, and the cluster list information can be used throughout the file opening period. Compared with the normal seek method, it is more appropriate to use the fast seek method to read a target file that has been opened for a long time to offset the file pointer.
[0131] S505: The file system determines that the file pointer offset mode of the target file is a normal seek mode.
[0132] Correspondingly, based on the above analysis of the normal seek method, it can be seen that when reading a target file with a small file size, a small number of file offsets, or a small file offset difference, using the normal seek method to offset the file pointer will not consume a lot of time. Therefore, the fast seek method can be omitted to reduce the time consumed in the file opening or initialization stage when reading the target file.
[0133] In addition, when reading files with a large number of switching times, it is more appropriate to use the normal seek method for file pointer offset because the normal seek method does not need to cache cluster list information during the file opening or initialization stage.
[0134] S506: The file system reads the target file and obtains usage information of the target file.
[0135] That is, the file system reads the target file based on the determined file pointer offset method, and obtains the file size, file pointer offset difference, file pointer offset frequency and / or single file opening duration of the target file during the file reading process.
[0136] Exemplarily, if the determined file pointer offset mode is the normal seek mode, the file system may sequentially call the open file interface, the read-write file interface, and the close file interface to operate the target file, so as to complete the task of the application program reading the target file.
[0137] Alternatively, if the determined file pointer offset mode is the fast seek mode, the file system can sequentially call the open file interface, cluster linked list interface, read and write file interface, and close file interface to operate the target file to complete the task of the application reading the target file.
[0138] It should be understood that in order to update the second configuration file, the file system can obtain the latest file size, file pointer offset difference, file pointer offset frequency and / or file single open duration of the target file. Therefore, after the file system reads the target file based on the determined file pointer offset method, it can obtain the usage information such as the file size, file pointer offset difference, file pointer offset frequency and / or file single open duration of the currently read target file, so as to subsequently update the second configuration file.
[0139] Optionally, the file system may create a timer that continuously triggers interrupts to obtain the file size, file pointer offset difference, file pointer offset frequency, and / or single file opening duration of the target file. The specific process is as follows.
[0140] S1. Initialize a timer object in the file system and set the timer trigger interval, for example, once per second.
[0141] S2. When the timer triggers an interrupt, the interrupt function may be called to obtain the file size, file pointer offset difference, file pointer offset frequency, and / or single file opening duration of the target file.
[0142] Optionally, the interrupt function for obtaining the file size can obtain the file size of the target file by calling the file opening interface of the file system. It should be noted that the file size can be obtained once when the file is opened.
[0143] Optionally, the interrupt function for obtaining the file pointer offset difference can record the current file pointer position before each file pointer movement, record the file pointer position after the file pointer movement, and then calculate the byte difference between the current position and the target position, which is the file pointer offset difference.
[0144] Optionally, the interrupt function for obtaining the file pointer offset frequency can obtain the file pointer offset frequency by calculating the number of operations for obtaining the file pointer offset within a certain time window. The number of file pointer offset operations can be obtained by a counter, and the value of the counter increases by one each time the file pointer is offset.
[0145] Optionally, the interrupt function for obtaining the single opening duration of a file can record an opening timestamp when the file is opened, and a closing timestamp when the file is closed. The single opening duration of the file is obtained by calculating the difference between the closing timestamp and the opening timestamp of the file.
[0146] It can be understood that S501 to S505 are used to determine the file pointer offset mode of the target file being read this time, and S506 to S509 are used to update the file operation table in the local storage, so that when the second configuration file is loaded next time, the file size, file pointer offset difference, file pointer offset frequency and / or single file opening duration in the second configuration file are the usage information of the target file read most recently.
[0147] Therefore, in this embodiment, S501 to S505 can be executed separately to determine the file pointer offset mode of the target file without relying on the execution of S506 to S509; or S501 to S505 can be used in combination with S506 to S509 to more comprehensively confirm the file pointer offset mode of the target file.
[0148] If S501 to S505 and S506 to S509 are used in combination, S501 to S505 and S506 to S509 can be executed sequentially or in parallel, that is, the execution process of S501 to S505 and the execution process of S506 to S509 do not distinguish the order of execution, thereby improving the efficiency and accuracy of determining the file pointer offset method.
[0149] S507: After the target file is read, the file system determines whether to add the file identifier of the target file to the second configuration file.
[0150] If the file size of the target file is greater than or equal to threshold A, the file pointer offset difference is greater than or equal to threshold B, the file pointer offset frequency is greater than or equal to threshold C, and the single opening duration of the file is greater than or equal to threshold D, the file system executes S508, that is, the file system adds the file identifier of the target file to the second configuration file.
[0151] If the file size of the target file is less than threshold A, the file pointer offset difference is less than threshold B, the file pointer offset frequency is less than threshold C, or the single file opening duration is less than threshold D, the file system executes S509.
[0152] Among them, threshold A, threshold B, threshold C and threshold D can be preset values. For example, threshold A can be 30MB, threshold B can be 5MB, threshold C can be 10,000 times / day, and threshold D can be 30 minutes / time. The specific values of threshold A, threshold B, threshold C and threshold D can be set according to actual conditions, and the embodiments of the present application are not limited.
[0153] It can be understood that if the file size of the target file is greater than or equal to threshold A, the file pointer offset difference is greater than or equal to threshold B, the file pointer offset frequency is greater than or equal to threshold C, and the single opening time of the file is greater than or equal to threshold D, then the target file is suitable for using the fast seek method for file pointer offset, and the file identifier of the target file is added to the second configuration file so that when the target file is read next time, it can be quickly determined that the file pointer offset method of the target file is the fast seek method.
[0154] It should be understood that if the file identifier of the target file exists in the original second configuration file, the file identifier of the target file may not be added to the second configuration file to prevent the file identifier of the target file from being repeated in the second configuration file.
[0155] In another implementation, when determining whether to add the file identifier of the target file to the second configuration file, the judgment may also be made based on the ratio of the actual offset of the file pointer to the required offset during the file pointer offset process.
[0156] For example, if the task of reading a file is initiated by a video player to read a video, the cluster chain corresponding to the video is Figure 3 Cluster chain A in the cluster chain. During video playback, the user may rewind the video. In this case, the file pointer may need to be offset from a later position in the cluster chain to an earlier position in the cluster chain.
[0157] For example, the file pointer needs to be offset from cluster number 4 to cluster number 3. However, since the normal seek method is cluster-by-cluster traversal when performing file pointer offset, that is, the file pointer can only be offset in the order of the cluster chain from front to back, it can be understood that if the normal seek method is used to offset the file pointer, the actual file pointer offset process is offset from cluster numbers 4, 45, 46, 1, 2, and 3 in sequence.
[0158] It is understandable that when the normal seek method is used to shift the file pointer, the actual offset of the file pointer and / or the required offset of the file pointer differ greatly. For such files, the fast seek method can be used to shift the file pointer. That is, when the normal seek method is used to shift the file pointer, the ratio of the actual offset of the file pointer to the required offset can be recorded during the file pointer shift process. If the ratio of the actual offset to the required offset is greater than or equal to the threshold value E, the identifier of the file is added to the second configuration file.
[0159] The threshold E is a preset value. Exemplarily, the threshold E may be that the ratio of the actual offset of the file pointer to the required offset is 100:1. For example, if the ratio of the actual offset to the required offset of the file pointer is 101:1 during the offset process, the identifier of the file is added to the second configuration file.
[0160] It can be understood that in actual operation, the file pointer offset method can be determined based on a combination of one or more data including file size, file pointer offset difference, file pointer offset frequency, single file opening duration and / or the ratio of actual offset to required offset.
[0161] S508: The file system adds the file identifier of the target file to the second configuration file.
[0162] S509: The file system updates the file operation table.
[0163] The file operation table stores a mapping relationship among file identifier, file size, file pointer offset difference, file pointer offset frequency and / or single file opening duration.
[0164] As mentioned above, the second configuration file can be generated and loaded into the file system based on the locally stored file operation table during the startup process of the electronic device or according to a preset period. It can be understood that in order to realize that the file pointer offset mode stored in the second configuration file loaded each time is determined based on the latest file size, file pointer offset difference, file pointer offset frequency and / or file single opening duration, the file operation table stored in the local storage space needs to be updated with the user's usage.
[0165] Therefore, after the target file is read, the file system can update the file operation table based on the file size, file pointer offset difference, file pointer offset frequency and / or single file opening duration of the target file read this time.
[0166] Optionally, in order to reduce the input / output operations between the file system and the local storage during the process of updating the file operation table, and to reduce the reduction in the operating efficiency of the file system due to frequent input / output operations, the file size, file pointer offset difference, file pointer offset frequency and / or the single opening duration of the target file being read can be written into the cache first, and when the electronic device is idle, or according to a preset period, the locally stored file operation table can be updated based on the file identifier in the cache and the file size, file pointer offset difference, file pointer offset frequency and / or the single opening duration of the file.
[0167] For ease of understanding, the process of updating the file operation table is introduced below.
[0168] like Figure 6 As shown, when the system of the electronic device is running, the file system can determine whether the file size, file pointer offset difference, file pointer offset frequency and / or single file opening time of the file exceed their respective corresponding thresholds, and the file pointer offset mode currently used is the normal seek mode.
[0169] If the file size, file pointer offset difference, file pointer offset frequency and / or single file open duration of the file exceed their respective thresholds, it can be understood that the file is suitable for the fast seek method, but the file pointer offset method currently used is the normal seek method. It can be understood that the data in the file operation table corresponding to the file needs to be updated so that the fast seek method can be used the next time the file is read.
[0170] If it is determined that the data in the file operation table corresponding to the file needs to be updated, the mapping relationship between the file identification, file size, file pointer offset difference, file pointer offset frequency and / or file single opening time of the file is stored in the file operation intermediate table in the cache, and when the electronic device is idle, the file operation table in the local storage is updated based on the mapping relationship between the file identification, file size, file pointer offset difference, file pointer offset frequency and / or file single opening time of the file in the file operation intermediate table.
[0171] Optionally, whether the electronic device is idle may be determined based on indicators such as the usage rate of the processor and / or the memory usage rate of the electronic device, which is not limited here.
[0172] In some embodiments, there may be a situation where the memory space of the electronic device is insufficient. In this case, some files may be selected to use the fast seek method. Exemplarily, for files whose file identifiers are in the second configuration file, the file system may combine the weights corresponding to the file size, the file pointer offset difference, the file pointer offset frequency, and / or the single opening duration of the file to obtain the target file that most needs to use the fast seek method.
[0173] Optionally, for multiple files that conform to the second configuration file, the file system obtains the file size, file pointer offset difference, file pointer offset frequency and / or single file opening duration of each file in the file operation table, and their respective corresponding weights, to obtain a fast seek score for each file.
[0174] Exemplarily, the weights corresponding to the file size, the file pointer offset difference, the file pointer offset frequency and / or the single file opening duration can be preset values. For example, the weight of the file size is 40%, the weight of the file pointer offset difference is 20%, the weight of the file pointer offset frequency is 20%, and the weight of the single file opening duration is 20%. The specific weight values can be set by the electronic device according to actual conditions, and the embodiments of the present application are not limited thereto.
[0175] Furthermore, the file system sorts the fast seek scores of all files from large to small based on the fast seek score of each file, determines that the file pointer offset mode of the file corresponding to the fast seek score ranked in the front preset position is the fast seek mode, and updates the second configuration file.
[0176] Figure 7 The file reading method of the embodiment of the present application is shown. The method includes:
[0177] S701: When a target parameter of a target file satisfies a first condition, read the target file by adopting a first pointer offset method.
[0178] S702: When the target parameter of the target file does not satisfy the first condition, read the target file using a second pointer offset method.
[0179] Among them, compared with the second pointer offset method, the first pointer offset method has the following characteristics: a long time to open the file, a large amount of memory is occupied, and the reading speed is fast. The target parameters include one or more of the following: the size of the target file, the pointer offset of the target file, the offset frequency of the target file, and the usage frequency of the target file.
[0180] In the embodiment of the present application, the target file can be any file in the electronic device, or, the target file can be described in the above text, which will not be repeated here. Exemplarily, the target file can be a font file, a UI resource file, a configuration file, a log file, etc.
[0181] The target parameter is used to indicate the usage information of the file system when reading the target file. Among them, the size of the target file can be used to indicate the total number of bytes of the target file; the pointer offset of the target file can be used to indicate the distance that the file pointer moves from the current position to the target position when reading the target file. Please refer to the description of the file pointer offset difference above.
[0182] The target file offset frequency can be used to indicate the frequency of movement of the file pointer in the file when reading the target file. Please refer to the description of the file pointer offset frequency above. The target file usage frequency can be used to indicate the number of times the electronic device opens the target file per unit time when reading the target file. It can also be understood as the single file opening duration mentioned above. The longer the single file opening duration is, the higher the usage frequency is. Please refer to the description of the single file opening duration mentioned above. No further explanation is given here.
[0183] The first pointer offset mode can refer to the fast seek mode mentioned above, and the second pointer offset mode can refer to the normal seek mode mentioned above. It should be noted that in the embodiment of the present application, the first pointer offset mode, such as the fast seek mode, can significantly improve the reading speed when reading a target file that is large, or has been opened for a long time, or has a large number of offsets; the second pointer offset mode, such as the normal seek mode, can read faster when reading a target file that is small, or has a large number of file openings and closings, or has a small number of offsets.
[0184] The first condition can be used to determine whether to use the first pointer offset method to read the target file. For example, Figure 5 The relevant description of step S507 in the corresponding embodiment can also be understood as that the first condition can be whether the file parameters of the target file meet their respective corresponding thresholds. If the target file meets the first condition, the target file can be read by the first pointer offset method. If the first condition is not met, the target file is read by the second pointer offset method.
[0185] In the embodiment of the present application, the file pointer offset mode used when reading the target file is determined by judging one or more of the file size, file pointer offset size, file pointer offset frequency and / or the single file opening duration of the target file. In this way, the file system can select a suitable file reading mode according to the actual situation of each file, which can reduce the memory usage of the electronic device, and can read the file content faster, improve the efficiency of reading files, and thus improve the user experience.
[0186] Optional, in Figure 7Based on the corresponding embodiment, the first condition includes one or more of the following: the size of the target file is greater than or equal to the first threshold, the pointer offset of the target file is greater than or equal to the second threshold, the offset frequency of the target file is greater than or equal to the third threshold, and the usage frequency of the target file is greater than or equal to the fourth threshold.
[0187] The first threshold can be understood as a threshold for determining the size of the target file, or it can be Figure 3 The corresponding embodiment of the threshold A. For example, the first threshold can be 30MB. Correspondingly, the second threshold can be understood as a threshold for determining the pointer offset, or can be Figure 3 The corresponding embodiment of the threshold B. For example, the second threshold can be 5MB. The third threshold can be understood as a threshold for determining the offset frequency of the target file, or can be Figure 3 The corresponding embodiment of the threshold C. For example, the third threshold can be 10000 times / day. The fourth threshold can be understood as a threshold for determining the frequency of use of the target file, or can be Figure 3 The corresponding threshold value D in the embodiment. For example, the first threshold value may be 30 minutes / time.
[0188] In an embodiment of the present application, the first condition can be to determine whether the target file simultaneously satisfies the following conditions: the size of the target file is greater than or equal to a first threshold, the pointer offset of the target file is greater than or equal to a second threshold, the offset frequency of the target file is greater than or equal to a third threshold, and the usage frequency of the target file is greater than or equal to a fourth threshold. Alternatively, the target file may satisfy the following conditions: the size of the target file is greater than or equal to the first threshold, the pointer offset of the target file is greater than or equal to the second threshold, the offset frequency of the target file is greater than or equal to the third threshold, and the usage frequency of the target file is greater than or equal to the fourth threshold, any one or more combinations of which are not limited here.
[0189] In the embodiment of the present application, when the electronic device determines that the target file meets the first condition, it can be understood that it is more appropriate to use the fast seek method when reading the target file, which can improve the efficiency of reading the file and thus enhance the user experience.
[0190] Optional, in Figure 7 On the basis of the corresponding embodiment, a first configuration file is configured in the electronic device, and when the target parameter of the target file meets the first condition, the target file is read by a first pointer offset method, including: when the first configuration file includes an identifier of the target file, the target file is read by the first pointer offset method; wherein the first configuration file includes identifiers of L files, the target parameters of each of the L files meet the first condition, the L files include the target file, L is a positive integer, and the first configuration file is fixedly set.
[0191] The first configuration file may include the identifier of the target file, or the first configuration file may also include the identifier of the target file and the corresponding file pointer offset mode, wherein the file pointer offset mode may be a first pointer offset mode or a second pointer offset mode. The identifier of the target file may be a mark or information used to uniquely identify the target file, for example, the identifier may be a file name or a file path, etc.
[0192] Optionally, the first configuration file may be a file pointer offset mode applicable to each file determined by the developer through analysis and evaluation based on usage of each file, wherein the usage of the file may be, for example, the frequency of user reading the file, the opening time, etc.
[0193] Alternatively, the first configuration file may be a file pointer offset method applicable to each file determined by the electronic device or cloud server based on the usage information of the file, wherein the usage information of the file may include the file size, file pointer offset frequency, file pointer offset difference and / or the single opening time of the file.
[0194] After the first configuration file is determined based on the above two methods, the first configuration file may be pre-set in the electronic device, for example, the first configuration file is stored in a storage space of the electronic device.
[0195] In an embodiment of the present application, by pre-setting a first configuration file in an electronic device, and determining whether to use a first pointer offset method or a second pointer offset method to read a target file based on the first configuration file when reading a file, it is more in line with the usage requirements of the file, thereby improving the efficiency of reading files and enhancing the user experience.
[0196] Optional, in Figure 7 On the basis of the corresponding embodiment, a second configuration file is configured in the electronic device, and when the target parameter of the target file meets the first condition, the target file is read by the first pointer offset method, including: when the second configuration file includes the identifier of the target file, the target file is read by the first pointer offset method; wherein the second configuration file includes the identifiers of M files, the target parameters of each of the M files meet the first condition, the M files include the target file, M is a positive integer, and the second configuration file is updated by the electronic device at a preset time.
[0197] Similar to the first configuration file, the second configuration file may also include the identifier of the target file, or the second configuration file may also include the identifier of the target file and the corresponding file pointer offset method, which is not limited here.
[0198] Optionally, the second configuration file may be updated based on the size of the target file, the pointer offset of the target file, the offset frequency of the target file, and the usage frequency of the target file recorded when the electronic device read the target file for the last time.
[0199] Optionally, the preset timing may be a period for counting the above target parameters, or a preset period, or may be updated when the electronic device is turned on, or updated when the electronic device is idle, which is not limited here.
[0200] Optionally, whether the electronic device is idle may be determined based on indicators such as the usage rate of the processor and / or the memory usage rate of the electronic device.
[0201] It should be understood that due to the different ways of determining the first configuration file and the second configuration file, the identifiers of the L files in the first configuration file and the identifiers of the M files in the second configuration file may be the same or different, and the value of L and the value of M may be the same or different.
[0202] It should be understood that when the first configuration file is not preset in the electronic device, the first pointer offset method or the second pointer offset method can be used to determine whether to read the target file based on the second configuration file. It can be understood that determining whether to read the target file based on the second configuration file using the first pointer offset method or the second pointer offset method may be more in line with the needs of the user, that is, the second configuration file can dynamically adjust the file pointer offset method according to the actual usage of the user, which has higher flexibility, speeds up the file reading efficiency, and improves the user experience.
[0203] Optionally, if the electronic device is configured with a first configuration file and a second configuration file, when reading a file, one of the first configuration file and the second configuration file may be used, or the first configuration file and the second configuration file may be used in combination to determine the file pointer offset mode.
[0204] When the first configuration file and the second configuration file are used in combination to determine the file pointer offset method, if there is a conflict in the file pointer offset methods determined by the two configuration files, the file pointer offset method determined by the first configuration file or the file pointer offset method determined by the second configuration file may be selected as the basis, and the embodiments of the present application do not limit this.
[0205] In an embodiment of the present application, a second configuration file is pre-set in the electronic device, and when reading a file, it is determined based on the second configuration file whether to use the first pointer offset method or the second pointer offset method to read the target file. Alternatively, a method based on a combination of the first configuration file and the second configuration file can be selected to determine whether to use the first pointer offset method or the second pointer offset method to read the target file, which is more in line with user needs, thereby improving the efficiency of reading files and enhancing user experience.
[0206] Optional, in Figure 7 On the basis of the corresponding embodiment, before the electronic device updates the second configuration file, it also includes: counting the target parameters of each of N files, N is a positive integer; the electronic device updates the second configuration file, including: when the target parameters of P files meet the first condition, the electronic device updates the second configuration file, wherein P is a positive integer, the N files include P files, the second configuration file includes identifications of the P files, and the P files are different from the M files.
[0207] It should be understood that the second configuration file is generated based on the latest file size, file pointer offset, file offset frequency and / or file usage frequency. Therefore, before updating the second configuration file, it is also necessary to collect statistics on the target parameters of the files of the electronic device.
[0208] The N files may be any N files in the electronic device. Before updating the second configuration file, the target parameters of the N files may be counted. If it is determined that the target parameters of P files among the N files meet the first condition, it is more appropriate to determine that the P files use the first pointer offset method to perform file pointer offset. Therefore, the identifiers of the M files originally stored in the second configuration file need to be updated to the identifiers storing the P files.
[0209] It is understandable that the usage of files read by the user in the electronic device may change. For example, when the second configuration file was updated last time, the pointer offset of file u was applied in the second pointer offset mode. However, when the target parameter of file u is determined not to meet the first condition during this update, file u does not exist in the identifiers of the P files updated this time. Therefore, it is understandable that the identifiers of the P files and the M files may be the same or different, and the values of P and M may be the same or different.
[0210] In an embodiment of the present application, before the electronic device updates the second configuration file, the target parameters of each of the N files are first counted. When P files among the N files meet the first condition, the second configuration file is updated according to the identifiers of the P files, so that the second configuration file can dynamically adjust the pointer offset method based on the actual usage of the user, which has higher flexibility and improves the user experience.
[0211] Optional, in Figure 7 On the basis of the corresponding embodiment, before reading the target file by the first pointer offset method, it also includes: counting target parameters of one or more files, wherein the one or more files include the target file; and ranking the one or more files based on the target parameters.
[0212] When the target parameter of the target file meets the first condition, the target file is read in a first pointer offset manner, including: when the target file is within a preset ranking range, the target file is read in a first pointer offset manner.
[0213] In an embodiment of the present application, there may be a situation where the memory space of the electronic device is insufficient. In this case, before reading the target file, part of the target file can be selected and the target file can be read using the first pointer offset method to save the memory of the electronic device.
[0214] It can be understood that the ranking position in the above one or more file rankings can be used to indicate the degree of need for the target file to use the first pointer offset method. Optionally, the one or more file rankings can be such that the higher the need, the higher the ranking position; or, the lower the need, the lower the ranking position. This is not limited here.
[0215] Exemplarily, after ranking one or more files, the target files within the preset ranking range may be selected to adopt the first pointer offset method. If one or more files are ranked, the higher the need, the higher the ranking, then the preset ranking range may be the target files ranked in the front preset number of places, for example, the first 3 target files in the file ranking.
[0216] The method provided in the embodiment of the present application can select files ranked within a preset range and adopt a first pointer offset method when the memory space of the electronic device is insufficient, thereby reducing the situation where file reading failures are caused by excessive memory usage when reading files, and improving the stability of the file system.
[0217] Optional, in Figure 7 On the basis of the corresponding embodiments, one or more files are ranked based on the target parameters, including: summing the calculation results of each parameter in the target parameters and sorting them to obtain one or more file rankings; wherein the calculation results of each parameter include one or more of the following: the product of the file size and the first weight, the product of the file pointer offset and the second weight, the product of the file offset frequency and the third weight, and the product of the file usage frequency and the fourth weight.
[0218] Among them, the first weight corresponds to the weight of the file size, for example, the first weight can be 40%; similarly, the second weight corresponds to the weight of the file pointer offset, for example, the second weight can be 20%; the third weight corresponds to the weight of the file offset frequency, for example, the third weight can be 20%; the fourth weight corresponds to the weight of the file usage frequency, for example, the fourth weight can be 20%. It should be understood that the specific weight values can be set by the electronic device according to actual conditions, and the embodiments of the present application are not limited thereto.
[0219] In an embodiment of the present application, the target parameters of the file and their respective corresponding weights are summed, and multiple parameters such as file size, pointer offset, offset frequency and usage frequency are comprehensively considered. Based on the respective corresponding weights, one or more target files that are more suitable for the first pointer offset method are selected to improve the stability of the file system of the electronic device.
[0220] Optional, in Figure 7 On the basis of the corresponding embodiment, the first pointer offset mode includes a fast seek mode, and the second pointer offset mode includes a normal seek mode.
[0221] Among them, the fast seek method can refer to Figure 4 The description of the fast seek method in the embodiment, corresponding to the normal seek method, can refer to Figure 4 Description of the normal seek method in the embodiment.
[0222] In the embodiment of the present application, for the target file, selecting a pointer offset method that is more suitable for the target file between the fast seek method and the normal seek method can significantly improve the efficiency of the file system in reading files and improve the user experience.
[0223] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of the relevant countries and regions, and provide corresponding operation entrances for users to choose to authorize or refuse.
[0224] The above mainly introduces the solution provided by the embodiment of the present application from the perspective of the method. In order to achieve the above functions, it includes hardware structures and / or software modules corresponding to the execution of each function. Those skilled in the art should easily appreciate that, in combination with the method steps of each example described in the embodiment disclosed herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in the form of hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present application.
[0225] The embodiment of the present application can divide the functional modules of the device implementing the method according to the above method example. For example, each functional module can be divided according to each function, or two or more functions can be integrated into one processing module. The integrated module can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of modules in the embodiment of the present application is schematic and is only a logical function division. There may be other division methods in actual implementation.
[0226] like Figure 8 FIG. 8 is a schematic diagram of a chip structure provided by an embodiment of the present application. The chip 800 includes one or more (including two) processors 801 , a communication line 802 , a communication interface 803 and a memory 804 .
[0227] In some implementations, the memory 804 stores the following elements: executable modules or data structures, or a subset thereof, or an extended set thereof.
[0228] The method described in the above embodiment of the present application can be applied to the processor 801, or implemented by the processor 801. The processor 801 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by an integrated logic circuit of hardware or software instructions in the processor 801. The above processor 801 can be a general processor (for example, a microprocessor or a conventional processor), a digital signal processor (digital signal processing, DSP), an application specific integrated circuit (application specific integrated circuit, ASIC), a field-programmable gate array (field-programmable gate array, FPGA) or other programmable logic devices, discrete gates, transistor logic devices or discrete hardware components. The processor 801 can implement or execute the methods, steps and logic block diagrams related to each processing disclosed in the embodiment of the present application.
[0229] The steps of the method disclosed in the embodiment of the present application can be directly embodied as being executed by a hardware decoding processor, or can be executed by a combination of hardware and software modules in the decoding processor. Among them, the software module can be located in a mature storage medium in the field such as a random access memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable read only memory (EEPROM). The storage medium is located in the memory 804, and the processor 801 reads the information in the memory 804 and completes the steps of the above method in combination with its hardware.
[0230] The processor 801 , the memory 804 , and the communication interface 803 may communicate with each other via the communication line 802 .
[0231] In the above embodiments, the instructions stored in the memory for execution by the processor may be implemented in the form of a computer program product, wherein the computer program product may be pre-written in the memory, or may be downloaded and installed in the memory in the form of software.
[0232] The embodiment of the present application also provides a computer program product including one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function according to the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network or other programmable device. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode. The computer-readable storage medium may be any available medium that a computer can store or a data storage device such as a server or data center that includes one or more available media integrated. For example, the available medium may include a magnetic medium (e.g., a floppy disk, a hard disk or a tape), an optical medium (e.g., a digital versatile disc (DVD)), or a semiconductor medium (e.g., a solid state disk (SSD)), etc.
[0233] The present application also provides a computer-readable storage medium. The methods described in the above embodiments can be implemented in whole or in part by software, hardware, firmware, or any combination thereof. Computer-readable media may include computer storage media and communication media, and may also include any medium that can transfer a computer program from one place to another. The storage medium may be any target medium that can be accessed by a computer.
[0234] As a possible design, the computer readable medium may include a compact disc read-only memory (CD-ROM), RAM, ROM, EEPROM or other optical disc storage; the computer readable medium may include a magnetic disk storage or other magnetic disk storage device. Moreover, any connection line may also be appropriately referred to as a computer readable medium. For example, if the software is transmitted from a website, server or other remote source using a coaxial cable, fiber optic cable, twisted pair, DSL or wireless technology (such as infrared, radio and microwave), the coaxial cable, fiber optic cable, twisted pair, DSL or wireless technology such as infrared, radio and microwave are included in the definition of medium. Disk and disc as used herein include compact disc (CD), laser disc, optical disc, digital versatile disc (DVD), floppy disk and Blu-ray disc, where disks usually reproduce data magnetically, while optical discs reproduce data optically using lasers.
[0235] The embodiments of the present application are described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processing unit of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processing unit of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
Claims
1. A file reading method, characterized in that: Applied to electronic equipment, the method comprises: When a target parameter of the target file satisfies a first condition, reading the target file in a first pointer offset manner; When the target parameter of the target file does not satisfy the first condition, reading the target file in a second pointer offset manner; Among them, compared with the second pointer offset method, the first pointer offset method has the following characteristics: a long time to open the file, a large amount of memory is occupied, and the reading speed is fast. The target parameters include one or more of the following: the size of the target file, the pointer offset of the target file, the offset frequency of the target file, and the usage frequency of the target file.
2. The method according to claim 1, characterized in that The first condition includes one or more of the following: the size of the target file is greater than or equal to a first threshold, the pointer offset of the target file is greater than or equal to a second threshold, the offset frequency of the target file is greater than or equal to a third threshold, and the usage frequency of the target file is greater than or equal to a fourth threshold.
3. The method according to claim 1 or 2, characterized in that: The electronic device is configured with a first configuration file, and when a target parameter of the target file satisfies a first condition, reading the target file in a first pointer offset manner includes: When the first configuration file includes the identifier of the target file, the target file is read using the first pointer offset method; wherein the first configuration file includes the identifiers of L files, the target parameters of the L files respectively satisfy the first condition, the L files include the target file, L is a positive integer, and the first configuration file is fixedly set.
4. The method according to any one of claims 1 to 3, characterized in that: The electronic device is configured with a second configuration file, and when a target parameter of the target file satisfies a first condition, reading the target file in a first pointer offset manner includes: When the second configuration file includes the identifier of the target file, the target file is read using the first pointer offset method; wherein the second configuration file includes the identifiers of M files, the target parameters of each of the M files satisfy the first condition, the M files include the target file, M is a positive integer, and the second configuration file is updated by the electronic device at a preset time.
5. The method according to claim 4, characterized in that Before the electronic device updates the second configuration file, the method further includes: Count the target parameters of each of N files, where N is a positive integer; The electronic device updating the second configuration file includes: When target parameters of P files meet the first condition, the electronic device updates the second configuration file, wherein P is a positive integer, the N files include the P files, the second configuration file includes identifiers of the P files, and the P files are different from the M files.
6. The method according to claim 1, characterized in that Before reading the target file in the first pointer offset mode, the method further includes: Counting target parameters of one or more files, wherein the one or more files include the target file; ranking the one or more files based on the target parameter; The method of reading the target file by using a first pointer offset method when the target parameter of the target file satisfies the first condition includes: When the target file is within a preset ranking range, the target file is read in a first pointer offset manner.
7. The method according to claim 6, characterized in that The ranking the one or more files based on the target parameter comprises: Summing and sorting the calculation results of each parameter in the target parameter to obtain the one or more file rankings; The calculation results of the parameters include one or more of the following: the product of the file size and the first weight, the product of the file pointer offset and the second weight, the product of the file offset frequency and the third weight, and the product of the file usage frequency and the fourth weight.
8. The method according to any one of claims 1 to 7, characterized in that: The first pointer offset mode includes a fastseek mode, and the second pointer offset mode includes a normal seek mode.
9. An electronic device, characterized in that: The electronic device comprises: one or more processors and a memory; The memory is coupled to the one or more processors, and the memory is used to store computer program codes, wherein the computer program codes include computer instructions, and the one or more processors call the computer instructions to enable the electronic device to execute the method according to any one of claims 1 to 8.
10. A chip system, characterized in that: The chip system is applied to an electronic device, and the chip system includes one or more processors, and the one or more processors are used to call computer instructions so that the electronic device executes the method according to any one of claims 1-8.
11. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes computer instructions, and when the computer instructions are executed on an electronic device, the electronic device executes the method according to any one of claims 1 to 8.
12. A computer program product, characterized in that The computer program product comprises a computer program code, and when the computer program code is run on an electronic device, the electronic device executes the method according to any one of claims 1 to 8.
Citation Information
Patent Citations
Storage system, file storage and reading method and terminal equipment
CN111506262A
Data operation method and device, computer equipment, and storage medium
CN113821458A
Storage system pre-reading method, device and equipment and storage medium
CN114442948A
Contact person searching method, terminal equipment and storage medium
CN117135253A
Big capacity disk access device and method in mobilecommunication system
KR1020020054145A