Staircase cpu scheduler v14.2
Subsystems (2)
PATCH 1/1 Staircase cpu scheduler v14.2
Just as a reminder, the staircase cpu scheduler is still in active development. While included in the -ck patchset, the standalone patch can be downloaded here:
http://ck.kolivas.org/patches/staircase/
Here is the current base staircase patch for 2.6.16
Cheers,
Con
--- fs/proc/array.c | 4 include/linux/sched.h | 12 kernel/exit.c | 1 kernel/sched.c | 966 +++++++++++++++++--------------------------------- 4 files changed, 349 insertions(+), 634 deletions(-)
fs/proc/array.c +2 -2
@@ -165,7 +165,7 @@ static inline char * task_state(struct tread_lock (&tasklist_lock); buffer +=sprintf (buffer,"State:\t%s\n" -"SleepAVG:\t%lu%%\n" +"Bonus:\t%d\n" "Tgid:\t%d\n" "Pid:\t%d\n" "PPid:\t%d\n"
@@ -173,7 +173,7 @@ static inline char * task_state(struct t"Uid:\t%d\t%d\t%d\t%d\n" "Gid:\t%d\t%d\t%d\t%d\n" ,get_task_state (p), - (p->sleep_avg/1024 )*100 /(1020000000 /1024 ), + p->bonus, p->tgid, p->pid,pid_alive (p) ? p->group_leader->real_parent->tgid :0 , pid_alive(p) && p->ptrace ? p->parent->pid : 0,
include/linux/sched.h +5 -7
@@ -521,7 +521,6 @@ extern struct user_struct *find_user(uidextern struct user_struct root_user;#define INIT_USER (&root_user) -typedef struct prio_array prio_array_t ;struct backing_dev_info ;struct reclaim_state ;
@@ -703,18 +702,17 @@ struct task_struct {#endif int prio, static_prio;struct list_head run_list; -prio_array_t *array;unsigned short ioprio; -unsigned long sleep_avg; -unsigned long long timestamp, last_ran; +unsigned long long timestamp; +unsigned long runtime, totalrun, ns_debit; +unsigned int bonus; +unsigned int slice, time_slice;unsigned long long sched_time;/* sched_clock time spent running */ -int activated;unsigned long policy;cpumask_t cpus_allowed; -unsigned int time_slice, first_time_slice;#ifdef CONFIG_SCHEDSTATS struct sched_info sched_info;
@@ -928,6 +926,7 @@ static inline void put_task_struct(struc#define PF_BORROWED_MM 0x00400000/* I am a kthread doing use_mm */ #define PF_RANDOMIZE 0x00800000/* randomize virtual address space */ #define PF_SWAPWRITE 0x01000000/* Allowed to write to swap */ +#define PF_NONSLEEP 0x02000000/* Waiting on in kernel activity */ /* * Only the _current_ task can read/write to tsk->flags, but other
@@ -1049,7 +1048,6 @@ extern void FASTCALL(wake_up_new_task(ststatic inline void kick_process (struct task_struct *tsk) { }#endif extern void FASTCALL (sched_fork (task_t * p,int clone_flags)); -extern void FASTCALL (sched_exit (task_t * p));extern int in_group_p (gid_t );extern int in_egroup_p (gid_t );
kernel/exit.c +0 -1
@@ -102,7 +102,6 @@ repeat: zap_leader = (leader->exit_signal ==-1 ); } -sched_exit (p);write_unlock_irq (&tasklist_lock);spin_unlock (&p->proc_lock);proc_pid_flush (proc_dentry);
kernel/sched.c +342 -624
1,483 lines not on this page · raw message