MoveIt Pro API
Core Behaviors for MoveIt Pro
Loading...
Searching...
No Matches
malloc_counter.cpp File Reference
#include "malloc_counter/malloc_counter.hpp"
#include <dlfcn.h>
#include <locale.h>
#include <pthread.h>
#include <stdatomic.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
Include dependency graph for malloc_counter.cpp:

Classes

struct  OriginalFunctions
 

Typedefs

using malloc_type = void *(size_t)
 
using free_type = void(void *)
 
using realloc_type = void *(void *, size_t)
 
using calloc_type = void *(size_t, size_t)
 

Functions

size_t malloc_count_current ()
 
size_t malloc_count_peak ()
 
void malloc_count_reset_peak ()
 
size_t malloc_count_num_allocs ()
 
void malloc_count_print_status ()
 
void malloc_count_set_callback (malloc_count_callback_type *, void *)
 
void malloc_count_start_monitoring ()
 
void malloc_count_stop_monitoring ()
 
size_t malloc_count_thread_allocs ()
 
void * malloc (size_t size)
 
void free (void *ptr)
 
void * calloc (size_t nmemb, size_t size)
 
void * realloc (void *ptr, size_t size)
 

Variables

constexpr size_t initHeapSize = 4096 * 4096
 

Typedef Documentation

◆ calloc_type

using calloc_type = void*(size_t, size_t)

◆ free_type

using free_type = void(void*)

◆ malloc_type

using malloc_type = void*(size_t)

◆ realloc_type

using realloc_type = void*(void*, size_t)

Function Documentation

◆ calloc()

void * calloc ( size_t  nmemb,
size_t  size 
)
extern

◆ free()

void free ( void *  ptr)
extern

◆ malloc()

void * malloc ( size_t  size)
extern

◆ malloc_count_current()

size_t malloc_count_current ( void  )
extern

◆ malloc_count_num_allocs()

size_t malloc_count_num_allocs ( void  )
extern

◆ malloc_count_peak()

size_t malloc_count_peak ( void  )
extern

◆ malloc_count_print_status()

void malloc_count_print_status ( void  )
extern

◆ malloc_count_reset_peak()

void malloc_count_reset_peak ( void  )
extern

◆ malloc_count_set_callback()

void malloc_count_set_callback ( malloc_count_callback_type cb,
void *  cookie 
)
extern

◆ malloc_count_start_monitoring()

void malloc_count_start_monitoring ( void  )
extern

◆ malloc_count_stop_monitoring()

void malloc_count_stop_monitoring ( void  )
extern

◆ malloc_count_thread_allocs()

size_t malloc_count_thread_allocs ( void  )
extern

◆ realloc()

void * realloc ( void *  ptr,
size_t  size 
)
extern

Variable Documentation

◆ initHeapSize

constexpr size_t initHeapSize = 4096 * 4096
constexpr