MCPcopy Create free account
hub / github.com/1a1a11a/libCacheSim / mspace_malloc

Function mspace_malloc

libCacheSim/dataStructure/sparsepp/spp_dlalloc.h:3724–3733  ·  view source on GitHub ↗

---------------------------- mspace versions of malloc/calloc/free routines -------------------- */

Source from the content-addressed store, hash-verified

3722
3723/* ---------------------------- mspace versions of malloc/calloc/free routines -------------------- */
3724SPP_API void* mspace_malloc(mspace msp, size_t bytes)
3725{
3726 mstate ms = (mstate)msp;
3727 if (!ms->ok_magic())
3728 {
3729 SPP_USAGE_ERROR_ACTION(ms, ms);
3730 return 0;
3731 }
3732 return ms->_malloc(bytes);
3733}
3734
3735SPP_API void mspace_free(mspace msp, void* mem)
3736{

Callers 4

allocateMethod · 0.85
internal_mallocMethod · 0.85
mspace_reallocFunction · 0.85
mspace_memalignFunction · 0.85

Calls 2

ok_magicMethod · 0.80
_mallocMethod · 0.80

Tested by

no test coverage detected