MOS Source Code
Loading...
Searching...
No Matches
naive.cpp File Reference
+ Include dependency graph for naive.cpp:

Go to the source code of this file.

Classes

struct  naive_sched_t
 
struct  naive_sched_node_t
 Node in the naive scheduler's list of threads. More...
 

Functions

static void naive_sched_init (scheduler_t *instance)
 
static Threadnaive_sched_select_next (scheduler_t *instance)
 
static void naive_sched_add_thread (scheduler_t *instance, Thread *thread)
 
static void naive_sched_remove_thread (scheduler_t *instance, Thread *thread)
 
 MOS_PUT_IN_SECTION (".mos.schedulers", scheduler_info_t, MOS_CONCAT(naive, __COUNTER__), { .name="naive",.scheduler=&naive_sched.base })
 

Variables

static const scheduler_ops_t naive_sched_ops
 
static naive_sched_t naive_sched
 

Function Documentation

◆ naive_sched_init()

static void naive_sched_init ( scheduler_t * instance)
static

Definition at line 24 of file naive.cpp.

+ Here is the call graph for this function:

◆ naive_sched_select_next()

static Thread * naive_sched_select_next ( scheduler_t * instance)
static

Definition at line 32 of file naive.cpp.

+ Here is the call graph for this function:

◆ naive_sched_add_thread()

static void naive_sched_add_thread ( scheduler_t * instance,
Thread * thread )
static

Definition at line 58 of file naive.cpp.

+ Here is the call graph for this function:

◆ naive_sched_remove_thread()

static void naive_sched_remove_thread ( scheduler_t * instance,
Thread * thread )
static

Definition at line 73 of file naive.cpp.

◆ MOS_PUT_IN_SECTION()

MOS_PUT_IN_SECTION ( ".mos.schedulers" ,
scheduler_info_t ,
MOS_CONCAT(naive, __COUNTER__) ,
{ .name="naive",.scheduler=&naive_sched.base }  )

Variable Documentation

◆ naive_sched_ops

const scheduler_ops_t naive_sched_ops
static
Initial value:
= {
.select_next = naive_sched_select_next,
.add_thread = naive_sched_add_thread,
.remove_thread = naive_sched_remove_thread,
}
static Thread * naive_sched_select_next(scheduler_t *instance)
Definition naive.cpp:32
static void naive_sched_remove_thread(scheduler_t *instance, Thread *thread)
Definition naive.cpp:73
static void naive_sched_add_thread(scheduler_t *instance, Thread *thread)
Definition naive.cpp:58
static void naive_sched_init(scheduler_t *instance)
Definition naive.cpp:24

Definition at line 91 of file naive.cpp.

◆ naive_sched

naive_sched_t naive_sched
static
Initial value:
= {
.base = { .ops = &naive_sched_ops },
}
static const scheduler_ops_t naive_sched_ops
Definition naive.cpp:91

Definition at line 98 of file naive.cpp.

Referenced by MOS_PUT_IN_SECTION(), naive_sched_add_thread(), naive_sched_init(), naive_sched_remove_thread(), and naive_sched_select_next().