21 lines
333 B
C
21 lines
333 B
C
#ifndef RT_JOBS_H
|
|
#define RT_JOBS_H
|
|
|
|
/* Work stealing job scheduler */
|
|
|
|
#include "runtime.h"
|
|
|
|
#include <stdint.h>
|
|
|
|
typedef void rt_job_fn(void *param, uint32_t iteration);
|
|
|
|
typedef struct {
|
|
uint32_t iterations;
|
|
rt_job_fn *fn;
|
|
void *param;
|
|
} rt_job_decl;
|
|
|
|
RT_DLLEXPORT void rtDispatchJob(const rt_job_decl *decl);
|
|
|
|
#endif
|