Graphviz 13.0.0~dev.20241220.2304
|
#include <neatogen/geometry.h>
#include <common/render.h>
#include <util/alloc.h>
#include <neatogen/mem.h>
#include <stdlib.h>
#include <stdio.h>
Go to the source code of this file.
Data Structures | |
struct | freenode |
struct | freeblock |
Macros | |
#define | LCM(x, y) ((x)%(y) == 0 ? (x) : (y)%(x) == 0 ? (y) : x*(y/gcd(x,y))) |
Typedefs | |
typedef struct freenode | Freenode |
typedef struct freeblock | Freeblock |
Functions | |
static int | gcd (int y, int x) |
void | freeinit (Freelist *fl, int size) |
void * | getfree (Freelist *fl) |
void | makefree (void *curr, Freelist *fl) |
#define LCM | ( | x, | |
y | |||
) | ((x)%(y) == 0 ? (x) : (y)%(x) == 0 ? (y) : x*(y/gcd(x,y))) |
void freeinit | ( | Freelist * | fl, |
int | size | ||
) |
Definition at line 41 of file memory.c.
References freelist::blocklist, free(), freelist::head, LCM, freeblock::next, freeblock::nodes, freelist::nodesize, and NULL.
Referenced by edgeinit(), ELcleanup(), ELinitialize(), and siteinit().
void * getfree | ( | Freelist * | fl | ) |
Definition at line 60 of file memory.c.
References freelist::blocklist, gv_alloc(), gv_calloc(), freelist::head, makefree(), freeblock::next, freenode::nextfree, freeblock::nodes, freelist::nodesize, NULL, and sqrt_nsites.
Referenced by getsite(), gvbisect(), and HEcreate().
void makefree | ( | void * | curr, |
Freelist * | fl | ||
) |
Definition at line 83 of file memory.c.
References freelist::head, and freenode::nextfree.
Referenced by deref(), ELgethash(), endpoint(), and getfree().