CPC G06F 12/06 (2013.01) [G06N 3/0464 (2023.01)] | 17 Claims |
1. A method of allocating a space address to data in a memory, comprising:
receiving a space assigning request aiming at storage space in the memory, wherein the space assigning request comprises a size of the data;
assigning target storage space to the data according to the received space assigning request;
allocating the space address to the data based on the assigned target storage space;
forming a plurality of memory blocks, wherein each memory block has a total storage size identifier and an available storage size identifier, wherein the total storage size identifier is configured to indicate a total storage size of the memory block, and the available storage size identifier is configured to indicate an available storage size of the memory block; and
taking the plurality of memory blocks as nodes to form a tree structure so that the data is assigned with the target storage space according to the tree structure when the space assigning request is received, wherein the tree structure comprises a plurality of nodes of multi-stage, wherein a total storage size of a parent node is a sum of total storage size of children nodes.
|