ROSS
hash-quadratic.c File Reference
#include <ross.h>
#include "avl_tree.h"

Go to the source code of this file.

Functions

static int is_prime (int ptst)
tw_eventhash_search (tw_event **hash_t, tw_event *evt, int size)
void hash_print (tw_hash *h)
void * tw_hash_create ()
void tw_hash_insert (void *h, tw_event *event, long pe)
tw_eventtw_hash_remove (void *h, tw_event *event, long pe)
int next_prime (int ptst)

Variables

static unsigned int ncpu = 1
unsigned int g_tw_hash_size = 31

Function Documentation

◆ hash_print()

void hash_print ( tw_hash * h)

Definition at line 306 of file hash-quadratic.c.

References tw_hash::hash_sizes, tw_hash::incoming, ncpu, and tw_hash::num_stored.

◆ hash_search()

tw_event * hash_search ( tw_event ** hash_t,
tw_event * evt,
int size )

Definition at line 283 of file hash-quadratic.c.

References tw_event::event_id, and g_tw_mynode.

◆ is_prime()

int is_prime ( int ptst)
static

Definition at line 259 of file hash-quadratic.c.

Referenced by next_prime(), and tw_hash_create().

◆ next_prime()

int next_prime ( int ptst)

Definition at line 239 of file hash-quadratic.c.

References is_prime().

Referenced by tw_hash_create().

◆ tw_hash_create()

◆ tw_hash_insert()

void tw_hash_insert ( void * h,
tw_event * event,
long pe )

◆ tw_hash_remove()

Variable Documentation

◆ g_tw_hash_size

unsigned int g_tw_hash_size = 31

Definition at line 21 of file hash-quadratic.c.

Referenced by tw_hash_create().

◆ ncpu

unsigned int ncpu = 1
static

Definition at line 20 of file hash-quadratic.c.

Referenced by hash_print(), and tw_hash_create().