-
Notifications
You must be signed in to change notification settings - Fork 0
/
SchedulingAlgorithms.h
executable file
·63 lines (48 loc) · 1.66 KB
/
SchedulingAlgorithms.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
/*
* SchedulingAlgorithms.h
*
* Common header file for the scheduling algorithms
* test fixture project. Includes commonly-used
* definitions and macros.
*
* Created on: Mar 18, 2013
* Author: dam7633
*/
#ifndef SCHEDULINGALOGIRTHMS_H_
#define SCHEDULINGALOGIRTHMS_H_
// Configure this define to set the trace event log level.
#define TRACE_EVENT_LOG_LEVEL TRACE_EVENT_LOG_LEVEL_DEBUG
/**
* TRACE_EVENT_LOG_LEVEL
*
* The list of available logging levels for which this fixture can use.
*/
// No Trace Events will be logged.
#define TRACE_EVENT_LOG_LEVEL_SILENT 0
// Missed deadlines and other error messages will be logged.
#define TRACE_EVENT_LOG_LEVEL_CRITICAL 1
// Messages related to the scheduling operations.
#define TRACE_EVENT_LOG_LEVEL_NORMAL 2
// Messages related to performance testing.
#define TRACE_EVENT_LOG_LEVEL_DEBUG 3
/**
* TRACE_EVENT_LOG
*
* Use these macros around the appropriate Trace Event logging.
*/
#define TRACE_EVENT_LOG_EVAL(__x) (TRACE_EVENT_LOG_LEVEL >= __x)
#define TRACE_EVENT_LOG_CRITICAL TRACE_EVENT_LOG_EVAL(TRACE_EVENT_LOG_CRITICAL)
#define TRACE_EVENT_LOG_NORMAL TRACE_EVENT_LOG_EVAL(TRACE_EVENT_LOG_LEVEL_NORMAL)
#define TRACE_EVENT_LOG_DEBUG TRACE_EVENT_LOG_EVAL(TRACE_EVENT_LOG_LEVEL_DEBUG)
/**
* TRACE_EVENT_CODE
*
* Enumeration of trace event types used by this fixture.
*/
#define TRACE_EVENT_SCHEDULING_START 10
#define TRACE_EVENT_SCHEDULING_END 11
#define TRACE_EVENT_TASK_START 20
#define TRACE_EVENT_TASK_END 21
#define TRACE_EVENT_DEADLINE_TIMER 30
#define TRACE_EVENT_DEADLINE_MISS 31
#endif /* SCHEDULINGALOGIRTHMS_H_ */