Memory allocation method and device based on TLSF algorithm, terminal chip and storage medium

The invention discloses a memory allocation method and device based on a TLSF algorithm, a terminal chip and a storage medium, and the method comprises the steps: determining a first linked list according to the size of a to-be-allocated memory, and enabling memory blocks in the first linked list to...

Ausführliche Beschreibung

Gespeichert in:
Bibliographische Detailangaben
1. Verfasser: DU PENGBO
Format: Patent
Sprache:chi ; eng
Schlagworte:
Online-Zugang:Volltext bestellen
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
Beschreibung
Zusammenfassung:The invention discloses a memory allocation method and device based on a TLSF algorithm, a terminal chip and a storage medium, and the method comprises the steps: determining a first linked list according to the size of a to-be-allocated memory, and enabling memory blocks in the first linked list to be larger than the size of the to-be-allocated memory; when the free memory blocks meeting the size of the to-be-allocated memory do not exist in the first linked list, the free memory blocks meeting the size of the to-be-allocated memory are searched from a second linked list, and the second linked list comprises the memory blocks meeting the size of the to-be-allocated memory. According to the method, when the memory is nearly exhausted, the probability of successful memory allocation can be improved, so that the memory can be fully utilized, and the situation that equipment crashes due to the fact that the memory is exhausted is reduced. 本发明公开了一种基于TLSF算法的内存分配方法、装置、终端芯片及存储介质,方法包括:根据待分配内存大小确定第一链表,第一链表中的内存块皆大于待分配内