Barrelfish
Data Structures | Typedefs | Functions
tweed.h File Reference

A simple work stealing library based upon both cilk and wool. More...

Data Structures

struct  generic_task_desc
 
struct  main_task_desc
 
struct  worker_desc
 

Typedefs

typedef void(* tweed_task_func_t) (struct generic_task_desc *_tweed_top_, void *task)
 

Functions

int init_tweed (int workers_requested, int(*main_func)(struct generic_task_desc *, void *), void *main_args)
 
struct generic_task_descset_top (void)
 
int sync_stolen (struct generic_task_desc *_tweed_top_)
 
int handle_stolen_task (struct generic_task_desc *_tweed_top_)
 

Detailed Description

A simple work stealing library based upon both cilk and wool.

Typedef Documentation

typedef void(* tweed_task_func_t) (struct generic_task_desc *_tweed_top_, void *task)

Task wrapper function type

Function Documentation

int handle_stolen_task ( struct generic_task_desc _tweed_top_)

Handle stolen task

int init_tweed ( int  workers_requested,
int(*)(struct generic_task_desc *, void *)  main_func,
void *  main_args 
)

Initialise the tweed library - must be called before any other tweed calls

struct generic_task_desc* set_top ( void  )

Initializes tweed_top to start of this worker's task block

int sync_stolen ( struct generic_task_desc _tweed_top_)

Check if syncing task really is stolen