-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathscheduler_pcb.h
More file actions
35 lines (31 loc) · 776 Bytes
/
scheduler_pcb.h
File metadata and controls
35 lines (31 loc) · 776 Bytes
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
/*
* Author: Daiki Kubo
* Student ID: 30523346
* Description of the program:
* This is a .h file that contains a data structure used to
* represent a process control block that has vital information for
* process scheduling.
* Start Date: 1st of October
* Last modified: 8th of October
*/
/* enum, used to indicate a process state */
typedef enum {
READY = 0, RUNNING = 1, EXIT = 2
} process_state_t;
/*
* A simplified model of process control block, which holds
* some vital information upon running process in the system.
*/
typedef struct {
char process_name[11];
int entryTime;
int serviceTime;
int remainingTime;
int deadLine;
int startTime;
int completeTime;
int waitTime;
int turnaroundTime;
int ddlMet;
process_state_t state;
} pcb_t;