CN-121979445-A - Storage management method and device, electronic equipment and chip
Abstract
The invention provides a storage management method, a device, electronic equipment and a chip, and relates to the technical field of chips, wherein the method comprises the steps of responding to a storage resource request of a first hardware accelerator, distributing a target virtual address corresponding to the storage resource request in a virtual storage list, wherein the virtual storage list is obtained by uniformly addressing a storage resource pool, the storage resource pool comprises special storage resources of a plurality of hardware accelerators in the chip, and the plurality of hardware accelerators comprise the first hardware accelerator; and opening the access authority of the target storage resource in the storage resource pool to the first hardware accelerator according to the storage resource physical address. By applying the technical scheme of the present disclosure, dedicated storage resources idle by the hardware accelerator can be fully utilized through unified pooling management, waste of the storage resources is avoided, flexible and effective management of the storage resources can be realized, and utilization rate of the storage resources can be improved.
Inventors
- MA YIRONG
Assignees
- 北京玄戒技术有限公司
Dates
- Publication Date
- 20260505
- Application Date
- 20251230
Claims (17)
- 1. A storage management method, comprising: Distributing a target virtual address corresponding to a storage resource request in a virtual storage list in response to the storage resource request of a first hardware accelerator, wherein the virtual storage list is obtained by uniformly addressing a storage resource pool, the storage resource pool comprises special storage resources of a plurality of hardware accelerators in a chip, and the plurality of hardware accelerators comprise the first hardware accelerator; acquiring a storage resource physical address corresponding to the target virtual address; and opening the access authority of the target storage resource in the storage resource pool to the first hardware accelerator according to the storage resource physical address.
- 2. The method of claim 1, wherein the pool of storage resources further comprises shared storage resources within the chip and external storage resources of the chip; the allocating the target virtual address corresponding to the storage resource request in the virtual storage list includes: Determining resource demand information according to the storage resource request; And according to the resource demand information, and combining the access performance priorities respectively corresponding to the special storage resource, the shared storage resource and the external storage resource, distributing the target virtual address in the virtual storage list.
- 3. The method according to claim 2, wherein the allocating the target virtual address in the virtual storage list according to the resource requirement information and in combination with access performance priorities corresponding to the dedicated storage resource, the shared storage resource and the external storage resource respectively includes: According to the order of the access performance priority from high to low, sequentially matching idle storage resources meeting the resource demand information in the storage resource pool, wherein the access performance priority of the special storage resources of the first hardware accelerator is higher than that of the special storage resources of other hardware accelerators, the access performance priority of the special storage resources of the other hardware accelerators is higher than that of the shared storage resources, and the access performance priority of the shared storage resources is higher than that of the external storage resources; And determining a corresponding virtual address in the virtual storage list as the target virtual address according to the idle storage resources obtained by matching.
- 4. The method of claim 2, wherein before the allocating the target virtual address in the virtual storage list according to the resource requirement information and in combination with the access performance priorities respectively corresponding to the dedicated storage resource, the shared storage resource, and the external storage resource, the method further comprises: detecting whether storage resources pre-allocated for the first hardware accelerator exist in the storage resource pool or not; And if the pre-allocated storage resources exist in the storage resource pool and the pre-allocated storage resources meet the resource demand information, determining the target virtual address according to the virtual address of the pre-allocated storage resources in the virtual storage list.
- 5. The method according to claim 4, wherein the allocating the target virtual address in the virtual storage list according to the resource requirement information and in combination with access performance priorities corresponding to the dedicated storage resource, the shared storage resource, and the external storage resource respectively includes: And if the pre-allocated storage resources do not exist in the storage resource pool or the pre-allocated storage resources do not meet the resource demand information, allocating the target virtual address in the virtual storage list according to the resource demand information and combining the access performance priorities respectively corresponding to the dedicated storage resources, the shared storage resources and the external storage resources.
- 6. The method according to claim 1, wherein the method further comprises: And acquiring a physical address of the storage resource corresponding to the target virtual address through a hardware accelerator page table, wherein the hardware accelerator page table comprises a mapping relation between the target virtual address and the physical address of the target storage resource.
- 7. The method of claim 6, wherein the hardware accelerator page table further comprises attribute bits of at least one of: The location bit is used for indicating a storage level of the target storage resource, wherein the storage level is any one of a storage level of a special storage resource of a hardware accelerator, a storage level of a shared storage resource in the chip and a storage level of an external storage resource of the chip; a migration bit to indicate whether migration of the target storage resource between different storage tiers is permitted; accelerator bits to indicate a target hardware accelerator that allows the target storage resource to be preferentially accessed.
- 8. The method of claim 7, wherein the method further comprises: If the allowable migration is determined according to the migration bit, and the storage hierarchy where the target storage resource is located is determined not to be the storage hierarchy corresponding to the highest access performance priority according to the position bit, migrating the storage hierarchy where the target storage resource is located to the storage hierarchy corresponding to the higher access performance priority; and after the migration is completed, updating the physical address mapping relation and the position bit corresponding to the target virtual address in the hardware accelerator page table.
- 9. The method according to any one of claims 1 to 8, further comprising: Transmitting a physical address descriptor of the target storage resource to a second hardware accelerator of the plurality of hardware accelerators; and responding to the access request of the second hardware accelerator to the target storage resource, and opening the access right of the target storage resource to the second hardware accelerator according to the physical address descriptor in the access request.
- 10. A storage management device, comprising: the allocation module is used for responding to a storage resource request of a first hardware accelerator and allocating a target virtual address corresponding to the storage resource request in a virtual storage list, wherein the virtual storage list is obtained by uniformly addressing a storage resource pool, the storage resource pool comprises special storage resources of a plurality of hardware accelerators in a chip, and the plurality of hardware accelerators comprise the first hardware accelerator; the acquisition module is used for acquiring a storage resource physical address corresponding to the target virtual address; And the opening module is used for opening the access authority of the target storage resource in the storage resource pool to the first hardware accelerator according to the physical address of the storage resource.
- 11. The apparatus of claim 10, wherein the pool of memory resources further comprises shared memory resources within the chip and external memory resources of the chip; The allocation module is specifically configured to determine resource requirement information according to the storage resource request, and allocate the target virtual address in the virtual storage list according to the resource requirement information and in combination with access performance priorities corresponding to the dedicated storage resource, the shared storage resource and the external storage resource respectively.
- 12. The apparatus according to claim 11, wherein the allocation module is specifically configured to: According to the order of the access performance priority from high to low, sequentially matching idle storage resources meeting the resource demand information in the storage resource pool, wherein the access performance priority of the special storage resources of the first hardware accelerator is higher than that of the special storage resources of other hardware accelerators, the access performance priority of the special storage resources of the other hardware accelerators is higher than that of the shared storage resources, and the access performance priority of the shared storage resources is higher than that of the external storage resources; And determining a corresponding virtual address in the virtual storage list as the target virtual address according to the idle storage resources obtained by matching.
- 13. The apparatus of any one of claims 10 to 12, wherein the open module is further to: Transmitting a physical address descriptor of the target storage resource to a second hardware accelerator of the plurality of hardware accelerators; and responding to the access request of the second hardware accelerator to the target storage resource, and opening the access right of the target storage resource to the second hardware accelerator according to the physical address descriptor in the access request.
- 14. An electronic device, comprising: A processor; a memory coupled to the processor, the memory having stored thereon a computer program which, when executed by the processor, implements the method of any of claims 1 to 9.
- 15. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the method of any one of claims 1 to 9.
- 16. A computer program product comprising a computer program, characterized in that the computer program, when executed by a processor, implements the method of any one of claims 1 to 9.
- 17. A chip comprising one or more interface circuits and one or more processors, the interface circuits to receive signals from a memory of an electronic device and to send the signals to the processor, the signals comprising computer instructions stored in the memory, which when executed by the processor, cause the electronic device to perform the method of any one of claims 1 to 9.
Description
Storage management method and device, electronic equipment and chip Technical Field The disclosure relates to the technical field of chips, and in particular relates to a storage management method, a storage management device, electronic equipment and a chip. Background With the development of extremely high frequency spectrum efficiency coding, carrier aggregation and other technologies, the data volume and real-time calculation requirements of baseband processing are increased. To meet the balance of performance and power consumption, a baseband chip (SoC) may employ a heterogeneous architecture with a processor responsible for controlling the flow and multiple dedicated hardware accelerators responsible for the data flow. In the related art, a chip includes dedicated memory resources configured for a plurality of hardware accelerators, respectively, which are not effectively managed, and each hardware accelerator can only use its own dedicated memory resource, resulting in low utilization of the memory resources. Disclosure of Invention In order to overcome the problems in the related art, the present disclosure provides a storage management method, a storage management device, an electronic device, and a chip. According to a first aspect of an embodiment of the present disclosure, there is provided a storage management method, including: Distributing a target virtual address corresponding to a storage resource request in a virtual storage list in response to the storage resource request of a first hardware accelerator, wherein the virtual storage list is obtained by uniformly addressing a storage resource pool, the storage resource pool comprises special storage resources of a plurality of hardware accelerators in a chip, and the plurality of hardware accelerators comprise the first hardware accelerator; acquiring a storage resource physical address corresponding to the target virtual address; and opening the access authority of the target storage resource in the storage resource pool to the first hardware accelerator according to the storage resource physical address. In some possible implementations, the storage resource pool further includes shared storage resources within the chip and external storage resources of the chip; the allocating the target virtual address corresponding to the storage resource request in the virtual storage list includes: Determining resource demand information according to the storage resource request; And according to the resource demand information, and combining the access performance priorities respectively corresponding to the special storage resource, the shared storage resource and the external storage resource, distributing the target virtual address in the virtual storage list. In some possible embodiments, the allocating the target virtual address in the virtual storage list according to the resource requirement information and in combination with access performance priorities corresponding to the dedicated storage resource, the shared storage resource and the external storage resource respectively includes: According to the order of the access performance priority from high to low, sequentially matching idle storage resources meeting the resource demand information in the storage resource pool, wherein the access performance priority of the special storage resources of the first hardware accelerator is higher than that of the special storage resources of other hardware accelerators, the access performance priority of the special storage resources of the other hardware accelerators is higher than that of the shared storage resources, and the access performance priority of the shared storage resources is higher than that of the external storage resources; And determining a corresponding virtual address in the virtual storage list as the target virtual address according to the idle storage resources obtained by matching. In some possible embodiments, before the allocating the target virtual address in the virtual storage list according to the resource requirement information and in combination with the access performance priorities corresponding to the dedicated storage resource, the shared storage resource and the external storage resource, the method further includes: detecting whether storage resources pre-allocated for the first hardware accelerator exist in the storage resource pool or not; And if the pre-allocated storage resources exist in the storage resource pool and the pre-allocated storage resources meet the resource demand information, determining the target virtual address according to the virtual address of the pre-allocated storage resources in the virtual storage list. In some possible embodiments, the allocating the target virtual address in the virtual storage list according to the resource requirement information and in combination with access performance priorities corresponding to the dedicated storage resource, the shared storage resource and