Please, help us to better serve our user community by answering the following short survey: https://www.hdfgroup.org/website-survey/
HDF  4.4.0
API Reference
Loading...
Searching...
No Matches
mcache_priv.h File Reference
#include "hdf_priv.h"
#include "hqueue_priv.h"

Data Structures

struct  BKT
struct  L_ELEM
struct  MCACHE
struct  MCACHE::_lqh
struct  MCACHE::_hqh
struct  MCACHE::_lhqh

Macros

#define RET_SUCCESS   SUCCEED
#define RET_ERROR   FAIL
#define HASHSIZE   128
#define HASHKEY(pgno)
#define DEF_PAGESIZE   8192
#define DEF_MAXCACHE   1
#define MAX_PAGE_NUMBER   0xffffffff
#define MCACHE_DIRTY   0x01
#define MCACHE_PINNED   0x02
#define ELEM_READ   0x01
#define ELEM_WRITTEN   0x02
#define ELEM_SYNC   0x03
#define MCACHE_EXTEND   0x10

Functions

MCACHEmcache_open (void *key, int32 object_id, int32 pagesize, int32 maxcache, int32 npages, int32 flags)
void mcache_filter (MCACHE *mp, int32(*pgin)(void *cookie, int32 pgno, void *page), int32(*pgout)(void *cookie, int32 pgno, const void *page), void *pgcookie)
void * mcache_new (MCACHE *mp, int32 *pgnoaddr, int32 flags)
void * mcache_get (MCACHE *mp, int32 pgno, int32 flags)
int mcache_put (MCACHE *mp, void *page, int32 flags)
int mcache_sync (MCACHE *mp)
int mcache_close (MCACHE *mp)
int32 mcache_get_pagesize (MCACHE *mp)
int32 mcache_get_maxcache (MCACHE *mp)
int32 mcache_set_maxcache (MCACHE *mp, int32 maxcache)
int32 mcache_get_npages (MCACHE *mp)

Macro Definition Documentation

◆ DEF_MAXCACHE

#define DEF_MAXCACHE   1

◆ DEF_PAGESIZE

#define DEF_PAGESIZE   8192

◆ ELEM_READ

#define ELEM_READ   0x01

◆ ELEM_SYNC

#define ELEM_SYNC   0x03

◆ ELEM_WRITTEN

#define ELEM_WRITTEN   0x02

◆ HASHKEY

#define HASHKEY ( pgno)
Value:
((pgno - 1) % HASHSIZE)
#define HASHSIZE
Definition mcache_priv.h:74

◆ HASHSIZE

#define HASHSIZE   128

◆ MAX_PAGE_NUMBER

#define MAX_PAGE_NUMBER   0xffffffff

◆ MCACHE_DIRTY

#define MCACHE_DIRTY   0x01

◆ MCACHE_EXTEND

#define MCACHE_EXTEND   0x10

◆ MCACHE_PINNED

#define MCACHE_PINNED   0x02

◆ RET_ERROR

#define RET_ERROR   FAIL

◆ RET_SUCCESS

#define RET_SUCCESS   SUCCEED

Function Documentation

◆ mcache_close()

int mcache_close ( MCACHE * mp)
extern

◆ mcache_filter()

void mcache_filter ( MCACHE * mp,
int32(* pgin )(void *cookie, int32 pgno, void *page),
int32(* pgout )(void *cookie, int32 pgno, const void *page),
void * pgcookie )
extern

◆ mcache_get()

void * mcache_get ( MCACHE * mp,
int32 pgno,
int32 flags )
extern

◆ mcache_get_maxcache()

int32 mcache_get_maxcache ( MCACHE * mp)
extern

◆ mcache_get_npages()

int32 mcache_get_npages ( MCACHE * mp)
extern

◆ mcache_get_pagesize()

int32 mcache_get_pagesize ( MCACHE * mp)
extern

◆ mcache_new()

void * mcache_new ( MCACHE * mp,
int32 * pgnoaddr,
int32 flags )
extern

◆ mcache_open()

MCACHE * mcache_open ( void * key,
int32 object_id,
int32 pagesize,
int32 maxcache,
int32 npages,
int32 flags )
extern

◆ mcache_put()

int mcache_put ( MCACHE * mp,
void * page,
int32 flags )
extern

◆ mcache_set_maxcache()

int32 mcache_set_maxcache ( MCACHE * mp,
int32 maxcache )
extern

◆ mcache_sync()

int mcache_sync ( MCACHE * mp)
extern