#include "dfg.h"
#include "controller_dfg.h"
#include "scheduling.h"
#include "api.h"
#include "logging.h"
#include "runtime_messages.h"
#include "controller_stats.h"
#include "msu_ids.h"
#include "haproxy.h"
#include <unistd.h>
#include <stdlib.h>
#include <string.h>
#include <stdbool.h>
Go to the source code of this file.
struct dfg_msu* clone_msu |
( |
int |
msu_id | ) |
|
Clone a msu of given ID.
- Parameters
-
msu_id | id of the MSU to clone |
- Returns
- 0/-1 success/failure
Definition at line 619 of file scheduling.c.
static int downstream_q_len |
( |
struct dfg_msu * |
msu | ) |
|
|
static |
Find a suitable thread for an MSU.
- Parameters
-
dfg_runtime | *runtime: pointer to runtime endpoint |
int | colocation_group: colocation group ID to filter |
int | msu_type: MSU type ID to filter |
- Returns
- : pointer to dfg_thread or NULL
Definition at line 272 of file scheduling.c.
int fix_all_route_ranges |
( |
struct dedos_dfg * |
dfg | ) |
|
static int fix_route_ranges |
( |
struct dfg_route * |
route | ) |
|
|
static |
static int get_dependencies |
( |
struct dfg_msu * |
msu, |
|
|
struct dfg_msu ** |
output, |
|
|
int |
out_size |
|
) |
| |
|
static |
static double get_q_len |
( |
struct dfg_msu * |
msu | ) |
|
|
static |
int msu_hierarchical_sort |
( |
struct dfg_msu ** |
msus | ) |
|
Based on the meta routing, sort msus in a list in ascending order (from leaf to root)
- Parameters
-
struct | dfg_msu *msus: decayed pointer to a list of MSU pointers |
- Returns
- -1/0: failure/success
Definition at line 198 of file scheduling.c.
Find a core on which to spawn a new thread for an MSU.
- Parameters
-
dfg_runtime | the target runtime |
struct | dfg_msu_msu: the target MSU |
- Returns
- failure/success: -1/0
Definition at line 317 of file scheduling.c.
void prepare_clone |
( |
struct dfg_msu * |
msu | ) |
|
Find an ID and clean up data structures for an MSU.
- Parameters
-
- Returns
- none
Definition at line 260 of file scheduling.c.
static int remove_routes_to_msu |
( |
struct dfg_msu * |
msu | ) |
|
|
static |
Tries to place an MSU on a given runtime.
Will wire the MSU with all upstream and downstream MSU, enforcing locality constraints. Also, will spawn any missing dependency.
- Parameters
-
- Returns
- 0/-1 success/failure
Definition at line 710 of file scheduling.c.
int unclone_msu |
( |
int |
msu_id | ) |
|
int wire_msu |
( |
struct dfg_msu * |
msu | ) |
|