提供AliOS Things系统内核内存管理功能的基础API.
◆ aos_alloc_trace()
void aos_alloc_trace |
( |
void * |
addr, |
|
|
uintptr_t |
allocator |
|
) |
| |
Trace alloced mems.
- 参数
-
[in] | addr | pointer of the mem alloced by malloc. |
[in] | allocator | buildin_address. |
◆ aos_calloc()
void* aos_calloc |
( |
size_t |
nitems, |
|
|
size_t |
size |
|
) |
| |
Alloc memory and clear to zero.
- 参数
-
[in] | nitems | number of items to malloc. |
[in] | size | size of one item to malloc. |
- 返回
- NULL: error.
◆ aos_free()
void aos_free |
( |
void * |
mem | ) |
|
Free memory.
- 参数
-
[in] | ptr | address point of the mem. |
- 返回
- none.
◆ aos_malloc()
void* aos_malloc |
( |
size_t |
size | ) |
|
Alloc memory.
- 参数
-
[in] | size | size of the mem to malloc. |
- 返回
- NULL: error.
◆ aos_realloc()
void* aos_realloc |
( |
void * |
mem, |
|
|
size_t |
size |
|
) |
| |
Realloc memory.
- 参数
-
[in] | mem | current memory address point. |
[in] | size | new size of the mem to remalloc. |
- 返回
- NULL: error.
◆ aos_zalloc()
void* aos_zalloc |
( |
size_t |
size | ) |
|
Alloc memory and clear to zero.
- 参数
-
[in] | size | size of the mem to malloc. |
- 返回
- NULL: error.