WO2024021657A1 - Storage control method and apparatus, device, storage medium, chip, and memory - Google Patents

Storage control method and apparatus, device, storage medium, chip, and memory Download PDF

Info

Publication number
WO2024021657A1
WO2024021657A1 PCT/CN2023/084426 CN2023084426W WO2024021657A1 WO 2024021657 A1 WO2024021657 A1 WO 2024021657A1 CN 2023084426 W CN2023084426 W CN 2023084426W WO 2024021657 A1 WO2024021657 A1 WO 2024021657A1
Authority
WO
WIPO (PCT)
Prior art keywords
storage element
element group
memory
power
storage
Prior art date
Application number
PCT/CN2023/084426
Other languages
French (fr)
Chinese (zh)
Inventor
刘卓睿
Original Assignee
哲库科技(上海)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 哲库科技(上海)有限公司 filed Critical 哲库科技(上海)有限公司
Publication of WO2024021657A1 publication Critical patent/WO2024021657A1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/26Power supply means, e.g. regulation thereof
    • G06F1/32Means for saving power
    • G06F1/3203Power management, i.e. event-based initiation of a power-saving mode
    • G06F1/3234Power saving characterised by the action undertaken
    • G06F1/325Power saving in peripheral device
    • G06F1/3275Power saving in memory, e.g. RAM, cache
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/26Power supply means, e.g. regulation thereof
    • G06F1/32Means for saving power
    • G06F1/3203Power management, i.e. event-based initiation of a power-saving mode
    • G06F1/3206Monitoring of events, devices or parameters that trigger a change in power modality
    • G06F1/3215Monitoring of peripheral devices
    • G06F1/3225Monitoring of peripheral devices of memory devices
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/26Power supply means, e.g. regulation thereof
    • G06F1/32Means for saving power
    • G06F1/3203Power management, i.e. event-based initiation of a power-saving mode
    • G06F1/3234Power saving characterised by the action undertaken
    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11CSTATIC STORES
    • G11C5/00Details of stores covered by group G11C11/00
    • G11C5/14Power supply arrangements, e.g. power down, chip selection or deselection, layout of wirings or power grids, or multiple supply levels
    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11CSTATIC STORES
    • G11C5/00Details of stores covered by group G11C11/00
    • G11C5/14Power supply arrangements, e.g. power down, chip selection or deselection, layout of wirings or power grids, or multiple supply levels
    • G11C5/143Detection of memory cassette insertion or removal; Continuity checks of supply or ground lines; Detection of supply variations, interruptions or levels ; Switching between alternative supplies
    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11CSTATIC STORES
    • G11C5/00Details of stores covered by group G11C11/00
    • G11C5/14Power supply arrangements, e.g. power down, chip selection or deselection, layout of wirings or power grids, or multiple supply levels
    • G11C5/147Voltage reference generators, voltage or current regulators; Internally lowered supply levels; Compensation for voltage drops
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Definitions

  • the embodiments of the present application relate to the field of storage technology, and in particular to a storage control method, device, equipment, storage medium, chip and memory.
  • Memory is an essential electronic component in terminal equipment.
  • a memory includes multiple storage elements. When the memory needs to work, all the storage elements included in the memory can be set to the powered-on state; when the memory does not need to work, all the storage elements included in the memory can be set to the powered-off state to save power consumption.
  • Embodiments of the present application provide a storage control method, device, equipment, storage medium, chip and memory.
  • the technical solutions are as follows:
  • a storage control method includes:
  • control the second storage element group of the memory Based on the memory switching from the first operating mode to the second operating mode, control the second storage element group of the memory to switch from the power-off state to the power-on state;
  • the memory includes a first storage element group configured to store a first type of data and a second storage element group configured to store a second type of data.
  • a storage control device is provided, and the device is configured to:
  • control the second storage element group of the memory Based on the memory switching from the first operating mode to the second operating mode, control the second storage element group of the memory to switch from the power-off state to the power-on state;
  • the memory includes a first storage element group configured to store a first type of data and a second storage element group configured to store a second type of data.
  • a terminal device includes a processor and a memory.
  • a computer program is stored in the memory.
  • the processor executes the computer program to implement the above storage control method. .
  • a computer-readable storage medium is provided, and a computer program is stored in the storage medium, and the computer program is used to be executed by a processor to implement the above storage control method.
  • a chip is provided, and the chip includes the above-mentioned storage control device.
  • a memory includes:
  • a first storage element group used to store first type data
  • a second storage element group is used to store second type data, wherein the second storage element group is configured to switch from a power-down state to a power-on state based on the memory switching from the first operating mode to the second operating mode.
  • a computer program product includes computer instructions.
  • the computer instructions are stored in a computer-readable storage medium.
  • a processor reads the computer-readable storage medium from the computer-readable storage medium. Fetch and execute the computer instructions to implement the above storage control method.
  • different storage element groups are used to store different types of data, thereby enabling on-demand use of the storage element groups.
  • the storage element group can be controlled to be in a power-off state.
  • the storage element group can be controlled to power off. The power state is switched to the power-on state.
  • Figure 1 is a schematic structural diagram of a system-on-chip including a memory provided by an embodiment of the present application
  • Figure 2 is a schematic structural diagram of a memory provided by an embodiment of the present application.
  • Figure 3 is a schematic diagram of storage element group division provided by an embodiment of the present application.
  • Figure 4 is a schematic diagram of storage element group division provided by another embodiment of the present application.
  • Figure 5 is a flow chart of a storage control method provided by an embodiment of the present application.
  • Figure 6 is a schematic diagram of the division and use of storage element groups provided by an embodiment of the present application.
  • Figure 7 is a schematic diagram of application type conversion provided by an embodiment of the present application.
  • Figure 8 is a flow chart of a storage control method provided by another embodiment of the present application.
  • Figure 9 is a block diagram of a storage control device provided by an embodiment of the present application.
  • Figure 10 is a schematic diagram of a terminal device provided by an embodiment of the present application.
  • FIG. 1 is a schematic structural diagram of a system on chip (SoC) including a memory provided by an exemplary embodiment of the present application.
  • SoC system on chip
  • the system-on-chip in this application can be used in mobile terminals, such as smartphones, smart watches, e-book readers, tablet computers, laptop computers, desktop computers, televisions, game consoles, and augmented reality (Augmented Reality, AR) terminals. Taking at least one of a virtual reality (Virtual Reality, VR) terminal, a mixed reality (MR) terminal, a wearable device, etc. as an example for explanation.
  • the system-on-chip 100 in this embodiment includes: a main device 101, a main bus 103, a memory controller 105 and a memory 200.
  • the main device 101 is connected to the storage controller 105 through the main bus 103 (Primary Bus), and the storage controller 105 is connected to the memory 200 through a physical layer (Physical Layer, PHY) interface.
  • the memory 200 is a dynamic random access memory (Dynamic Random Access Memory, DRAM).
  • DRAM Dynamic Random Access Memory
  • the DRAM adopts Packaging on Packaging (PoP) packaging.
  • the master device 101 is a processor or non-processor with data reading and writing requirements.
  • the main device may include, but is not limited to, a central processing unit (CPU), a graphics processor (Graphics Processing Unit, GPU), a neural network processor (Neural-network Processing Unit, NPU), a digital signal processor (Digital Signal) Processors such as Processor (DSP), and non-processors such as Image Sensor (Image Sensor), Image Signal Processing Unit (ISP), and Video Processing Unit (VPU).
  • CPUs include CPU, GPU and NPU, and non-processors
  • An image sensor and a VPU are taken as examples for schematic explanation, but this does not constitute a limitation.
  • the processor uses various interfaces and lines to connect various parts of the entire terminal device, and executes the terminal device by running or executing instructions, programs, code sets or instruction sets stored in the memory, and calling data stored in the memory. various functions and process data.
  • the processor may adopt at least one of digital signal processing (Digital Signal Processing, DSP), field-programmable gate array (Field-Programmable Gate Array, FPGA), and programmable logic array (Programmable Logic Array, PLA).
  • DSP Digital Signal Processing
  • FPGA field-programmable gate array
  • PLA programmable logic array
  • the processor can integrate one or a combination of CPU, GPU, NPU and baseband chip.
  • the CPU mainly handles the operating system, user interface and applications;
  • the GPU is responsible for the rendering and drawing of the content that needs to be displayed on the display;
  • the NPU is used to implement AI (Artificial Intelligence, artificial intelligence) functions;
  • the baseband chip is used for processing Wireless communication.
  • m links using the AXI (Advanced eXtensible Interface, Advanced Extension Interface) protocol are established between the main device 101 and the main bus 103, and between the main bus 103 and the storage controller 105.
  • AXI Advanced eXtensible Interface, Advanced Extension Interface
  • FIG. 1 four AXI links with a width of 256 bits are established between each master device 101 and the main bus 103, and between the main bus 103 and the memory controller 105.
  • the storage controller 105 includes a secondary bus, k controllers (corresponding to k memory channels), and physical layer interfaces corresponding to each controller, where k is a positive integer.
  • a link using the AXI protocol is established between the slave bus and the controller, and the branching function is implemented at the slave bus. For example, after the slave bus is branched (k branches are n branches, n is a positive integer), 8 AXI links with a bit width of 128 bits are established between the slave bus and the controller. Correspondingly, eight AXI links with a bit width of 128 bits are established between the memory controller 105 and the memory 200 .
  • the memory 200 is a memory that supports n (n>k) memory channels, and the n storage elements in the memory 200 each have a working bus, that is, the working bus of each storage element is connected to the storage controller 105 in a concurrent manner.
  • Figure 1 takes a system on a chip that integrates a memory (that is, the memory is arranged inside the system on a chip) as an example.
  • the memory can be arranged outside the system on a chip. This is not limited in the embodiments of the present application.
  • Figure 2 is a schematic structural diagram of a memory provided by an exemplary embodiment of the present application.
  • the memory 200 includes n storage elements 201, where n is an integer greater than 1.
  • the memory 200 is a DRAM
  • the storage element 201 is a memory die.
  • the DRAM is packaged in TOP.
  • the embodiment of the present application does not limit the specific types of the memory 200 and the storage element 201.
  • the internal particles of the storage element 201 may be arranged in a 2D (Two Dimensional, two-dimensional) manner or a 3D (Three Dimensional, three-dimensional) manner.
  • the 3D arrangement can adopt simple stack (Simple Stack), vertical channel (Vertical Channel, VC) or vertical gate (Vertical Grid, VG) and other methods.
  • each storage element 201 has a specification of 16Gb ⁇ 16 data width (Datawidth).
  • Datawidth 16Gb ⁇ 16 data width
  • some storage elements have the same component parameters, some storage components have different component parameters, or different storage components have different component parameters. The embodiments of this application do not limit the specific component parameters of each storage component.
  • n storage elements 201 are packaged into a storage particle, such as a DRAM device using POP packaging.
  • the n storage elements 201 adopt 2D packaging or 3D packaging.
  • the embodiments of this application do not limit the specific packaging method.
  • the memory 200 in the embodiment of the present application supports n memory channels, so the number of storage elements 201 in the memory 200 is equal to n, and different storage elements 201 correspond to respective memory channels, that is, n storage elements correspond to n memory channels. .
  • n storage elements correspond to n memory channels.
  • the embodiments of the present application do not limit the specific number of storage elements (a positive integer is sufficient, and it can be an even number or an odd number).
  • the memory 200 includes: m storage element groups, each storage element group includes at least one storage element 201, and m is an integer greater than 1. That is to say, the n storage elements 201 included in the memory 200 are divided into m storage element groups.
  • One storage element group may have one and only one storage element 201, or may include multiple (two or more) storage elements 201. Storage element 201.
  • the number of storage elements 201 included in each storage element group is the same.
  • the memory 200 includes 8 storage elements 201, which are divided into 2 storage element groups, denoted as a first storage element group and a second storage element group, each A storage element group includes four storage elements 201.
  • the first storage element group includes storage elements 201 corresponding to memory channels A, B, C and D respectively
  • the second storage element group includes storage elements 201 corresponding to memory channels E, F, G and H respectively.
  • the memory 200 includes 8 storage elements 201, and the 8 storage elements 201 are divided into 4 storage element groups, and each storage element group includes 2 storage elements 201.
  • each storage element group includes one storage element 201, and the memory 200 includes 8 storage elements 201, and the 8 storage elements 201 are divided into 8 storage element groups.
  • the number of storage elements 201 included in each storage element group is the same, there is no limit to the number of storage elements 201 included in each storage element group, which can be flexibly set according to actual needs. .
  • m storage element groups there are at least two storage element groups that contain different numbers of storage elements 201 .
  • the memory 200 includes 6 storage elements 201.
  • the 6 storage elements 201 are divided into 2 storage element groups, denoted as a first storage element group and a second storage element group.
  • the first The storage element group includes 2 storage elements 201
  • the second storage element group includes 4 storage elements 201.
  • the first storage element group includes storage elements 201 corresponding to memory channels A and B respectively
  • the second storage element group includes storage elements 201 corresponding to memory channels C, D, E and F respectively.
  • the memory 200 includes 8 storage elements 201, and the 8 storage elements 201 are divided into 3 storage element groups, denoted as the first storage element group, the second storage element group and the third storage element group; wherein, the One storage element group includes two storage elements 201 , a second storage element group includes two storage elements 201 , and a third storage element group includes four storage elements 201 .
  • the number of storage elements 201 included in at least two storage element groups is different, the number of storage elements 201 included in each storage element group is not limited, and this can be done in accordance with actual needs. Flexible settings.
  • FIG. 5 is a flow chart of a storage control method provided by an embodiment of the present application.
  • the method can be performed by a control circuit.
  • the control circuit is used to control the memory, such as controlling the power-on or power-off state of each storage element or storage element group in the memory.
  • the control circuit can be any form of processor, controller, microprocessor or integrated circuit chip with data processing capabilities. This application describes the implementation form of the control circuit. The formula is not limited.
  • the control circuit may be provided inside the memory.
  • the control circuit may also be provided inside the power management chip corresponding to the memory (the power management chip is used to provide input voltage for the memory).
  • the control circuit may also be provided inside the memory chip for carrying the memory. This application does not limit the location of the control circuit on the circuit board of the memory and/or power management chip.
  • the method may include the following steps 510:
  • Step 510 Based on the memory switching from the first operating mode to the second operating mode, control the second storage element group of the memory to switch from the power-off state to the power-on state; wherein the memory includes a first storage configured to store the first type of data. A group of elements and a second group of storage elements configured to store data of a second type.
  • the memory includes multiple storage element groups, and each storage element group includes at least one storage element.
  • each storage element group includes at least one storage element.
  • the first storage element group and the second storage element group are different storage element groups.
  • the memory includes two storage element groups, the first storage element group 61 is one of the two storage element groups, and the second storage element group 62 is the two storage element groups. Another storage element group within the group.
  • the memory includes 3 or more storage element groups, the first storage element group is at least one storage element group among the 3 or more storage element groups, and the second storage element group is the 3 or more storage element groups. At least one storage element group among three or more storage element groups, and the second storage element group and the first storage element group do not have the same storage element group.
  • the first storage element group is at least one storage element group among the 3 or more storage element groups, and the second storage element group is the 3 or more storage element groups except the first storage element group. The remaining storage element groups outside the group.
  • a certain storage element group is in a powered-on state, which means that the power management chip of the memory provides an input voltage to each storage element in the storage element group, so that each storage element in the storage element group can Normal work is used to store the state of data.
  • a certain storage element group is in a power-off state, which means that the power management chip of the memory does not provide input voltage to each storage element in the storage element group, so that each storage element in the storage element group does not receive input voltage to work. state.
  • the storage element group in the powered-on state can be used to store data, while the storage element group in the powered-off state cannot be used to store data.
  • the first storage element group in the first operating mode of the memory, is controlled to be in a power-on state, and the second storage element group is controlled to be in a power-down state.
  • the first working mode since only the first type of data needs to be stored, and the first type of data is stored by the first storage element group , so the first storage element group of the control memory is in the powered-on state, and the second storage element group of the control memory is in the powered-off state.
  • the power management chip of the memory provides an input voltage to each storage element in the first storage element group, so that the first storage element group can operate normally and is used to store the first type of storage element. The data.
  • the second storage element group is controlled to be in a power-off state, that is, the power management chip of the memory does not provide power to the second storage element group.
  • Each storage element in the storage element group provides an input voltage, so that the second storage element group does not work when powered off, thereby saving power.
  • the power management chip of the control memory provides an input voltage to each storage element in the second storage element group, so that the second storage element group can operate normally and is used to store the second type of data.
  • the first storage element group when switching from the first operating mode to the second operating mode, the first storage element group is controlled to remain powered on, that is, the first storage element group is always powered on regardless of whether it is in the first operating mode or the second operating mode. Is powered on and provides the necessary storage area. By controlling the first storage element group to always be in a powered-on state, it is ensured that an application program using the first storage element group can efficiently use the storage area.
  • the second type of data is different from the first type of data, that is, the first type of data and the second type of data are two different types of data.
  • the method of classifying data types is not limited.
  • the types can be classified according to the source of the data (such as the data producer or provider).
  • different types of data are divided based on whether the application that generates the data belongs to the target type.
  • there is no application program of the target type running in the first working mode there is an application program running of the target type in the second working mode, and the second type of data includes data corresponding to the application program of the target type.
  • the control memory switches to the second working mode.
  • the memory in the absence of an application program of the target type running, it is determined that the memory operates in a first operating mode, the first storage element group of the memory is controlled to be in a powered-on state, and the second storage element group of the memory is controlled In the power-off state; when there is an application program of the target type running, it is determined that the memory operates in the second working mode, and the first storage element group and the second storage element group of the control memory are both in the power-on state.
  • the second type of data includes data corresponding to the target type of application
  • the first One type of data includes data corresponding to applications other than the target type application.
  • the applications of the terminal device are divided into normal applications (Normal Usage APP) and high-performance applications (Performance Usage APP).
  • the target type of applications is high-performance applications, except for the target type of applications.
  • the other apps are normal apps.
  • the first storage element group 61 is used by ordinary applications
  • the second storage element group 62 is used by high-performance applications.
  • the first storage element group 61 is also used to provide default kernel space and reserved space for use by the kernel and storage requirements under some special circumstances.
  • the target type of application can be fixed, that is, it will not change dynamically.
  • the target type of application can also be dynamically determined, that is, it can be dynamically changed.
  • an application can change from belonging to the target type to not belonging to the target type, or from not belonging to the target type to belonging to the target type.
  • the method of dynamically determining the application program of the target type please refer to the introduction in the embodiment below.
  • the second type of data generated in the second operating mode is stored in the second storage element group.
  • the first storage element group is not used to store the second type of data generated in the second operating mode. That is to say, the first storage element group is only used to store the first type of data, and the second type of data can only be stored through the second storage element group and cannot be stored through the first storage element group. In this way, the isolation of different types of data storage in different working modes is achieved, which helps to improve the security and reliability of data storage.
  • the operating frequencies of various storage element groups included in the memory can be controlled uniformly or independently.
  • the above operating frequency can also be called the operating rate.
  • the operating frequency of the storage element group refers to the clock frequency of the storage element group, or it can also be the data reading and writing frequency of the storage element group.
  • the above clock frequency is also related to the data reading and writing frequency.
  • the clock frequency and the data reading and writing frequency are positively correlated. relation.
  • Unified control of the operating frequencies of each storage element group refers to unified control of the operating frequencies of each storage element group based on unified parameter indicators, and the operating frequencies of each storage element group are the same.
  • the operating frequency of each storage element group is independently controlled, which means that the operating frequency of each storage element group is independently controlled according to the parameter index of each storage element group.
  • the operating frequency of the first storage element group and the operating frequency of the second storage element group are independently controlled.
  • the operating frequency of the first storage element group and the operating frequency of the second storage element group are controlled independently.
  • the parameter index of the group determines the operating frequency of the first storage element group (recorded as the first operating frequency), and controls the first storage element group to operate according to the first operating frequency.
  • the operating frequency of the second storage element group (denoted as the second operating frequency) is determined according to the parameter index of the second storage element group, and the second storage element group is controlled according to the second operating frequency. Work at two operating frequencies.
  • the above-mentioned first operating frequency and the second operating frequency may be the same or different, thereby achieving independent control.
  • the above-mentioned parameter index used to determine the operating frequency may be a load parameter, which may also be called a bandwidth parameter.
  • the load parameter of a storage element group refers to the amount of access to the storage element group within a unit time.
  • there is a positive correlation between the operating frequency of the storage element group and the load parameter that is, the greater the load parameter, the greater the operating frequency, and conversely, the smaller the load parameter, the smaller the operating frequency.
  • the operation of the first storage element group can be controlled.
  • the frequency (that is, the first operating frequency) is greater than the operating frequency of the second storage element group (that is, the second operating frequency); assuming that the load parameter of the first storage element group is smaller than the load parameter of the second storage element group, then the The operating frequency of the first storage element group (that is, the first operating frequency) is smaller than the operating frequency of the second storage element group (that is, the second operating frequency); assuming that the load parameter of the first storage element group is equal to the load parameter of the second storage element group Load parameters, then the operating frequency of the first storage element group (that is, the first operating frequency) and the operating frequency of the second storage element group (that is, the second operating frequency) can be controlled to be equal.
  • the operating frequencies of different storage element groups are decoupled and independently controlled, and the operating frequency of each storage element group is determined according to the load parameters of each storage element group, which can realize the actual access requirements of the storage element group. Properly setting the operating frequency will help further improve energy saving effects.
  • the storage element group by dividing the memory into multiple storage element groups (for example, including at least a first storage element group and a second storage element group), different storage element groups are used to store different types of data, so that it can be achieved On-demand use of storage element groups. For example, when there is no data corresponding to a certain storage element group that needs to be stored, the storage element group can be controlled to be in a power-off state. When there is need to store data corresponding to the storage element group, the storage element group can be controlled to power off. Controlling the storage element group to switch from the power-off state to the power-on state, this on-demand allocation and control method can save the power consumption of the memory and achieve a better energy-saving effect.
  • historical running data of at least one application program in the terminal device is obtained, and a target type of application program is determined from each application program based on the historical running data of each application program.
  • the historical running data of the application is used to record the historical running status of the application.
  • the historical running data of the application includes but is not limited to at least one of the following: historical storage space usage, historical power consumption, historical usage frequency, and historical CPU usage.
  • the historical storage space usage is used to reflect the application's demand for storage space.
  • the indicator can be obtained by counting the storage space usage when the application is running in the recent period.
  • Historical power consumption is used to reflect the battery power consumption of the application.
  • this indicator can be obtained by counting the battery power consumption of the application during the recent period of operation.
  • the historical usage frequency is used to reflect the user's frequency of use of the application.
  • the indicator can be obtained by counting the number of times and/or the running time of the application in the recent period.
  • the historical CPU usage is used to reflect the application's usage of CPU processing resources.
  • this indicator can be obtained by counting the CPU usage of the application when it was running in the recent period.
  • Each of the above indicators can reflect the performance requirements of the application. For example, the greater the historical storage space usage, the greater the historical power consumption, the greater the historical frequency of use, and the greater the historical CPU usage, the greater the historical CPU usage. The higher the performance requirements. Therefore, based on the above indicators, we can classify whether the application belongs to the target type from the perspective of performance requirements, and obtain the applications that belong to the target type (such as high-performance applications) and the applications that do not belong to the target type (such as common applications). Among them, the performance requirements of applications belonging to the target type (such as high-performance applications) are greater than those of applications that do not belong to the target type (such as ordinary applications).
  • the above-mentioned latest period of time refers to a period of time starting from the current moment and working backwards.
  • the length of the latest period of time can be reasonably set based on actual needs, such as 1 month, 1 week, 1 day, 1 hour, etc. This application does not limit this.
  • a threshold corresponding to the indicator can be set. If the indicator of the application is greater than (or less than) the threshold, it is determined that the application belongs to the target type, and vice versa. If the indicator of an application is less than (or greater than) the threshold, it is determined that the application does not belong to the target type. Taking the indicator as historical storage space usage as an example, if the historical storage space usage of an application is greater than the threshold, it is determined that the application belongs to the target type. On the contrary, if the historical storage space usage of the application is less than the threshold, it is determined that the application does not belong to the target type. Belongs to target type.
  • a comprehensive indicator when the historical operating data only includes multiple indicators, a comprehensive indicator can be calculated based on the multiple indicators, and a threshold corresponding to the comprehensive indicator can be set. Among them, the comprehensive indicator reflects the overall situation of the above-mentioned indicators. If the comprehensive indicator of the application is greater than (or less than) the threshold, it is determined that the application belongs to the target type. On the contrary, if the comprehensive indicator of the application is less than (or greater than) >) threshold determines that the application does not belong to the target type. Take historical operating data including historical storage space usage, historical power consumption, historical usage frequency, and historical CPU usage as an example.
  • the above method of calculating the comprehensive index can be to perform a weighted average or weighted sum of multiple indicators to obtain a comprehensive index, or to input multiple indicators into a neural network model and output the comprehensive index through the neural network model, or to use This application does not limit other calculation methods.
  • applications are divided into two major categories, including high-performance applications and ordinary applications.
  • the memory includes a first storage element group and a second storage element group. Data of ordinary application programs are stored in the first storage element group, and data of high-performance application programs are stored in the second storage element group.
  • the first storage element group cannot be used to store data of high-performance applications
  • the second storage element group cannot be used to store data of ordinary applications, so that the data of the two types of applications are isolated from each other.
  • whether it is a high-performance application or a normal application can be determined and adjusted dynamically. For example, the historical running data of the application is obtained, and whether the application is a high-performance application or a normal application is determined based on the historical running data of the application.
  • a switching strategy may be used in combination with historical running data of each application in the terminal device to determine the application belonging to the target type from each application.
  • the switching policy refers to the policy used to determine whether the application belongs to the target type.
  • the switching strategy may be a dynamic selection strategy based on Markov chain, or other dynamic selection strategies, which is not limited in this application.
  • the usage relationship between the application program and the storage element group is not static.
  • the application program belongs to the target type, it uses the second storage element group.
  • the application does not belong to the target type, it uses the first storage element group for data storage, and whether the application belongs to the target type can be dynamically switched according to the user's recent usage of the application, improving It improves the flexibility of memory usage and the rationality of memory allocation.
  • Figure 8 is a flow chart of a storage control method provided by another embodiment of the present application. This method can be performed by the control circuit introduced above. The method may include at least one of the following steps 810 to 830: Steps:
  • Step 810 In the first working mode of the memory, the first storage element group of the control memory is in the powered-on state, and the second storage element group of the control memory is in the powered-off state; wherein, the first storage element group is used to store the first A type of data.
  • Step 820 Based on the memory switching from the first working mode to the second working mode, control the second storage element group of the memory to switch from the power-off state to the power-on state.
  • the second storage element group is used to store the data generated in the second working mode.
  • the second type of data is different from the first type of data.
  • Step 830 Based on the memory switching from the second operating mode to the first operating mode, control the second storage element group of the memory to switch from the power-on state to the power-off state.
  • the memory can be controlled to switch from the second working mode to the first working mode, and the second storage element group of the memory can be controlled to switch from the power-on state to the power-off state, thereby saving power. For example, if it is determined that no application program of the target type is running, the second storage element group is controlled to switch from the power-on state to the power-off state.
  • control the second storage element group after switching from the first working mode to the second working mode, if there is no application program of the target type running within the target time period, control the second storage element group to switch from the power-on state to the power-off state; wherein , within the target duration, the second storage element group remains powered on. That is to say, after the application program of the target type stops running, the second storage element group is not controlled to power off immediately at the moment when it stops running. Instead, it waits for a period of time and no application program of the target type is running during this period of time. In this case, the second storage element group is then controlled to power off.
  • the second storage element group can be avoided from being powered on and off frequently, and when an application of the target type is started again in a short period of time, the second storage element group can be directly used to improve the normal operation of the application of the target type after being restarted. state efficiency.
  • Figure 9 is a block diagram of a storage control device provided by an embodiment of the present application.
  • the device has the function of implementing the above method example, and the function can be implemented by hardware, or can be implemented by hardware executing corresponding software.
  • the device 900 may be the control circuit introduced above, or may be provided in the control circuit.
  • the device 900 is configured to switch from the first operating mode to the The second operating mode controls the second storage element group of the memory to switch from the power-off state to the power-on state; wherein the memory includes a first storage element group configured to store the first type of data and a second storage element group configured to store the second type of data.
  • the second storage element group of type data is configured to switch from the first operating mode to the The second operating mode controls the second storage element group of the memory to switch from the power-off state to the power-on state; wherein the memory includes a first storage element group configured to store the first type of data and a second storage element group configured to store the second type of data.
  • the second storage element group of type data is configured to switch from the first operating mode to the The second operating mode controls the second storage element group of the memory to switch from the power-off state to the power-on state; wherein the memory includes a first storage element group configured to store the first type of data and a second storage element group configured to store the second type of data. The second storage element group of type data
  • the device 900 is further configured to, in the first operating mode of the memory, control the first storage element group to be in a power-on state, and control the second storage element group to be in a power-down state. power status.
  • the device 900 is further configured to control the memory to switch to the second working mode based on determining the target type of application execution.
  • the apparatus 900 is further configured to dynamically determine the target type of application.
  • the apparatus 900 is further configured to obtain historical running data of at least one application in the terminal device; wherein the historical running data is used to record the historical running status of the application; according to each of the The historical running data of the application program determines the application program of the target type from each of the application programs.
  • the device 900 is further configured to store the second type of data generated in the second operating mode in the second storage element group.
  • the device 900 is further configured to control the second storage element group to switch from the power-on state to the first operating mode based on the memory switching from the second operating mode to the first operating mode. Describe the power-off status.
  • the device 900 is further configured to, after switching from the first working mode to the second working mode, if there is no application program of the target type running within a target duration, control all The second storage element group switches from the power-on state to the power-down state; wherein, within the target time period, the second storage element group maintains the power-on state.
  • the device 900 is further configured to control the first storage element group to maintain the power-on state when switching from the first operating mode to the second operating mode.
  • the apparatus 900 is further configured to independently control the operating frequency of the first storage element group and the operating frequency of the second storage element group.
  • the device 900 may include: a first control module 910 and a second control module 920 .
  • the first control module 910 is configured to control the clock frequency and/or data reading and writing frequency of the first storage element group.
  • the second control module 920 is configured to control the clock frequency of the second storage element group and/or data read and write frequency.
  • the memory by dividing the memory into multiple storage element groups (for example, including at least a first storage element group and a second storage element group), different storage element groups are used to store different types of data, thereby enabling storage On-demand use of element groups. For example, when there is no data corresponding to a certain storage element group that needs to be stored, the storage element group can be controlled to be in a power-off state. When there is need to store data corresponding to the storage element group, the storage element group can be controlled again. The storage element group switches from the power-off state to the power-on state.
  • This on-demand allocation and control method can save the power consumption of the memory and achieve a better energy-saving effect.
  • Figure 10 is a schematic diagram of a terminal device provided by an exemplary embodiment of the present application. Take the terminal device 1500 in this embodiment including the main device 101 and the memory 200 as an example for explanation:
  • the terminal device 1500 is provided with a main device 101 and the memory 200 described in the above embodiment, and the main device 101 and the memory 200 are electrically connected.
  • the memory 200 may be provided inside the system-on-chip or outside the system-on-chip. It should be noted that in addition to the system on a chip, the terminal device 1500 may also include other necessary components, such as read-only memory (Read-Only Memory, ROM), display components, input units, audio circuits, speakers, microphones, power supplies and other components. This embodiment will not be described in detail here.
  • the terminal device 1500 may be an electronic device such as a mobile phone, a tablet computer, a game console, an e-book reader, a multimedia playback device, a wearable device, etc.
  • the terminal device 1500 is a mobile terminal device.
  • the terminal device is used to implement the storage control method provided in the above embodiment.
  • the terminal device includes a processor and a memory.
  • the processor may be the processor in the main device 101 described above, and the memory may be the memory 200 described above.
  • a computer program is stored in the memory, and the processor executes the computer program to implement the above storage control method.
  • the present application also provides a computer-readable storage medium in which a computer program is stored, and when executed by a processor, the computer program implements the above storage control method.
  • the computer-readable storage medium may include: ROM (Read-Only Memory), RAM (Random-Access Memory), SSD (Solid State Drives, solid state drive) or optical disk, etc.
  • random access memory can include ReRAM (Resistance Random Access Memory, resistive random access memory) and DRAM (Dynamic Random Access Memory, dynamic random access memory).
  • the present application also provides a chip, which includes the storage control device as provided in the above embodiments.
  • a chip which includes the storage control device as provided in the above embodiments.
  • this application also provides a memory, the memory includes:
  • a first storage element group used to store first type data
  • a second storage element group is used to store second type data, wherein the second storage element group is configured to switch from a power-down state to a power-on state based on the memory switching from the first operating mode to the second operating mode.
  • the present application also provides a computer program product, the computer program product includes a computer program, and the computer program is stored in a computer-readable storage medium.
  • the processor of the terminal device reads the computer program from the computer-readable storage medium, and the processor executes the computer instructions, so that the terminal device executes the above storage control method.
  • the "plurality” mentioned in this article means two or more than two.
  • “And/or” describes the relationship between related objects, indicating that there can be three relationships.
  • a and/or B can mean: A exists alone, A and B exist simultaneously, and B exists alone.
  • the character “/” generally indicates that the related objects are in an "or” relationship.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Power Engineering (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Power Sources (AREA)

Abstract

A storage control method and apparatus, a device, a storage medium, a chip, and a memory, relating to the technical field of storage. The method comprises: on the basis of a memory switching from a first working mode to a second working mode, controlling a second memory element group of the memory to switch from a power-off state to a power-on state, wherein the memory comprising a first memory element group, configured to store a first type of data, and the second memory element group, configured to store a second type of data (510). The present application can implement on-demand use of memory element groups, and by means of an on-demand distribution and control means, power consumption of the memory can be reduced and a better energy-saving effect can be achieved.

Description

存储控制方法、装置、设备、存储介质、芯片及存储器Storage control method, device, equipment, storage medium, chip and memory
本申请要求于2022年07月25日提交的申请号为202210875910.9、发明名称为“存储控制方法、装置、设备、存储介质、芯片及存储器”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims priority to the Chinese patent application with application number 202210875910.9 and the invention name "storage control method, device, equipment, storage medium, chip and memory" submitted on July 25, 2022, the entire content of which is incorporated by reference. in this application.
技术领域Technical field
本申请实施例涉及存储技术领域,特别涉及一种存储控制方法、装置、设备、存储介质、芯片及存储器。The embodiments of the present application relate to the field of storage technology, and in particular to a storage control method, device, equipment, storage medium, chip and memory.
背景技术Background technique
存储器是终端设备中必不可少的电子元件。Memory is an essential electronic component in terminal equipment.
相关技术中,存储器包含多个存储元件。当存储器需要工作时,可以将存储器包含的全部存储元件均置为上电状态;当存储器不需要工作时,可以将存储器包含的全部存储元件均置为下电状态,以节省功耗。In related art, a memory includes multiple storage elements. When the memory needs to work, all the storage elements included in the memory can be set to the powered-on state; when the memory does not need to work, all the storage elements included in the memory can be set to the powered-off state to save power consumption.
然而,上述方式已无法满足一些场景下的省电需求。However, the above method can no longer meet the power saving needs in some scenarios.
发明内容Contents of the invention
本申请实施例提供了一种存储控制方法、装置、设备、存储介质、芯片及存储器。所述技术方案如下:Embodiments of the present application provide a storage control method, device, equipment, storage medium, chip and memory. The technical solutions are as follows:
根据本申请实施例的一个方面,提供了一种存储控制方法,所述方法包括:According to one aspect of the embodiment of the present application, a storage control method is provided, and the method includes:
基于存储器从第一工作模式切换至第二工作模式,控制所述存储器的第二存储元件组从下电状态切换到上电状态;Based on the memory switching from the first operating mode to the second operating mode, control the second storage element group of the memory to switch from the power-off state to the power-on state;
其中,所述存储器包括配置成存储第一类型数据的第一存储元件组和配置成存储第二类型数据的所述第二存储元件组。Wherein, the memory includes a first storage element group configured to store a first type of data and a second storage element group configured to store a second type of data.
根据本申请实施例的一个方面,提供了一种存储控制装置,所述装置配置成:According to one aspect of the embodiment of the present application, a storage control device is provided, and the device is configured to:
基于存储器从第一工作模式切换至第二工作模式,控制所述存储器的第二存储元件组从下电状态切换到上电状态; Based on the memory switching from the first operating mode to the second operating mode, control the second storage element group of the memory to switch from the power-off state to the power-on state;
其中,所述存储器包括配置成存储第一类型数据的第一存储元件组和配置成存储第二类型数据的所述第二存储元件组。Wherein, the memory includes a first storage element group configured to store a first type of data and a second storage element group configured to store a second type of data.
根据本申请实施例的一个方面,提供了一种终端设备,所述终端设备包括处理器和存储器,所述存储器中存储有计算机程序,所述处理器执行所述计算机程序以实现上述存储控制方法。According to an aspect of an embodiment of the present application, a terminal device is provided. The terminal device includes a processor and a memory. A computer program is stored in the memory. The processor executes the computer program to implement the above storage control method. .
根据本申请实施例的一个方面,提供了一种计算机可读存储介质,所述存储介质中存储有计算机程序,所述计算机程序用于被处理器执行,以实现上述存储控制方法。According to one aspect of an embodiment of the present application, a computer-readable storage medium is provided, and a computer program is stored in the storage medium, and the computer program is used to be executed by a processor to implement the above storage control method.
根据本申请实施例的一个方面,提供了一种芯片,所述芯片包括上述存储控制装置。According to one aspect of the embodiment of the present application, a chip is provided, and the chip includes the above-mentioned storage control device.
根据本申请实施例的一个方面,提供了一种存储器,所述存储器包括:According to one aspect of the embodiment of the present application, a memory is provided, and the memory includes:
第一存储元件组,用于存储第一类型数据;A first storage element group used to store first type data;
第二存储元件组,用于存储第二类型数据,其中,所述第二存储元件组配置成基于所述存储器从第一工作模式切换至第二工作模式从下电状态切换到上电状态。A second storage element group is used to store second type data, wherein the second storage element group is configured to switch from a power-down state to a power-on state based on the memory switching from the first operating mode to the second operating mode.
根据本申请实施例的一个方面,提供了一种计算机程序产品,所述计算机程序产品包括计算机指令,所述计算机指令存储在计算机可读存储介质中,处理器从所述计算机可读存储介质读取并执行所述计算机指令,以实现上述存储控制方法。According to an aspect of an embodiment of the present application, a computer program product is provided. The computer program product includes computer instructions. The computer instructions are stored in a computer-readable storage medium. A processor reads the computer-readable storage medium from the computer-readable storage medium. Fetch and execute the computer instructions to implement the above storage control method.
本申请实施例提供的技术方案,可以带来如下技术效果:The technical solutions provided by the embodiments of this application can bring the following technical effects:
通过将存储器划分为多个存储元件组(如至少包括第一存储元件组和第二存储元件组),不同的存储元件组用于存储不同类型的数据,从而能够实现存储元件组的按需使用,例如在没有某一存储元件组对应的数据需要存储时,则可以控制该存储元件组处于下电状态,在有需要该存储元件组对应的数据需要存储时,再控制该存储元件组从下电状态切换至上电状态,这种按需分配和控制的方式,能够节省存储器的电量消耗,达到较好的节能效果。By dividing the memory into multiple storage element groups (for example, including at least a first storage element group and a second storage element group), different storage element groups are used to store different types of data, thereby enabling on-demand use of the storage element groups. , for example, when there is no data corresponding to a certain storage element group that needs to be stored, the storage element group can be controlled to be in a power-off state. When there is data corresponding to the storage element group that needs to be stored, the storage element group can be controlled to power off. The power state is switched to the power-on state. This on-demand allocation and control method can save the power consumption of the memory and achieve better energy-saving effects.
附图说明Description of drawings
图1是本申请一个实施例提供的包含存储器的片上系统的结构示意图;Figure 1 is a schematic structural diagram of a system-on-chip including a memory provided by an embodiment of the present application;
图2是本申请一个实施例提供的存储器的结构示意图; Figure 2 is a schematic structural diagram of a memory provided by an embodiment of the present application;
图3是本申请一个实施例提供的存储元件组划分的示意图;Figure 3 is a schematic diagram of storage element group division provided by an embodiment of the present application;
图4是本申请另一个实施例提供的存储元件组划分的示意图;Figure 4 is a schematic diagram of storage element group division provided by another embodiment of the present application;
图5是本申请一个实施例提供的存储控制方法的流程图;Figure 5 is a flow chart of a storage control method provided by an embodiment of the present application;
图6是本申请一个实施例提供的存储元件组划分和使用的示意图;Figure 6 is a schematic diagram of the division and use of storage element groups provided by an embodiment of the present application;
图7是本申请一个实施例提供的应用程序类型转换的示意图;Figure 7 is a schematic diagram of application type conversion provided by an embodiment of the present application;
图8是本申请另一个实施例提供的存储控制方法的流程图;Figure 8 is a flow chart of a storage control method provided by another embodiment of the present application;
图9是本申请一个实施例提供的存储控制装置的框图;Figure 9 is a block diagram of a storage control device provided by an embodiment of the present application;
图10是本申请一个实施例提供的终端设备的示意图。Figure 10 is a schematic diagram of a terminal device provided by an embodiment of the present application.
具体实施方式Detailed ways
为使本申请的目的、技术方案和优点更加清楚,下面将结合附图对本申请实施方式作进一步地详细描述。In order to make the purpose, technical solutions and advantages of the present application clearer, the embodiments of the present application will be further described in detail below with reference to the accompanying drawings.
图1是本申请一个示例性实施例提供的包含存储器的片上系统(System on Chip,SoC)的结构示意图。本申请中的片上系统以运用于移动终端,如智能手机、智能手表、电子书阅读器、平板电脑、膝上便携计算机、台式计算机、电视机、游戏机、增强现实(Augmented Reality,AR)终端、虚拟现实(Virtual Reality,VR)终端和混合现实(Mixed Reality,MR)终端、可穿戴式设备等中的至少一种为例进行说明。本实施例中的片上系统100包括:主设备101、主总线103、存储控制器105以及存储器200。Figure 1 is a schematic structural diagram of a system on chip (SoC) including a memory provided by an exemplary embodiment of the present application. The system-on-chip in this application can be used in mobile terminals, such as smartphones, smart watches, e-book readers, tablet computers, laptop computers, desktop computers, televisions, game consoles, and augmented reality (Augmented Reality, AR) terminals. Taking at least one of a virtual reality (Virtual Reality, VR) terminal, a mixed reality (MR) terminal, a wearable device, etc. as an example for explanation. The system-on-chip 100 in this embodiment includes: a main device 101, a main bus 103, a memory controller 105 and a memory 200.
主设备101通过主总线103(Primary Bus)与存储控制器105相连,存储控制器105通过物理层(Physical Layer,PHY)接口与存储器200相连。在一些实施例中,该存储器200为动态随机存取存储器(Dynamic Random Access Memory,DRAM)。可选地,该DRAM采用叠层(Packaging on Packaging,PoP)封装。The main device 101 is connected to the storage controller 105 through the main bus 103 (Primary Bus), and the storage controller 105 is connected to the memory 200 through a physical layer (Physical Layer, PHY) interface. In some embodiments, the memory 200 is a dynamic random access memory (Dynamic Random Access Memory, DRAM). Optionally, the DRAM adopts Packaging on Packaging (PoP) packaging.
主设备101是具有数据读写需求的处理器或者非处理器。主设备可以包括但不限于中央处理器(Central Processing Unit,CPU)、图像处理器(Graphics Processing Unit,GPU)、神经网络处理器(Neural-network Processing Unit,NPU)、数字信号处理器(Digital Signal Processor,DSP)等处理器,以及图像传感器(Image Sensor)、图像信号处理单元(Image Signal Processing Unit,ISP)、视频处理单元(Video Processing Unit,VPU)等非处理器。上述主设备在运行过程中均具有内存数据读和/或写的需求。图1中以处理器包括CPU、GPU和NPU,非处理器 包括图像传感器与VPU为例进行示意性说明,但并不对此构成限定。The master device 101 is a processor or non-processor with data reading and writing requirements. The main device may include, but is not limited to, a central processing unit (CPU), a graphics processor (Graphics Processing Unit, GPU), a neural network processor (Neural-network Processing Unit, NPU), a digital signal processor (Digital Signal) Processors such as Processor (DSP), and non-processors such as Image Sensor (Image Sensor), Image Signal Processing Unit (ISP), and Video Processing Unit (VPU). The above-mentioned main devices all have memory data reading and/or writing requirements during operation. In Figure 1, processors include CPU, GPU and NPU, and non-processors An image sensor and a VPU are taken as examples for schematic explanation, but this does not constitute a limitation.
其中,处理器利用各种接口和线路连接整个终端设备内的各个部分,通过运行或执行存储在存储器内的指令、程序、代码集或指令集,以及调用存储在存储器内的数据,执行终端设备的各种功能和处理数据。Among them, the processor uses various interfaces and lines to connect various parts of the entire terminal device, and executes the terminal device by running or executing instructions, programs, code sets or instruction sets stored in the memory, and calling data stored in the memory. various functions and process data.
在一些实施例中,处理器可以采用数字信号处理(Digital Signal Processing,DSP)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)、可编程逻辑阵列(Programmable Logic Array,PLA)中的至少一种硬件形式来实现。In some embodiments, the processor may adopt at least one of digital signal processing (Digital Signal Processing, DSP), field-programmable gate array (Field-Programmable Gate Array, FPGA), and programmable logic array (Programmable Logic Array, PLA). A form of hardware implementation.
处理器可集成CPU、GPU、NPU和基带芯片等中的一种或几种的组合。其中,CPU主要处理操作系统、用户界面和应用程序等;GPU用于负责显示屏所需要显示的内容的渲染和绘制;NPU用于实现AI(Artificial Intelligence,人工智能)功能;基带芯片用于处理无线通信。The processor can integrate one or a combination of CPU, GPU, NPU and baseband chip. Among them, the CPU mainly handles the operating system, user interface and applications; the GPU is responsible for the rendering and drawing of the content that needs to be displayed on the display; the NPU is used to implement AI (Artificial Intelligence, artificial intelligence) functions; the baseband chip is used for processing Wireless communication.
在一些实施例中,主设备101与主总线103之间,主总线103与存储控制器105之间建立有m条采用AXI(Advanced eXtensible Interface,高级扩展接口)协议的链路。示例性的如图1所示,各个主设备101与主总线103之间,主总线103与存储控制器105之间建立有4条位宽(Width)为256bits的AXI链路。In some embodiments, m links using the AXI (Advanced eXtensible Interface, Advanced Extension Interface) protocol are established between the main device 101 and the main bus 103, and between the main bus 103 and the storage controller 105. As shown in FIG. 1 , four AXI links with a width of 256 bits are established between each master device 101 and the main bus 103, and between the main bus 103 and the memory controller 105.
在一些实施例中,存储控制器105包括从总线(Secondary Bus)、k个控制器(对应k条内存通道)以及各个控制器对应的物理层接口,k为正整数。In some embodiments, the storage controller 105 includes a secondary bus, k controllers (corresponding to k memory channels), and physical layer interfaces corresponding to each controller, where k is a positive integer.
在一些实施例中,从总线与控制器之间建立有采用AXI协议的链路,且在从总线处实现分路功能。比如,经过从总线分路后(k条分路为n条,n为正整数),从总线与控制器之间建立有8条位宽为128bits的AXI链路。相应的,存储控制器105与存储器200之间建立8条位宽为128bits的AXI链路。In some embodiments, a link using the AXI protocol is established between the slave bus and the controller, and the branching function is implemented at the slave bus. For example, after the slave bus is branched (k branches are n branches, n is a positive integer), 8 AXI links with a bit width of 128 bits are established between the slave bus and the controller. Correspondingly, eight AXI links with a bit width of 128 bits are established between the memory controller 105 and the memory 200 .
存储器200是支持n(n>k)条内存通道的存储器,且存储器200中的n个存储元件分别具备工作总线,即各个存储元件的工作总线通过并发方式与存储控制器105相连。The memory 200 is a memory that supports n (n>k) memory channels, and the n storage elements in the memory 200 each have a working bus, that is, the working bus of each storage element is connected to the storage controller 105 in a concurrent manner.
图1以片上系统中集成有存储器(即存储器设置在片上系统内部)为例进行说明,在其他可能的设计中,存储器可以设置在片上系统外部,本申请实施例对此不作限定。Figure 1 takes a system on a chip that integrates a memory (that is, the memory is arranged inside the system on a chip) as an example. In other possible designs, the memory can be arranged outside the system on a chip. This is not limited in the embodiments of the present application.
图2是本申请一个示例性实施例提供的存储器的结构示意图。 Figure 2 is a schematic structural diagram of a memory provided by an exemplary embodiment of the present application.
存储器200包括n个存储元件201,n为大于1的整数。在一些实施例中,该存储器200为DRAM,该存储元件201为存储晶片(Die)。可选地,该DRAM采用TOP封装。本申请实施例并不对存储器200以及存储元件201的具体类型进行限定。The memory 200 includes n storage elements 201, where n is an integer greater than 1. In some embodiments, the memory 200 is a DRAM, and the storage element 201 is a memory die. Optionally, the DRAM is packaged in TOP. The embodiment of the present application does not limit the specific types of the memory 200 and the storage element 201.
在一些实施例中,存储元件201的内部颗粒可以采用2D(Two Dimensional,二维)方式排列或者3D(Three Dimensional,三维)方式排列。其中,3D方式排列可以采用简单堆叠(Simple Stack)、垂直沟道(Vertical Channel,VC)或者垂直栅极(Vertical Grid,VG)等方式。In some embodiments, the internal particles of the storage element 201 may be arranged in a 2D (Two Dimensional, two-dimensional) manner or a 3D (Three Dimensional, three-dimensional) manner. Among them, the 3D arrangement can adopt simple stack (Simple Stack), vertical channel (Vertical Channel, VC) or vertical gate (Vertical Grid, VG) and other methods.
在一些实施例中,各个存储元件201的元件参数(比如容量)相同,比如,各个存储元件201均为16Gb×16数据位宽(Datawidth)的规格。在另一些实施例中,部分存储元件的元件参数相同,部分存储元件的元件参数不同,或者,不同存储元件的元件参数不同,本申请实施例并不对各个存储元件的具体元件参数进行限定。In some embodiments, the element parameters (such as capacity) of each storage element 201 are the same. For example, each storage element 201 has a specification of 16Gb×16 data width (Datawidth). In other embodiments, some storage elements have the same component parameters, some storage components have different component parameters, or different storage components have different component parameters. The embodiments of this application do not limit the specific component parameters of each storage component.
n个存储元件201被封装成一个存储颗粒,比如采用POP封装的DRAM器件。在一些可能的设计中,n个存储元件201采用2D封装或者3D封装,本申请实施例并不对具体封装方式进行限定。n storage elements 201 are packaged into a storage particle, such as a DRAM device using POP packaging. In some possible designs, the n storage elements 201 adopt 2D packaging or 3D packaging. The embodiments of this application do not limit the specific packaging method.
本申请实施例中的存储器200支持n条的内存通道,因此存储器200中的存储元件201的数量等于n,且不同存储元件201分别对应各自的内存通道,即n个存储元件对应n条内存通道。比如,对于支持8条内存通道的存储器,该存储器中设置有8个存储元件;对于支持6条内存通道的存储器,该存储器中设置有6个存储元件。本申请实施例并不对存储元件的具体数量(正整数即可,可以为偶数,也可以为奇数)进行限定。The memory 200 in the embodiment of the present application supports n memory channels, so the number of storage elements 201 in the memory 200 is equal to n, and different storage elements 201 correspond to respective memory channels, that is, n storage elements correspond to n memory channels. . For example, for a memory that supports 8 memory channels, 8 storage elements are provided in the memory; for a memory that supports 6 memory channels, 6 storage elements are provided with the memory. The embodiments of the present application do not limit the specific number of storage elements (a positive integer is sufficient, and it can be an even number or an odd number).
在一些实施例中,存储器200包括:m个存储元件组,每个存储元件组包括至少一个存储元件201,m为大于1的整数。也就是说,存储器200包括的n个存储元件201被划分为m个存储元件组,一个存储元件组中可以有且仅有一个存储元件201,也可以包括多个(两个或两个以上)存储元件201。In some embodiments, the memory 200 includes: m storage element groups, each storage element group includes at least one storage element 201, and m is an integer greater than 1. That is to say, the n storage elements 201 included in the memory 200 are divided into m storage element groups. One storage element group may have one and only one storage element 201, or may include multiple (two or more) storage elements 201. Storage element 201.
在一些实施例中,对于上述m个存储元件组,各个存储元件组中包含的存储元件201的数量相同。In some embodiments, for the above m storage element groups, the number of storage elements 201 included in each storage element group is the same.
示例性地,如图3所示,存储器200包括8个存储元件201,该8个存储元件201被划分为2个存储元件组,记为第一存储元件组和第二存储元件组,每 个存储元件组包括4个存储元件201。在图3中,第一存储元件组包括内存通道A、B、C和D分别对应的存储元件201,第二存储元件组包括内存通道E、F、G和H分别对应的存储元件201。For example, as shown in Figure 3, the memory 200 includes 8 storage elements 201, which are divided into 2 storage element groups, denoted as a first storage element group and a second storage element group, each A storage element group includes four storage elements 201. In FIG. 3 , the first storage element group includes storage elements 201 corresponding to memory channels A, B, C and D respectively, and the second storage element group includes storage elements 201 corresponding to memory channels E, F, G and H respectively.
又例如,存储器200包括8个存储元件201,该8个存储元件201被划分为4个存储元件组,每个存储元件组包括2个存储元件201。或者,每个存储元件组包括一个存储元件201,存储器200包括8个存储元件201,该8个存储元件201被划分为8个存储元件组。在本申请实施例中,在各个存储元件组中包含的存储元件201的数量相同的情况下,对各个存储元件组中包含的存储元件201的数量不作限定,这可以结合实际需求进行灵活设定。For another example, the memory 200 includes 8 storage elements 201, and the 8 storage elements 201 are divided into 4 storage element groups, and each storage element group includes 2 storage elements 201. Alternatively, each storage element group includes one storage element 201, and the memory 200 includes 8 storage elements 201, and the 8 storage elements 201 are divided into 8 storage element groups. In the embodiment of the present application, when the number of storage elements 201 included in each storage element group is the same, there is no limit to the number of storage elements 201 included in each storage element group, which can be flexibly set according to actual needs. .
在一些实施例中,对于上述m个存储元件组,存在至少两个存储元件组中包含的存储元件201的数量不同。In some embodiments, for the above-mentioned m storage element groups, there are at least two storage element groups that contain different numbers of storage elements 201 .
示例性地,如图4所示,存储器200包括6个存储元件201,该6个存储元件201被划分为2个存储元件组,记为第一存储元件组和第二存储元件组,第一存储元件组包括2个存储元件201,第二存储元件组包括4个存储元件201。在图4中,第一存储元件组包括内存通道A和B分别对应的存储元件201,第二存储元件组包括内存通道C、D、E和F分别对应的存储元件201。For example, as shown in Figure 4, the memory 200 includes 6 storage elements 201. The 6 storage elements 201 are divided into 2 storage element groups, denoted as a first storage element group and a second storage element group. The first The storage element group includes 2 storage elements 201, and the second storage element group includes 4 storage elements 201. In FIG. 4 , the first storage element group includes storage elements 201 corresponding to memory channels A and B respectively, and the second storage element group includes storage elements 201 corresponding to memory channels C, D, E and F respectively.
又例如,存储器200包括8个存储元件201,该8个存储元件201被划分为3个存储元件组,记为第一存储元件组、第二存储元件组和第三存储元件组;其中,第一存储元件组包括2个存储元件201,第二存储元件组包括2个存储元件201,第三存储元件组包括4个存储元件201。在本申请实施例中,在存在至少两个存储元件组中包含的存储元件201的数量不同的情况下,对各个存储元件组中包含的存储元件201的数量不作限定,这可以结合实际需求进行灵活设定。For another example, the memory 200 includes 8 storage elements 201, and the 8 storage elements 201 are divided into 3 storage element groups, denoted as the first storage element group, the second storage element group and the third storage element group; wherein, the One storage element group includes two storage elements 201 , a second storage element group includes two storage elements 201 , and a third storage element group includes four storage elements 201 . In the embodiment of the present application, in the case where the number of storage elements 201 included in at least two storage element groups is different, the number of storage elements 201 included in each storage element group is not limited, and this can be done in accordance with actual needs. Flexible settings.
当然,上文实施例仅是示例性给出了几种存储元件组的划分方式,本申请对存储器200中包含的存储元件组的数量,以及每个存储元件组中包含的存储元件201的数量不作限定,这可以结合实际需求进行设计和划分。Of course, the above embodiments are only examples of how to divide several storage element groups. This application specifies the number of storage element groups included in the memory 200 and the number of storage elements 201 included in each storage element group. There is no limit, this can be designed and divided according to actual needs.
图5是本申请一个实施例提供的存储控制方法的流程图。该方法可以由控制电路执行。控制电路用于对存储器进行控制,例如控制存储器中各个存储元件或存储元件组的上电或下电状态。控制电路可以是任意形式的处理器、控制器、微处理器或者具备数据处理能力的集成电路芯片,本申请对控制电路的实现形 式不作限定。在一些实施例中,控制电路可以设置在存储器内部,控制电路也可以设置在存储器对应的电源管理芯片(该电源管理芯片用于为存储器提供输入电压)内部,控制电路还可以设置在用于承载存储器和/或电源管理芯片的电路板上,本申请对控制电路的设置位置也不作限定。该方法可以包括如下步骤510:Figure 5 is a flow chart of a storage control method provided by an embodiment of the present application. The method can be performed by a control circuit. The control circuit is used to control the memory, such as controlling the power-on or power-off state of each storage element or storage element group in the memory. The control circuit can be any form of processor, controller, microprocessor or integrated circuit chip with data processing capabilities. This application describes the implementation form of the control circuit. The formula is not limited. In some embodiments, the control circuit may be provided inside the memory. The control circuit may also be provided inside the power management chip corresponding to the memory (the power management chip is used to provide input voltage for the memory). The control circuit may also be provided inside the memory chip for carrying the memory. This application does not limit the location of the control circuit on the circuit board of the memory and/or power management chip. The method may include the following steps 510:
步骤510,基于存储器从第一工作模式切换至第二工作模式,控制存储器的第二存储元件组从下电状态切换到上电状态;其中,存储器包括配置成存储第一类型数据的第一存储元件组和配置成存储第二类型数据的第二存储元件组。Step 510: Based on the memory switching from the first operating mode to the second operating mode, control the second storage element group of the memory to switch from the power-off state to the power-on state; wherein the memory includes a first storage configured to store the first type of data. A group of elements and a second group of storage elements configured to store data of a second type.
在本申请实施例中,存储器包括多个存储元件组,每个存储元件组包括至少一个存储元件。有关存储器的介绍说明,可参见上文实施例,本实施例对此不再赘述。In this embodiment of the present application, the memory includes multiple storage element groups, and each storage element group includes at least one storage element. For an introduction to the memory, please refer to the above embodiment, which will not be described again in this embodiment.
第一存储元件组和第二存储元件组是不同的存储元件组。示例性地,如图6所示,存储器包括2个存储元件组,第一存储元件组61是该2个存储元件组中的一个存储元件组,第二存储元件组62是该2个存储元件组中的另一个存储元件组。示例性地,存储器包括3个或者3个以上的存储元件组,第一存储元件组是该3个或者3个以上的存储元件组中的至少一个存储元件组,第二存储元件组是该3个或者3个以上的存储元件组中的至少一个存储元件组,且第二存储元件组和第一存储元件组中不存在相同的存储元件组。例如,第一存储元件组是该3个或者3个以上的存储元件组中的至少一个存储元件组,第二存储元件组是该3个或者3个以上的存储元件组中除第一存储元件组之外剩余的存储元件组。The first storage element group and the second storage element group are different storage element groups. Exemplarily, as shown in Figure 6, the memory includes two storage element groups, the first storage element group 61 is one of the two storage element groups, and the second storage element group 62 is the two storage element groups. Another storage element group within the group. Exemplarily, the memory includes 3 or more storage element groups, the first storage element group is at least one storage element group among the 3 or more storage element groups, and the second storage element group is the 3 or more storage element groups. At least one storage element group among three or more storage element groups, and the second storage element group and the first storage element group do not have the same storage element group. For example, the first storage element group is at least one storage element group among the 3 or more storage element groups, and the second storage element group is the 3 or more storage element groups except the first storage element group. The remaining storage element groups outside the group.
在本申请实施例中,某一个存储元件组处于上电状态,是指通过存储器的电源管理芯片给该存储元件组中的各个存储元件提供输入电压,使得该存储元件组中的各个存储元件能够正常工作用于存储数据的状态。某一个存储元件组处于下电状态,是指通过存储器的电源管理芯片不给该存储元件组中的各个存储元件提供输入电压,使得该存储元件组中的各个存储元件不接收输入电压进行工作的状态。处于上电状态的存储元件组能够用于存储数据,而处于下电状态的存储元件组则无法用于存储数据。In the embodiment of the present application, a certain storage element group is in a powered-on state, which means that the power management chip of the memory provides an input voltage to each storage element in the storage element group, so that each storage element in the storage element group can Normal work is used to store the state of data. A certain storage element group is in a power-off state, which means that the power management chip of the memory does not provide input voltage to each storage element in the storage element group, so that each storage element in the storage element group does not receive input voltage to work. state. The storage element group in the powered-on state can be used to store data, while the storage element group in the powered-off state cannot be used to store data.
在一些实施例中,在存储器的第一工作模式下,控制第一存储元件组处于上电状态,以及控制第二存储元件组处于下电状态。在第一工作模式下,由于仅有第一类型的数据需要存储,而该第一类型的数据是由第一存储元件组进行存储 的,因此控制存储器的第一存储元件组处于上电状态,以及控制存储器的第二存储元件组处于下电状态。在第一存储元件组处于上电状态的情况下,存储器的电源管理芯片给第一存储元件组中的各个存储元件提供输入电压,使得第一存储元件组能够正常工作,用于存储第一类型的数据。与此同时,由于仅有第一类型的数据需要存储,并没有需要第二存储元件组进行存储的数据,因此控制第二存储元件组处于下电状态,即存储器的电源管理芯片不给第二存储元件组中的各个存储元件提供输入电压,使得第二存储元件组断电不工作,从而节省电量。In some embodiments, in the first operating mode of the memory, the first storage element group is controlled to be in a power-on state, and the second storage element group is controlled to be in a power-down state. In the first working mode, since only the first type of data needs to be stored, and the first type of data is stored by the first storage element group , so the first storage element group of the control memory is in the powered-on state, and the second storage element group of the control memory is in the powered-off state. When the first storage element group is in a powered-on state, the power management chip of the memory provides an input voltage to each storage element in the first storage element group, so that the first storage element group can operate normally and is used to store the first type of storage element. The data. At the same time, since only the first type of data needs to be stored and there is no data that needs to be stored by the second storage element group, the second storage element group is controlled to be in a power-off state, that is, the power management chip of the memory does not provide power to the second storage element group. Each storage element in the storage element group provides an input voltage, so that the second storage element group does not work when powered off, thereby saving power.
在第二工作模式下,由于有第二类型的数据需要存储,而该第二类型的数据是由第二存储元件组进行存储的,因此在存储器从第一工作模式切换至第二工作模式的情况下,需要控制存储器的第二存储元件组从下电状态切换到上电状态。例如,控制存储器的电源管理芯片给第二存储元件组中的各个存储元件提供输入电压,使得第二存储元件组能够正常工作,用于存储第二类型的数据。In the second working mode, since there is a second type of data that needs to be stored, and the second type of data is stored by the second storage element group, when the memory switches from the first working mode to the second working mode In this case, it is necessary to control the second storage element group of the memory to switch from the power-off state to the power-on state. For example, the power management chip of the control memory provides an input voltage to each storage element in the second storage element group, so that the second storage element group can operate normally and is used to store the second type of data.
可选地,在从第一工作模式切换至第二工作模式的情况下,控制第一存储元件组保持上电状态,即不论处于第一工作模式还是第二工作模式,第一存储元件组始终处于上电状态,提供必要的存储区域。通过控制第一存储元件组始终处于上电状态,确保使用第一存储元件组的应用程序能够高效地使用该存储区域。Optionally, when switching from the first operating mode to the second operating mode, the first storage element group is controlled to remain powered on, that is, the first storage element group is always powered on regardless of whether it is in the first operating mode or the second operating mode. Is powered on and provides the necessary storage area. By controlling the first storage element group to always be in a powered-on state, it is ensured that an application program using the first storage element group can efficiently use the storage area.
在本申请实施例中,第二类型的数据和第一类型的数据不同,也即第一类型的数据和第二类型的数据是两种不同类型的数据。在本申请实施例中,对数据类型的划分方式不作限定,例如可以根据数据的来源(如数据的产生方或提供方)进行类型划分。In this embodiment of the present application, the second type of data is different from the first type of data, that is, the first type of data and the second type of data are two different types of data. In the embodiment of the present application, the method of classifying data types is not limited. For example, the types can be classified according to the source of the data (such as the data producer or provider).
在一些实施例中,不同类型的数据,是基于产生数据的应用程序是否属于目标类型来划分的。可选地,第一工作模式下不存在目标类型的应用程序运行,第二工作模式下存在目标类型的应用程序运行,第二类型的数据包括目标类型的应用程序对应的数据。可选地,基于确定目标类型的应用程序运行,控制存储器切换至第二工作模式。示例性地,在不存在目标类型的应用程序运行的情况下,确定存储器在第一工作模式下进行工作,控制存储器的第一存储元件组处于上电状态,以及控制存储器的第二存储元件组处于下电状态;在存在目标类型的应用程序运行的情况下,确定存储器在第二工作模式下进行工作,控制存储器的第一存储元件组和第二存储元件组均处于上电状态。In some embodiments, different types of data are divided based on whether the application that generates the data belongs to the target type. Optionally, there is no application program of the target type running in the first working mode, there is an application program running of the target type in the second working mode, and the second type of data includes data corresponding to the application program of the target type. Optionally, based on determining the target type of application program execution, the control memory switches to the second working mode. Exemplarily, in the absence of an application program of the target type running, it is determined that the memory operates in a first operating mode, the first storage element group of the memory is controlled to be in a powered-on state, and the second storage element group of the memory is controlled In the power-off state; when there is an application program of the target type running, it is determined that the memory operates in the second working mode, and the first storage element group and the second storage element group of the control memory are both in the power-on state.
在一些实施例中,第二类型的数据包括目标类型的应用程序对应的数据,第 一类型的数据包括除目标类型的应用程序之外的其他应用程序对应的数据。示例性地,将终端设备的应用程序划分为普通应用程序(Normal Usage APP)和高性能应用程序(Performance Usage APP),目标类型的应用程序为高性能应用程序,除目标类型的应用程序之外的其他应用程序则为普通应用程序。示例性地,如图6所示,第一存储元件组61供普通应用程序使用,第二存储元件组62供高性能应用程序使用。可选地,第一存储元件组61还用于提供默认内核空间和预留空间,供内核和一些特殊情况下的存储需求所使用。In some embodiments, the second type of data includes data corresponding to the target type of application, and the first One type of data includes data corresponding to applications other than the target type application. For example, the applications of the terminal device are divided into normal applications (Normal Usage APP) and high-performance applications (Performance Usage APP). The target type of applications is high-performance applications, except for the target type of applications. The other apps are normal apps. For example, as shown in FIG. 6 , the first storage element group 61 is used by ordinary applications, and the second storage element group 62 is used by high-performance applications. Optionally, the first storage element group 61 is also used to provide default kernel space and reserved space for use by the kernel and storage requirements under some special circumstances.
需要说明的是,目标类型的应用程序可以是固定设定的,也即不会动态改变的。或者,目标类型的应用程序也可以是动态确定的,也即是可以动态改变的,例如,一个应用程序可以从属于目标类型变为不属于目标类型,或者从不属于目标类型变为属于目标类型。有关动态地确定目标类型的应用程序的方式,可参见下文实施例中的介绍说明。It should be noted that the target type of application can be fixed, that is, it will not change dynamically. Alternatively, the target type of application can also be dynamically determined, that is, it can be dynamically changed. For example, an application can change from belonging to the target type to not belonging to the target type, or from not belonging to the target type to belonging to the target type. . For the method of dynamically determining the application program of the target type, please refer to the introduction in the embodiment below.
在一些实施例中,将第二工作模式下产生的第二类型数据存储于第二存储元件组。第一存储元件组不用于存储第二工作模式下产生的第二类型的数据。也就是说,第一存储元件组仅用于存储第一类型的数据,第二类型的数据只能够通过第二存储元件组进行存储,无法通过第一存储元件组进行存储。这样,实现了不同工作模式下不同类型数据存储的隔离,有助于提升数据存储的安全性和可靠性。In some embodiments, the second type of data generated in the second operating mode is stored in the second storage element group. The first storage element group is not used to store the second type of data generated in the second operating mode. That is to say, the first storage element group is only used to store the first type of data, and the second type of data can only be stored through the second storage element group and cannot be stored through the first storage element group. In this way, the isolation of different types of data storage in different working modes is achieved, which helps to improve the security and reliability of data storage.
在一些实施例中,存储器包括的各个存储元件组的工作频率可以统一控制,也可以分别独立控制。上述工作频率也可以称为工作速率。存储元件组的工作频率是指该存储元件组的时钟频率,或者也可以是该存储元件组的数据读写频率,上述时钟频率和数据读写频率也有关联,时钟频率和数据读写频率呈正相关关系。各个存储元件组的工作频率统一控制,是指根据统一的参数指标对各个存储元件组的工作频率进行统一控制,各个存储元件组的工作频率相同。各个存储元件组的工作频率分别独立控制,是指根据每一个存储元件组的参数指标对该存储元件组的工作频率进行独立控制,各个存储元件组的工作频率有可能相同,也有可能不同,实现各个存储元件组的工作频率之间的解耦,更具灵活性。In some embodiments, the operating frequencies of various storage element groups included in the memory can be controlled uniformly or independently. The above operating frequency can also be called the operating rate. The operating frequency of the storage element group refers to the clock frequency of the storage element group, or it can also be the data reading and writing frequency of the storage element group. The above clock frequency is also related to the data reading and writing frequency. The clock frequency and the data reading and writing frequency are positively correlated. relation. Unified control of the operating frequencies of each storage element group refers to unified control of the operating frequencies of each storage element group based on unified parameter indicators, and the operating frequencies of each storage element group are the same. The operating frequency of each storage element group is independently controlled, which means that the operating frequency of each storage element group is independently controlled according to the parameter index of each storage element group. The operating frequency of each storage element group may be the same or different. Implementation Decoupling between the operating frequencies of each storage element group provides greater flexibility.
示例性地,第一存储元件组的工作频率和第二存储元件组的工作频率分别独立控制。或者说,分别独立地控制第一存储元件组的工作频率和第二存储元件组的工作频率。例如,在第一存储元件组处于上电状态下,根据该第一存储元件 组的参数指标确定该第一存储元件组的工作频率(记为第一工作频率),控制该第一存储元件组按照第一工作频率进行工作。在第二存储元件组处于上电状态下,根据该第二存储元件组的参数指标确定该第二存储元件组的工作频率(记为第二工作频率),控制该第二存储元件组按照第二工作频率进行工作。上述第一工作频率和第二工作频率有可能相同,也有可能不同,从而实现独立控制。另外,上述用于确定工作频率的参数指标可以是负载参数,负载参数也可称为带宽参数,存储元件组的负载参数是指在单位时间内对该存储元件组的访问量。可选地,存储元件组的工作频率和负载参数呈正相关关系,也即负载参数越大,工作频率越大,反之,负载参数越小,工作频率越小。例如,如果第一存储元件组和第二存储元件组均处于上电状态,假设第一存储元件组的负载参数大于第二存储元件组的负载参数,那么可以控制该第一存储元件组的工作频率(也即第一工作频率)大于第二存储元件组的工作频率(也即第二工作频率);假设第一存储元件组的负载参数小于第二存储元件组的负载参数,那么可以控制该第一存储元件组的工作频率(也即第一工作频率)小于第二存储元件组的工作频率(也即第二工作频率);假设第一存储元件组的负载参数等于第二存储元件组的负载参数,那么可以控制该第一存储元件组的工作频率(也即第一工作频率)和第二存储元件组的工作频率(也即第二工作频率)相等。通过上述方式,将不同存储元件组的工作频率进行解耦式的独立控制,并根据各个存储元件组的负载参数确定该存储元件组的工作频率,能够实现依据存储元件组的实际访问量需求来合理设置工作频率,有助于进一步提升节能效果。Exemplarily, the operating frequency of the first storage element group and the operating frequency of the second storage element group are independently controlled. In other words, the operating frequency of the first storage element group and the operating frequency of the second storage element group are controlled independently. For example, when the first storage element group is in a powered-on state, according to the first storage element The parameter index of the group determines the operating frequency of the first storage element group (recorded as the first operating frequency), and controls the first storage element group to operate according to the first operating frequency. When the second storage element group is in the powered-on state, the operating frequency of the second storage element group (denoted as the second operating frequency) is determined according to the parameter index of the second storage element group, and the second storage element group is controlled according to the second operating frequency. Work at two operating frequencies. The above-mentioned first operating frequency and the second operating frequency may be the same or different, thereby achieving independent control. In addition, the above-mentioned parameter index used to determine the operating frequency may be a load parameter, which may also be called a bandwidth parameter. The load parameter of a storage element group refers to the amount of access to the storage element group within a unit time. Optionally, there is a positive correlation between the operating frequency of the storage element group and the load parameter, that is, the greater the load parameter, the greater the operating frequency, and conversely, the smaller the load parameter, the smaller the operating frequency. For example, if both the first storage element group and the second storage element group are in a powered-on state, assuming that the load parameter of the first storage element group is greater than the load parameter of the second storage element group, then the operation of the first storage element group can be controlled. The frequency (that is, the first operating frequency) is greater than the operating frequency of the second storage element group (that is, the second operating frequency); assuming that the load parameter of the first storage element group is smaller than the load parameter of the second storage element group, then the The operating frequency of the first storage element group (that is, the first operating frequency) is smaller than the operating frequency of the second storage element group (that is, the second operating frequency); assuming that the load parameter of the first storage element group is equal to the load parameter of the second storage element group Load parameters, then the operating frequency of the first storage element group (that is, the first operating frequency) and the operating frequency of the second storage element group (that is, the second operating frequency) can be controlled to be equal. Through the above method, the operating frequencies of different storage element groups are decoupled and independently controlled, and the operating frequency of each storage element group is determined according to the load parameters of each storage element group, which can realize the actual access requirements of the storage element group. Properly setting the operating frequency will help further improve energy saving effects.
在本申请实施例中,通过将存储器划分为多个存储元件组(如至少包括第一存储元件组和第二存储元件组),不同的存储元件组用于存储不同类型的数据,从而能够实现存储元件组的按需使用,例如在没有某一存储元件组对应的数据需要存储时,则可以控制该存储元件组处于下电状态,在有需要该存储元件组对应的数据需要存储时,再控制该存储元件组从下电状态切换至上电状态,这种按需分配和控制的方式,能够节省存储器的电量消耗,达到较好的节能效果。In the embodiment of the present application, by dividing the memory into multiple storage element groups (for example, including at least a first storage element group and a second storage element group), different storage element groups are used to store different types of data, so that it can be achieved On-demand use of storage element groups. For example, when there is no data corresponding to a certain storage element group that needs to be stored, the storage element group can be controlled to be in a power-off state. When there is need to store data corresponding to the storage element group, the storage element group can be controlled to power off. Controlling the storage element group to switch from the power-off state to the power-on state, this on-demand allocation and control method can save the power consumption of the memory and achieve a better energy-saving effect.
下面,对动态地确定目标类型的应用程序进行介绍说明。Next, an application that dynamically determines the target type is introduced.
在一些实施例中,获取终端设备中的至少一个应用程序的历史运行数据,根据各个应用程序的历史运行数据,从各个应用程序中确定目标类型的应用程序。 In some embodiments, historical running data of at least one application program in the terminal device is obtained, and a target type of application program is determined from each application program based on the historical running data of each application program.
应用程序的历史运行数据用于记录该应用程序的历史运行情况。可选地,应用程序的历史运行数据包括但不限于以下至少之一:历史的存储空间用量、历史的电量消耗、历史的使用频率、历史的CPU占用率。其中,历史的存储空间用量用于反映该应用程序对存储空间的需求量,例如可以统计应用程序在最近一段时间内运行时对存储空间的使用量来得到该指标。历史的电量消耗用于反映该应用程序对电池电量的消耗量,例如可以统计应用程序在最近一段时间内运行时对电池电量的消耗量来得到该指标。历史的使用频率用于反映用户对该应用程序的使用频繁度,例如可以统计应用程序在最近一段时间内的运行次数和/或运行时长来得到该指标。历史的CPU占用率用于反映该应用程序对CPU处理资源的占用情况,例如可以统计应用程序在最近一段时间内运行时对CPU的占用率来得到该指标。上述各项指标均能够反映出应用程序的性能需求,例如历史的存储空间用量越大、历史的电量消耗越大、历史的使用频率越大、历史的CPU占用率越大,则说明该应用程序的性能需求越高。因此,通过根据上述各项指标,可以从性能需求的角度对应用程序是否属于目标类型进行划分,得到属于目标类型的应用程序(如高性能应用程序),和不属于目标类型的应用程序(如普通应用程序)。其中,属于目标类型的应用程序(如高性能应用程序)的性能需求,大于不属于目标类型的应用程序(如普通应用程序)。The historical running data of the application is used to record the historical running status of the application. Optionally, the historical running data of the application includes but is not limited to at least one of the following: historical storage space usage, historical power consumption, historical usage frequency, and historical CPU usage. Among them, the historical storage space usage is used to reflect the application's demand for storage space. For example, the indicator can be obtained by counting the storage space usage when the application is running in the recent period. Historical power consumption is used to reflect the battery power consumption of the application. For example, this indicator can be obtained by counting the battery power consumption of the application during the recent period of operation. The historical usage frequency is used to reflect the user's frequency of use of the application. For example, the indicator can be obtained by counting the number of times and/or the running time of the application in the recent period. The historical CPU usage is used to reflect the application's usage of CPU processing resources. For example, this indicator can be obtained by counting the CPU usage of the application when it was running in the recent period. Each of the above indicators can reflect the performance requirements of the application. For example, the greater the historical storage space usage, the greater the historical power consumption, the greater the historical frequency of use, and the greater the historical CPU usage, the greater the historical CPU usage. The higher the performance requirements. Therefore, based on the above indicators, we can classify whether the application belongs to the target type from the perspective of performance requirements, and obtain the applications that belong to the target type (such as high-performance applications) and the applications that do not belong to the target type (such as common applications). Among them, the performance requirements of applications belonging to the target type (such as high-performance applications) are greater than those of applications that do not belong to the target type (such as ordinary applications).
另外,上述最近一段时间是指从当前时刻开始往前倒推的一段时间,该最近一段时间的时长可以结合实际需求进行合理设定,如1个月、1星期、1天、1小时等,本申请对此不作限定。In addition, the above-mentioned latest period of time refers to a period of time starting from the current moment and working backwards. The length of the latest period of time can be reasonably set based on actual needs, such as 1 month, 1 week, 1 day, 1 hour, etc. This application does not limit this.
在一些实施例中,在历史运行数据仅包括一项指标的情况下,可以设置该指标对应的阈值,如果应用程序的该指标大于(或小于)阈值则确定该应用程序属于目标类型,反之,如果应用程序的该指标小于(或大于)阈值则确定该应用程序不属于目标类型。以指标为历史的存储空间用量为例,如果应用程序的历史的存储空间用量大于阈值则确定该应用程序属于目标类型,反之,如果应用程序的历史的存储空间用量小于阈值则确定该应用程序不属于目标类型。In some embodiments, when the historical operating data only includes one indicator, a threshold corresponding to the indicator can be set. If the indicator of the application is greater than (or less than) the threshold, it is determined that the application belongs to the target type, and vice versa. If the indicator of an application is less than (or greater than) the threshold, it is determined that the application does not belong to the target type. Taking the indicator as historical storage space usage as an example, if the historical storage space usage of an application is greater than the threshold, it is determined that the application belongs to the target type. On the contrary, if the historical storage space usage of the application is less than the threshold, it is determined that the application does not belong to the target type. Belongs to target type.
在一些实施例中,在历史运行数据仅包括多项指标的情况下,可以根据该多项指标计算出一个综合指标,并设置该综合指标对应的阈值。其中,综合指标反映了上述多项指标的整体情况。如果应用程序的该综合指标大于(或小于)阈值则确定该应用程序属于目标类型,反之,如果应用程序的该综合指标小于(或大 于)阈值则确定该应用程序不属于目标类型。以历史运行数据包括历史的存储空间用量、历史的电量消耗、历史的使用频率、历史的CPU占用率为例,对于每一个应用程序,根据该应用程序的历史的存储空间用量、历史的电量消耗、历史的使用频率、历史的CPU占用率,计算得到该应用程序的综合指标,如果该应用程序的综合指标大于阈值则确定该应用程序属于目标类型,反之,如果该应用程序的综合指标小于阈值则确定该应用程序不属于目标类型。可选地,上述计算综合指标的方式,可以是对多个指标进行加权平均或者加权求和得到综合指标,也可以是将多个指标输入神经网络模型,通过神经网络模型输出综合指标,或者采用其他的计算方式,本申请对此不作限定。In some embodiments, when the historical operating data only includes multiple indicators, a comprehensive indicator can be calculated based on the multiple indicators, and a threshold corresponding to the comprehensive indicator can be set. Among them, the comprehensive indicator reflects the overall situation of the above-mentioned indicators. If the comprehensive indicator of the application is greater than (or less than) the threshold, it is determined that the application belongs to the target type. On the contrary, if the comprehensive indicator of the application is less than (or greater than) >) threshold determines that the application does not belong to the target type. Take historical operating data including historical storage space usage, historical power consumption, historical usage frequency, and historical CPU usage as an example. For each application, based on the application’s historical storage space usage and historical power consumption , historical usage frequency, historical CPU usage, calculate the comprehensive indicator of the application. If the comprehensive indicator of the application is greater than the threshold, it is determined that the application belongs to the target type. On the contrary, if the comprehensive indicator of the application is less than the threshold It is determined that the application does not belong to the target type. Optionally, the above method of calculating the comprehensive index can be to perform a weighted average or weighted sum of multiple indicators to obtain a comprehensive index, or to input multiple indicators into a neural network model and output the comprehensive index through the neural network model, or to use This application does not limit other calculation methods.
示例性地,如图7所示,应用程序分为两大类,包括高性能应用程序和普通应用程序。存储器包括第一存储元件组和第二存储元件组,普通应用程序的数据采用第一存储元件组进行存储,高性能应用程序的数据采用第二存储元件组进行存储。其中,第一存储元件组无法用于存储高性能应用程序的数据,第二存储元件组也不会用于存储普通应用程序的数据,从而使得两类应用程序的数据互相隔离。对于任意一个应用程序来说,其属于高性能应用程序还是普通应用程序,可以动态确定和调整。例如,获取该应用程序的历史运行数据,根据该应用程序的历史运行数据确定该应用程序是属于高性能应用程序还是普通应用程序。Illustratively, as shown in Figure 7, applications are divided into two major categories, including high-performance applications and ordinary applications. The memory includes a first storage element group and a second storage element group. Data of ordinary application programs are stored in the first storage element group, and data of high-performance application programs are stored in the second storage element group. Among them, the first storage element group cannot be used to store data of high-performance applications, and the second storage element group cannot be used to store data of ordinary applications, so that the data of the two types of applications are isolated from each other. For any application, whether it is a high-performance application or a normal application can be determined and adjusted dynamically. For example, the historical running data of the application is obtained, and whether the application is a high-performance application or a normal application is determined based on the historical running data of the application.
在一些实施例中,可以采用切换策略结合终端设备中各个应用程序的历史运行数据,从各个应用程序中确定属于目标类型的应用程序。其中,切换策略是指用于确定应用程序是否属于目标类型的策略。示例性地,切换策略可以是基于马尔科夫链的动态选择策略,或者其他动态选择策略,本申请对此不作限定。In some embodiments, a switching strategy may be used in combination with historical running data of each application in the terminal device to determine the application belonging to the target type from each application. Among them, the switching policy refers to the policy used to determine whether the application belongs to the target type. For example, the switching strategy may be a dynamic selection strategy based on Markov chain, or other dynamic selection strategies, which is not limited in this application.
在本申请实施例中,通过动态确定应用程序是否属于目标类型,从而使得应用程序和存储元件组之间的使用关系并不是一成不变的,在应用程序属于目标类型时,其使用第二存储元件组进行数据存储,在应用程序不属于目标类型时,其使用第一存储元件组进行数据存储,且应用程序是否属于目标类型,可以随着用户在近期对该应用程序的使用情况而动态切换,提升了内存使用的灵活性,以及内存分配的合理性。In the embodiment of the present application, by dynamically determining whether the application program belongs to the target type, the usage relationship between the application program and the storage element group is not static. When the application program belongs to the target type, it uses the second storage element group. For data storage, when the application does not belong to the target type, it uses the first storage element group for data storage, and whether the application belongs to the target type can be dynamically switched according to the user's recent usage of the application, improving It improves the flexibility of memory usage and the rationality of memory allocation.
图8是本申请另一个实施例提供的存储控制方法的流程图。该方法可以由上文介绍的控制电路执行。该方法可以包括如下步骤810~830中的至少一个步 骤:Figure 8 is a flow chart of a storage control method provided by another embodiment of the present application. This method can be performed by the control circuit introduced above. The method may include at least one of the following steps 810 to 830: Steps:
步骤810,在存储器的第一工作模式下,控制存储器的第一存储元件组处于上电状态,以及控制存储器的第二存储元件组处于下电状态;其中,第一存储元件组用于存储第一类型的数据。Step 810: In the first working mode of the memory, the first storage element group of the control memory is in the powered-on state, and the second storage element group of the control memory is in the powered-off state; wherein, the first storage element group is used to store the first A type of data.
步骤820,基于存储器从第一工作模式切换至第二工作模式,控制存储器的第二存储元件组从下电状态切换到上电状态,第二存储元件组用于存储第二工作模式下产生的第二类型的数据,第二类型的数据和第一类型的数据不同。Step 820: Based on the memory switching from the first working mode to the second working mode, control the second storage element group of the memory to switch from the power-off state to the power-on state. The second storage element group is used to store the data generated in the second working mode. The second type of data is different from the first type of data.
上述步骤810-820可以参见上文实施例中的介绍说明,本实施例对此不再赘述。For the above steps 810-820, please refer to the introduction in the above embodiment, which will not be described again in this embodiment.
步骤830,基于存储器从第二工作模式切换至第一工作模式,控制存储器的第二存储元件组从上电状态切换到下电状态。Step 830: Based on the memory switching from the second operating mode to the first operating mode, control the second storage element group of the memory to switch from the power-on state to the power-off state.
在无第二类型的数据需要存储时,可以控制存储器从第二工作模式切换至第一工作模式,控制存储器的第二存储元件组从上电状态切换到下电状态,从而节省电量。示例性地,在确定无目标类型的应用程序运行的情况下,控制第二存储元件组从上电状态切换到下电状态。When there is no need to store the second type of data, the memory can be controlled to switch from the second working mode to the first working mode, and the second storage element group of the memory can be controlled to switch from the power-on state to the power-off state, thereby saving power. For example, if it is determined that no application program of the target type is running, the second storage element group is controlled to switch from the power-on state to the power-off state.
可选地,在从第一工作模式切换至第二工作模式之后,若在目标时长内不存在目标类型的应用程序运行,则控制第二存储元件组从上电状态切换到下电状态;其中,在目标时长内,第二存储元件组保持上电状态。也就是说,在目标类型的应用程序停止运行之后,并不是在其停止运行的时刻立即控制第二存储元件组下电,而是等待一段时间且在这一段时间内没有目标类型的应用程序运行的情况下,再控制第二存储元件组下电。这样,可以避免第二存储元件组频繁地上下电,且在短时间内有目标类型的应用程序再次启动时,可以直接使用第二存储元件组,提升目标类型的应用程序再次启动后进入正常运行状态的效率。Optionally, after switching from the first working mode to the second working mode, if there is no application program of the target type running within the target time period, control the second storage element group to switch from the power-on state to the power-off state; wherein , within the target duration, the second storage element group remains powered on. That is to say, after the application program of the target type stops running, the second storage element group is not controlled to power off immediately at the moment when it stops running. Instead, it waits for a period of time and no application program of the target type is running during this period of time. In this case, the second storage element group is then controlled to power off. In this way, the second storage element group can be avoided from being powered on and off frequently, and when an application of the target type is started again in a short period of time, the second storage element group can be directly used to improve the normal operation of the application of the target type after being restarted. state efficiency.
下述为本申请装置实施例,可以用于执行本申请方法实施例。对于本申请装置实施例中未披露的细节,请参照本申请方法实施例。The following are device embodiments of the present application, which can be used to execute method embodiments of the present application. For details not disclosed in the device embodiments of this application, please refer to the method embodiments of this application.
图9是本申请一个实施例提供的存储控制装置的框图。该装置具有实现上述方法示例的功能,所述功能可以由硬件实现,也可以由硬件执行相应的软件实现。所述装置900可以是上文介绍的控制电路,也可以设置在控制电路中。Figure 9 is a block diagram of a storage control device provided by an embodiment of the present application. The device has the function of implementing the above method example, and the function can be implemented by hardware, or can be implemented by hardware executing corresponding software. The device 900 may be the control circuit introduced above, or may be provided in the control circuit.
在一些实施例中,所述装置900配置成基于存储器从第一工作模式切换至 第二工作模式,控制所述存储器的第二存储元件组从下电状态切换到上电状态;其中,所述存储器包括配置成存储第一类型数据的第一存储元件组和配置成存储第二类型数据的所述第二存储元件组。In some embodiments, the device 900 is configured to switch from the first operating mode to the The second operating mode controls the second storage element group of the memory to switch from the power-off state to the power-on state; wherein the memory includes a first storage element group configured to store the first type of data and a second storage element group configured to store the second type of data. The second storage element group of type data.
在一些实施例中,所述装置900还配置成在所述存储器的所述第一工作模式下,控制所述第一存储元件组处于上电状态,以及控制所述第二存储元件组处于下电状态。In some embodiments, the device 900 is further configured to, in the first operating mode of the memory, control the first storage element group to be in a power-on state, and control the second storage element group to be in a power-down state. power status.
在一些实施例中,所述装置900还配置成基于确定目标类型的应用程序运行,控制所述存储器切换至所述第二工作模式。In some embodiments, the device 900 is further configured to control the memory to switch to the second working mode based on determining the target type of application execution.
在一些实施例中,所述装置900还配置成动态地确定所述目标类型的应用程序。In some embodiments, the apparatus 900 is further configured to dynamically determine the target type of application.
在一些实施例中,所述装置900还配置成获取终端设备中的至少一个应用程序的历史运行数据;其中,所述历史运行数据用于记录所述应用程序的历史运行情况;根据各个所述应用程序的历史运行数据,从各个所述应用程序中确定所述目标类型的应用程序。In some embodiments, the apparatus 900 is further configured to obtain historical running data of at least one application in the terminal device; wherein the historical running data is used to record the historical running status of the application; according to each of the The historical running data of the application program determines the application program of the target type from each of the application programs.
在一些实施例中,所述装置900还配置成将所述第二工作模式下产生的所述第二类型数据存储于所述第二存储元件组。In some embodiments, the device 900 is further configured to store the second type of data generated in the second operating mode in the second storage element group.
在一些实施例中,所述装置900还配置成基于所述存储器从所述第二工作模式切换至所述第一工作模式,控制所述第二存储元件组从所述上电状态切换到所述下电状态。In some embodiments, the device 900 is further configured to control the second storage element group to switch from the power-on state to the first operating mode based on the memory switching from the second operating mode to the first operating mode. Describe the power-off status.
在一些实施例中,所述装置900还配置成在从所述第一工作模式切换至所述第二工作模式之后,若在目标时长内不存在所述目标类型的应用程序运行,则控制所述第二存储元件组从所述上电状态切换到所述下电状态;其中,在所述目标时长内,所述第二存储元件组保持所述上电状态。In some embodiments, the device 900 is further configured to, after switching from the first working mode to the second working mode, if there is no application program of the target type running within a target duration, control all The second storage element group switches from the power-on state to the power-down state; wherein, within the target time period, the second storage element group maintains the power-on state.
在一些实施例中,所述装置900还配置成在从所述第一工作模式切换至所述第二工作模式的情况下,控制所述第一存储元件组保持所述上电状态。In some embodiments, the device 900 is further configured to control the first storage element group to maintain the power-on state when switching from the first operating mode to the second operating mode.
在一些实施例中,所述装置900还配置成分别独立地控制所述第一存储元件组的工作频率和所述第二存储元件组的工作频率。In some embodiments, the apparatus 900 is further configured to independently control the operating frequency of the first storage element group and the operating frequency of the second storage element group.
在一些实施例中,所述装置900可以包括:第一控制模块910和第二控制模块920。第一控制模块910配置成控制所述第一存储元件组的时钟频率和/或数据读写频率。第二控制模块920配置成控制所述第二存储元件组的时钟频率 和/或数据读写频率。In some embodiments, the device 900 may include: a first control module 910 and a second control module 920 . The first control module 910 is configured to control the clock frequency and/or data reading and writing frequency of the first storage element group. The second control module 920 is configured to control the clock frequency of the second storage element group and/or data read and write frequency.
本申请实施例中,通过将存储器划分为多个存储元件组(如至少包括第一存储元件组和第二存储元件组),不同的存储元件组用于存储不同类型的数据,从而能够实现存储元件组的按需使用,例如在没有某一存储元件组对应的数据需要存储时,则可以控制该存储元件组处于下电状态,在有需要该存储元件组对应的数据需要存储时,再控制该存储元件组从下电状态切换至上电状态,这种按需分配和控制的方式,能够节省存储器的电量消耗,达到较好的节能效果。In the embodiment of the present application, by dividing the memory into multiple storage element groups (for example, including at least a first storage element group and a second storage element group), different storage element groups are used to store different types of data, thereby enabling storage On-demand use of element groups. For example, when there is no data corresponding to a certain storage element group that needs to be stored, the storage element group can be controlled to be in a power-off state. When there is need to store data corresponding to the storage element group, the storage element group can be controlled again. The storage element group switches from the power-off state to the power-on state. This on-demand allocation and control method can save the power consumption of the memory and achieve a better energy-saving effect.
需要说明的是,上述实施例提供的装置,在实现其功能时,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将设备的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。另外,上述实施例提供的装置与方法实施例属于同一构思,其具体实现过程详见方法实施例,这里不再赘述。It should be noted that when implementing the functions of the device provided by the above embodiments, only the division of the above functional modules is used as an example. In practical applications, the above functions can be allocated to different functional modules according to needs, that is, The internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the apparatus and method embodiments provided in the above embodiments belong to the same concept, and the specific implementation process can be found in the method embodiments, which will not be described again here.
图10是本申请一个示例性实施例提供的终端设备的示意图。以本实施例中的终端设备1500包含主设备101和存储器200为例进行说明:Figure 10 is a schematic diagram of a terminal device provided by an exemplary embodiment of the present application. Take the terminal device 1500 in this embodiment including the main device 101 and the memory 200 as an example for explanation:
终端设备1500设置有主设备101和上述实施例所述的存储器200,主设备101和存储器200电性相连。其中,该存储器200可以设置在片上系统的内部,或者,设置在片上系统的外部。需要说明的是,除了片上系统外,终端设备1500还可以包括其它必要组件,比如只读存储器(Read-Only Memory,ROM)、显示组件、输入单元、音频电路、扬声器、麦克风、电源等部件,本实施例在此不作赘述。The terminal device 1500 is provided with a main device 101 and the memory 200 described in the above embodiment, and the main device 101 and the memory 200 are electrically connected. The memory 200 may be provided inside the system-on-chip or outside the system-on-chip. It should be noted that in addition to the system on a chip, the terminal device 1500 may also include other necessary components, such as read-only memory (Read-Only Memory, ROM), display components, input units, audio circuits, speakers, microphones, power supplies and other components. This embodiment will not be described in detail here.
终端设备1500可以是诸如手机、平板电脑、游戏主机、电子书阅读器、多媒体播放设备、可穿戴设备等电子设备。可选地,终端设备1500为移动终端设备。该终端设备用于实施上述实施例中提供的存储控制方法。The terminal device 1500 may be an electronic device such as a mobile phone, a tablet computer, a game console, an e-book reader, a multimedia playback device, a wearable device, etc. Optionally, the terminal device 1500 is a mobile terminal device. The terminal device is used to implement the storage control method provided in the above embodiment.
在一些实施例中,终端设备包括处理器和存储器,处理器可以是上述主设备101中的处理器,存储器可以是上述存储器200。存储器中存储有计算机程序,处理器执行该计算机程序以实现上述存储控制方法。In some embodiments, the terminal device includes a processor and a memory. The processor may be the processor in the main device 101 described above, and the memory may be the memory 200 described above. A computer program is stored in the memory, and the processor executes the computer program to implement the above storage control method.
在一些实施例中,本申请还提供了一种计算机可读存储介质,所述存储介质中存储有计算机程序,所述计算机程序在被处理器执行时以实现上述存储控制方法。 In some embodiments, the present application also provides a computer-readable storage medium in which a computer program is stored, and when executed by a processor, the computer program implements the above storage control method.
可选地,该计算机可读存储介质可以包括:ROM(Read-Only Memory,只读存储器)、RAM(Random-Access Memory,随机存储器)、SSD(Solid State Drives,固态硬盘)或光盘等。其中,随机存取记忆体可以包括ReRAM(Resistance Random Access Memory,电阻式随机存取记忆体)和DRAM(Dynamic Random Access Memory,动态随机存取存储器)。Optionally, the computer-readable storage medium may include: ROM (Read-Only Memory), RAM (Random-Access Memory), SSD (Solid State Drives, solid state drive) or optical disk, etc. Among them, random access memory can include ReRAM (Resistance Random Access Memory, resistive random access memory) and DRAM (Dynamic Random Access Memory, dynamic random access memory).
在一些实施例中,本申请还提供了一种芯片,所述芯片包括如上文实施例提供的存储控制装置。有关该存储控制装置的未详细说明的细节,可参考上文实施例,此处不再赘述。In some embodiments, the present application also provides a chip, which includes the storage control device as provided in the above embodiments. For unspecified details of the storage control device, please refer to the above embodiments and will not be described again here.
在一些实施例中,本申请还提供了一种存储器,所述存储器包括:In some embodiments, this application also provides a memory, the memory includes:
第一存储元件组,用于存储第一类型数据;A first storage element group used to store first type data;
第二存储元件组,用于存储第二类型数据,其中,所述第二存储元件组配置成基于所述存储器从第一工作模式切换至第二工作模式从下电状态切换到上电状态。有关该存储器的未详细说明的细节,可参考上文实施例,此处不再赘述。A second storage element group is used to store second type data, wherein the second storage element group is configured to switch from a power-down state to a power-on state based on the memory switching from the first operating mode to the second operating mode. For unspecified details of the memory, please refer to the above embodiments and will not be described again here.
在一些实施例中,本申请还提供了一种计算机程序产品,该计算机程序产品包括计算机程序,该计算机程序存储在计算机可读存储介质中。终端设备的处理器从计算机可读存储介质读取该计算机程序,处理器执行该计算机指令,使得该终端设备执行上述存储控制方法。In some embodiments, the present application also provides a computer program product, the computer program product includes a computer program, and the computer program is stored in a computer-readable storage medium. The processor of the terminal device reads the computer program from the computer-readable storage medium, and the processor executes the computer instructions, so that the terminal device executes the above storage control method.
在本文中提及的“多个”是指两个或两个以上。“和/或”,描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。字符“/”一般表示前后关联对象是一种“或”的关系。The "plurality" mentioned in this article means two or more than two. "And/or" describes the relationship between related objects, indicating that there can be three relationships. For example, A and/or B can mean: A exists alone, A and B exist simultaneously, and B exists alone. The character "/" generally indicates that the related objects are in an "or" relationship.
以上所述仅为本申请的可选实施例,并不用以限制本申请,凡在本申请的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本申请的保护范围之内。 The above are only optional embodiments of the present application and are not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included in the protection of the present application. within the range.

Claims (16)

  1. 一种存储控制方法,所述方法包括:A storage control method, the method includes:
    基于存储器从第一工作模式切换至第二工作模式,控制所述存储器的第二存储元件组从下电状态切换到上电状态;Based on the memory switching from the first operating mode to the second operating mode, control the second storage element group of the memory to switch from the power-off state to the power-on state;
    其中,所述存储器包括配置成存储第一类型数据的第一存储元件组和配置成存储第二类型数据的所述第二存储元件组。Wherein, the memory includes a first storage element group configured to store a first type of data and a second storage element group configured to store a second type of data.
  2. 根据权利要求1所述的方法,其中,所述方法还包括:The method of claim 1, further comprising:
    在所述存储器的所述第一工作模式下,控制所述第一存储元件组处于上电状态,以及控制所述第二存储元件组处于下电状态。In the first operating mode of the memory, the first storage element group is controlled to be in a power-on state, and the second storage element group is controlled to be in a power-down state.
  3. 根据权利要求1所述的方法,其中,所述方法还包括:The method of claim 1, further comprising:
    基于确定目标类型的应用程序运行,控制所述存储器切换至所述第二工作模式。Based on determining the target type of application program execution, the memory is controlled to switch to the second working mode.
  4. 根据权利要求3所述的方法,其中,所述方法还包括:The method of claim 3, further comprising:
    动态地确定所述目标类型的应用程序。Dynamically determine the target type of application.
  5. 根据权利要求4所述的方法,其中,所述动态地确定所述目标类型的应用程序,包括:The method of claim 4, wherein the dynamically determining the target type of application includes:
    获取终端设备中的至少一个应用程序的历史运行数据;其中,所述历史运行数据用于记录所述应用程序的历史运行情况;Obtain historical running data of at least one application program in the terminal device; wherein the historical running data is used to record the historical running status of the application program;
    根据各个所述应用程序的历史运行数据,从各个所述应用程序中确定所述目标类型的应用程序。The application program of the target type is determined from each of the application programs according to the historical operation data of each of the application programs.
  6. 根据权利要求1至5任一项所述的方法,其中,所述方法还包括:The method according to any one of claims 1 to 5, wherein the method further includes:
    将所述第二工作模式下产生的所述第二类型数据存储于所述第二存储元件组。 The second type data generated in the second operating mode is stored in the second storage element group.
  7. 根据权利要求1至6任一项所述的方法,其中,所述方法还包括:The method according to any one of claims 1 to 6, wherein the method further includes:
    基于所述存储器从所述第二工作模式切换至所述第一工作模式,控制所述第二存储元件组从所述上电状态切换到所述下电状态。Based on the memory switching from the second operating mode to the first operating mode, the second storage element group is controlled to switch from the power-on state to the power-down state.
  8. 根据权利要求7所述的方法,其中,所述方法还包括:The method of claim 7, further comprising:
    在从所述第一工作模式切换至所述第二工作模式之后,若在目标时长内不存在所述目标类型的应用程序运行,则执行所述控制所述第二存储元件组从所述上电状态切换到所述下电状态的步骤;After switching from the first working mode to the second working mode, if there is no application program of the target type running within a target time period, execute the control of the second storage element group from the above The step of switching the power state to the power-off state;
    其中,在所述目标时长内,所述第二存储元件组保持所述上电状态。Wherein, within the target duration, the second storage element group maintains the power-on state.
  9. 根据权利要求1至8任一项所述的方法,其中,所述方法还包括:The method according to any one of claims 1 to 8, wherein the method further includes:
    在从所述第一工作模式切换至所述第二工作模式的情况下,控制所述第一存储元件组保持所述上电状态。When switching from the first operating mode to the second operating mode, the first storage element group is controlled to maintain the power-on state.
  10. 根据权利要求1至9任一项所述的方法,其中,所述方法还包括:The method according to any one of claims 1 to 9, wherein the method further includes:
    分别独立地控制所述第一存储元件组的工作频率和所述第二存储元件组的工作频率。The operating frequency of the first storage element group and the operating frequency of the second storage element group are controlled independently.
  11. 一种存储控制装置,所述装置配置成:A storage control device, the device is configured to:
    基于存储器从第一工作模式切换至第二工作模式,控制所述存储器的第二存储元件组从下电状态切换到上电状态;Based on the memory switching from the first operating mode to the second operating mode, controlling the second storage element group of the memory to switch from the power-off state to the power-on state;
    其中,所述存储器包括配置成存储第一类型数据的第一存储元件组和配置成存储第二类型数据的所述第二存储元件组。Wherein, the memory includes a first storage element group configured to store a first type of data and a second storage element group configured to store a second type of data.
  12. 根据权利要求11所述的装置,其中,所述装置包括:The device of claim 11, wherein said device includes:
    第一控制模块,配置成控制所述第一存储元件组的时钟频率和/或数据读写频率;A first control module configured to control the clock frequency and/or data reading and writing frequency of the first storage element group;
    第二控制模块,配置成控制所述第二存储元件组的时钟频率和/或数据读写频率。 The second control module is configured to control the clock frequency and/or data reading and writing frequency of the second storage element group.
  13. 一种终端设备,所述终端设备包括处理器和存储器,所述存储器中存储有计算机程序,所述处理器执行所述计算机程序以实现如权利要求1至10任一项所述的方法。A terminal device, the terminal device includes a processor and a memory, a computer program is stored in the memory, and the processor executes the computer program to implement the method according to any one of claims 1 to 10.
  14. 一种计算机可读存储介质,所述存储介质中存储有计算机程序,所述计算机程序用于被处理器执行,以实现如权利要求1至10任一项所述的方法。A computer-readable storage medium, in which a computer program is stored, and the computer program is used to be executed by a processor to implement the method according to any one of claims 1 to 10.
  15. 一种芯片,所述芯片包括如权利要求11至12任一项所述的存储控制装置。A chip comprising the storage control device according to any one of claims 11 to 12.
  16. 一种存储器,所述存储器包括:A memory including:
    第一存储元件组,用于存储第一类型数据;A first storage element group used to store first type data;
    第二存储元件组,用于存储第二类型数据,其中,所述第二存储元件组配置成基于所述存储器从第一工作模式切换至第二工作模式从下电状态切换到上电状态。 A second storage element group is used to store second type data, wherein the second storage element group is configured to switch from a power-down state to a power-on state based on the memory switching from the first operating mode to the second operating mode.
PCT/CN2023/084426 2022-07-25 2023-03-28 Storage control method and apparatus, device, storage medium, chip, and memory WO2024021657A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210875910.9A CN117492553A (en) 2022-07-25 2022-07-25 Storage control method, device, equipment, storage medium, chip and memory
CN202210875910.9 2022-07-25

Publications (1)

Publication Number Publication Date
WO2024021657A1 true WO2024021657A1 (en) 2024-02-01

Family

ID=89681495

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/084426 WO2024021657A1 (en) 2022-07-25 2023-03-28 Storage control method and apparatus, device, storage medium, chip, and memory

Country Status (2)

Country Link
CN (1) CN117492553A (en)
WO (1) WO2024021657A1 (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007114620A (en) * 2005-10-21 2007-05-10 Konica Minolta Business Technologies Inc Image forming apparatus
JP2011060238A (en) * 2009-09-14 2011-03-24 Ricoh Co Ltd Information processor, image forming apparatus, operation mode switching method
US20130166935A1 (en) * 2011-12-26 2013-06-27 Yuuki Imaizumi Control device and computer program product for controlling method
CN104808765A (en) * 2014-01-27 2015-07-29 联想(北京)有限公司 Information processing method and electronic equipment
CN104850208A (en) * 2014-02-19 2015-08-19 联想(北京)有限公司 Information processing method and electronic equipment

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007114620A (en) * 2005-10-21 2007-05-10 Konica Minolta Business Technologies Inc Image forming apparatus
JP2011060238A (en) * 2009-09-14 2011-03-24 Ricoh Co Ltd Information processor, image forming apparatus, operation mode switching method
US20130166935A1 (en) * 2011-12-26 2013-06-27 Yuuki Imaizumi Control device and computer program product for controlling method
CN104808765A (en) * 2014-01-27 2015-07-29 联想(北京)有限公司 Information processing method and electronic equipment
CN104850208A (en) * 2014-02-19 2015-08-19 联想(北京)有限公司 Information processing method and electronic equipment

Also Published As

Publication number Publication date
CN117492553A (en) 2024-02-02

Similar Documents

Publication Publication Date Title
US8977880B2 (en) Method for managing power supply of multi-core processor system involves powering off main and slave cores when master bus is in idle state
US11797467B2 (en) Data processing device with transmission circuit
CN110309088B (en) ZYNQ FPGA chip, data processing method thereof and storage medium
CN110750351B (en) Multi-core task scheduler, multi-core task scheduling method, multi-core task scheduling device and related products
CN102597912A (en) Coordinating device and application break events for platform power saving
CN103076868B (en) The electronic system of method for managing power supply and application the method
US9223379B2 (en) Intelligent receive buffer management to optimize idle state residency
WO2024021657A1 (en) Storage control method and apparatus, device, storage medium, chip, and memory
CN116169758A (en) Output power adjusting method and charger
EP4142217A1 (en) Inter-node communication method and device based on multiple processing nodes
TWI763158B (en) Memory sharing
US9081766B2 (en) Memory and process sharing via input/output with virtualization
WO2023231437A1 (en) Memory, system-on-a-chip, terminal device and power supply control method
CN107209544A (en) The system and method for SoC idle power states control based on I/O operation feature
WO2024001192A1 (en) System on chip, voltage control method for system on chip, and terminal
CN106708239A (en) Method and device for adjusting power consumption
WO2023123496A1 (en) Chip system and control method
CN112232498B (en) Data processing device, integrated circuit chip, electronic equipment, board card and method
CN117234744B (en) Multi-chip system performance optimization method, system, electronic equipment and medium
WO2023016382A1 (en) Method for system on chip, and related product thereof
WO2024045580A1 (en) Method for scheduling tasks, and related product thereof
US11442522B2 (en) Method of controlling performance boosting of semiconductor device based on at least user input and feedback from previous boosting policies and semiconductor device performing the method
CN113742266B (en) Integrated circuit device, electronic apparatus, board and computing method
CN111783954B (en) Method, electronic device and storage medium for determining performance of neural network
WO2022083471A1 (en) Power consumption management method and apparatus

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 23844875

Country of ref document: EP

Kind code of ref document: A1