summaryrefslogtreecommitdiff
path: root/src/til_module_context.h
blob: 6f4339b5bd09df98e8ad14c925d6ac0eba041b4c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#ifndef _TIL_MODULE_CONTEXT_H
#define _TIL_MODULE_CONTEXT_H

#include <stdint.h>

typedef struct til_module_context_t til_module_context_t;
typedef struct til_module_t til_module_t;
typedef struct til_stream_t til_stream_t;

struct til_module_context_t {
	const til_module_t	*module;
	til_stream_t		*stream; /* optional stream this context is part of */
	unsigned		seed;
	unsigned		ticks;
	unsigned		n_cpus;
	char			*path;	/* for locating this instance of the module, NOT a file path */
	uint32_t		path_hash;
};

void * til_module_context_new(til_stream_t *stream, size_t size, unsigned seed, unsigned ticks, unsigned n_cpus, char *path);
void * til_module_context_free(til_module_context_t *module_context);

#endif
© All Rights Reserved