Arm MAP Metric Plugin Interface
Metric Plugin Interface for MAP
allinea_safe_malloc.h File Reference

Async signal safe memory management functions for use in metric plugins. More...

#include <stdlib.h>
Include dependency graph for allinea_safe_malloc.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

Memory management functions

Async signal safe replacements for memory management functions.

Since metric library functions need to be async signal safe the standard libc memory management functions (such as malloc, free, new, delete) cannot be used. The following memory management functions can safely be used by the metric plugin libraries even if they are called from inside a signal handler.

void * allinea_safe_malloc (size_t size)
 An async-signal-safe version of malloc. More...
 
void allinea_safe_free (void *ptr)
 An async-signal-safe version of free. More...
 
void * allinea_safe_calloc (size_t nmemb, size_t size)
 An async-signal-safe version of calloc. More...
 
void * allinea_safe_realloc (void *ptr, size_t size)
 An async-signal-safe version of realloc. More...
 

Detailed Description

Async signal safe memory management functions for use in metric plugins.