Toggle navigation
Documentation
The friendly Operating System for the Internet of Things
Loading...
Searching...
No Matches
tlsf-malloc.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2014-2018 Freie Universität Berlin
3
*
4
* This file is subject to the terms and conditions of the GNU Lesser
5
* General Public License v2.1. See the file LICENSE in the top level
6
* directory for more details.
7
*/
36
#ifndef TLSF_MALLOC_H
37
#define TLSF_MALLOC_H
38
39
#include <stddef.h>
40
41
#include "tlsf.h"
42
43
#ifdef __cplusplus
44
extern
"C"
{
45
#endif
46
51
typedef
struct
{
52
unsigned
free
;
53
unsigned
used
;
54
}
tlsf_size_container_t
;
55
67
void
tlsf_size_walker
(
void
* ptr,
size_t
size,
int
used,
void
* user);
68
83
int
tlsf_add_global_pool
(
void
*mem,
size_t
bytes);
84
90
tlsf_t
_tlsf_get_global_control
(
void
);
91
92
#ifdef __cplusplus
93
}
94
#endif
95
96
#endif
/* TLSF_MALLOC_H */
97
tlsf_add_global_pool
int tlsf_add_global_pool(void *mem, size_t bytes)
Add an area of memory to the global allocator pool.
_tlsf_get_global_control
tlsf_t _tlsf_get_global_control(void)
Get a pointer to the global tlsf_control block.
tlsf_size_walker
void tlsf_size_walker(void *ptr, size_t size, int used, void *user)
Walk the memory pool to print all block sizes and to calculate the total amount of free and used bloc...
tlsf_size_container_t
Struct to hold the total sizes of free and used blocks Used for tlsf_size_walker()
Definition
tlsf-malloc.h:51
tlsf_size_container_t::free
unsigned free
total free size
Definition
tlsf-malloc.h:52
tlsf_size_container_t::used
unsigned used
total used size
Definition
tlsf-malloc.h:53
Generated on Sat Nov 23 2024 19:57:24 by
1.9.8