webkit  2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
Classes | Macros
user_malloc.h File Reference
#include <stdlib.h>
#include <sys/types.h>
#include <strings.h>
#include <stdint.h>

Go to the source code of this file.

Classes

struct  malloc_type_stats
 
struct  malloc_type_internal
 
struct  malloc_type
 
struct  malloc_type_stream_header
 
struct  malloc_type_header
 

Macros

#define MINALLOCSIZE   UMA_SMALLEST_UNIT
 
#define M_NOWAIT   0x0001 /* do not block */
 
#define M_WAITOK   0x0002 /* ok to block */
 
#define M_ZERO   0x0100 /* bzero the allocation */
 
#define M_NOVM   0x0200 /* don't ask VM for pages */
 
#define M_USE_RESERVE   0x0400 /* can alloc out of reserve memory */
 
#define M_MAGIC   877983977 /* time when first defined :-) */
 
#define MAXCPU   4 /* arbitrary? */
 
#define MALLOC_TYPE_STREAM_VERSION   0x00000001
 
#define MALLOC_MAX_NAME   32
 
#define MALLOC_DEFINE(type, shortdesc, longdesc)
 
#define MALLOC_DECLARE(type)   extern struct malloc_type type[1]
 
#define FREE(addr, type)   free((addr))
 
#define MALLOC(space, cast, size, type, flags)
 

Macro Definition Documentation

◆ FREE

#define FREE (   addr,
  type 
)    free((addr))

◆ M_MAGIC

#define M_MAGIC   877983977 /* time when first defined :-) */

◆ M_NOVM

#define M_NOVM   0x0200 /* don't ask VM for pages */

◆ M_NOWAIT

#define M_NOWAIT   0x0001 /* do not block */

◆ M_USE_RESERVE

#define M_USE_RESERVE   0x0400 /* can alloc out of reserve memory */

◆ M_WAITOK

#define M_WAITOK   0x0002 /* ok to block */

◆ M_ZERO

#define M_ZERO   0x0100 /* bzero the allocation */

◆ MALLOC

#define MALLOC (   space,
  cast,
  size,
  type,
  flags 
)
Value:
((space) = (cast)malloc((u_long)(size))); \
do { \
if (flags & M_ZERO) { \
memset(space,0,size); \
} \
} while (0);
EGLStreamKHR EGLint EGLint EGLint size
Definition: eglext.h:984
#define M_ZERO
Definition: user_malloc.h:62
const UChar space
Definition: CharacterNames.h:87
#define malloc
Definition: mbmalloc.h:49
Definition: bwe_rtp.cc:26

◆ MALLOC_DECLARE

#define MALLOC_DECLARE (   type)    extern struct malloc_type type[1]

◆ MALLOC_DEFINE

#define MALLOC_DEFINE (   type,
  shortdesc,
  longdesc 
)
Value:
struct malloc_type type[1] = { \
{ NULL, 0, 0, 0, 0, 0, M_MAGIC, shortdesc, NULL, NULL, \
NULL, 0, NULL, NULL, 0, 0 } \
}
EGLenum type
Definition: eglext.h:63
Definition: user_malloc.h:109
#define NULL
Definition: common_types.h:41
#define M_MAGIC
Definition: user_malloc.h:66

◆ MALLOC_MAX_NAME

#define MALLOC_MAX_NAME   32

◆ MALLOC_TYPE_STREAM_VERSION

#define MALLOC_TYPE_STREAM_VERSION   0x00000001

◆ MAXCPU

#define MAXCPU   4 /* arbitrary? */

◆ MINALLOCSIZE

#define MINALLOCSIZE   UMA_SMALLEST_UNIT