malloc_monitor.h
1 /*
2  * Copyright (C) 2024 TU Dresden
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  */
13 #ifndef MALLOC_MONITOR_H
14 #define MALLOC_MONITOR_H
15 
16 #include <assert.h>
17 #include <stdint.h>
18 #include <stddef.h>
19 #include <string.h>
20 
21 #include "architecture.h"
22 
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
26 
33 
41 
50 
51 #ifdef __cplusplus
52 }
53 #endif
54 
55 #endif /* MALLOC_MONITOR_H */
56 
Platform-independent access to architecture details.
POSIX.1-2008 compliant version of the assert macro.
size_t malloc_monitor_get_usage_high_watermark(void)
Obtain maximum heap memory usage since last call to malloc_monitor_reset_high_watermark().
void malloc_monitor_reset_high_watermark(void)
Reset maximum heap memory usage.
size_t malloc_monitor_get_usage_current(void)
Obtain current heap memory usage.