Status of sedf?
I am running xen-2.0-testing and would like to use the sedf scheduler, which is only in unstable right now. When will sedf appear in 2.0-testing? Or could I copy unstable's xen/common/sched* into testing and recompile?
Thanks,
Andy
Quoted 3 lines
I am running xen-2.0-testing and would like to use the sedf scheduler, which is only in unstable right now. When will sedf appear in 2.0-testing?
I don't think it's planned to be included but there again I don't think anyone has asked... -testing generally only accepts bug fixes now (a bit like the Linux 2.6.x.y series). -unstable is a separate project to produce Xen 3.0 and so features aren't generally backported.
Quoted 2 lines
Or could I copy unstable's xen/common/sched* into testing and recompile?
There's a thought... That might *almost* work but there may be other internal API changes that stop it working prorperly.
-unstable will go into feature freeze in the next couple of months anyhow, so you won't have to wait long before you can get a release with the new scheduler.
Cheers,
Mark
Quoted 8 lines
Thanks,
Andy_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Quoted 6 lines
Quoted 6 lines
I am running xen-2.0-testing and would like to use the sedf scheduler,
which is only in unstable right now. When will sedf appear in 2.0-testing?
It was not planed to release the sedf scheduler for 2.0-testing. But as some people have been asking about that, I might see what I can do!
Quoted 8 lines
Quoted 4 lines
Or could I copy unstable's xen/common/sched* into testing and recompile?
There's a thought... That might *almost* work but there may be other
internal
Quoted 4 lines
API changes that stop it working prorperly.
That would not work, as some fundamental changes have been made in the general scheduling API and in the names of datastructures etc. (see domains -> exec_domains -> vcpus, ...)
Cheers,
Stephan
Quoted 7 lines
Quoted 4 lines
Quoted 4 lines
I am running xen-2.0-testing and would like to use the sedf scheduler,
which is only in unstable right now. When will sedf appear in 2.0-testing?
It was not planed to release the sedf scheduler for 2.0-testing. But as some people have been asking about that, I might see what I can do!
That's cool!
Quoted 5 lines
Quoted 4 lines
Quoted 2 lines
Or could I copy unstable's xen/common/sched* into testing and recompile?
There's a thought... That might *almost* work but there may be other
Quoted 7 lines
internal
Quoted 1 line
API changes that stop it working prorperly.
That would not work, as some fundamental changes have been made in the general scheduling API and in the names of datastructures etc. (see domains ->
exec_domains-> vcpus, ...)
I wasn't sure how much drift had occurred in the scheduling API but I thought the raft of renames and restructuring might have broken things. Ah well... Roll on 3.0 :-)
Cheers,
Mark
Quoted 7 lines
Quoted 5 lines
Quoted 5 lines
I am running xen-2.0-testing and would like to use the sedf scheduler, which is only in unstable right now. When will sedf appear in 2.0-testing?
It was not planed to release the sedf scheduler for 2.0-testing. But as some people have been asking about that, I might see what I can do!
Thank you! If it's not too much work for you, that would be fantastic! Although 3.0 is just around the corner, I might hold off upgrading until 3.0.1 due to my bias against initial releases. :-)
Sorry for that late reply...
I'm quite busy fixing bugs for 3.0, so I just quickly tried some old diff and merged it with the current repository. Compiles, but not sure whether it works (esp. control tools).
Please try it out!
Cheers,
Stephan
P.S.: The code contains the most serious bugfixes, but again, it might contain bugs!
Quoted 16 lines
Quoted 6 lines
Quoted 3 lines
Quoted 3 lines
I am running xen-2.0-testing and would like to use the sedf scheduler, which is only in unstable right now. When will sedf appear in 2.0-testing?
It was not planed to release the sedf scheduler for 2.0-testing. But as some people have been asking about that, I might see what I can do!
Thank you! If it's not too much work for you, that would be fantastic! Although 3.0 is just around the corner, I might hold off upgrading until 3.0.1 due to my bias against initial releases. :-)
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
It was a long day...
This time with the patch!
Sorry,
Stephan
Signed-off by: Stephan.Diestelhorst@{cl.cam.ac.uk, inf.tu-dresden.de}
Quoted 29 lines
Sorry for that late reply...
I'm quite busy fixing bugs for 3.0, so I just quickly tried some old diff and merged it with the current repository. Compiles, but not sure whether it works (esp. control tools).
Please try it out!Cheers,
Stephan
P.S.: The code contains the most serious bugfixes, but again, it might contain bugs!Quoted 12 lines
Quoted 6 lines
Quoted 3 lines
Quoted 3 lines
I am running xen-2.0-testing and would like to use the sedf scheduler, which is only in unstable right now. When will sedf appear in 2.0-testing?
It was not planed to release the sedf scheduler for 2.0-testing. But as some people have been asking about that, I might see what I can do!
Thank you! If it's not too much work for you, that would be fantastic! Although 3.0 is just around the corner, I might hold off upgrading until 3.0.1 due to my bias against initial releases. :-)
Quoted 4 lines
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Quoted 4 lines
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
tools/libxc/Makefile +1 -0
@@ -16,6 +16,7 @@ INCLUDES += -I $(XEN_LIBXUTIL) SRCS := +SRCS += xc_sedf.c SRCS += xc_atropos.c SRCS += xc_bvtsched.c SRCS += xc_domain.c
tools/libxc/xc.h +8 -0
@@ -245,6 +245,14 @@int xc_rrobin_global_get (int xc_handle,u64 *slice); +int xc_sedf_domain_set (int xc_handle, +u32 domid, +u64 period,u64 slice,u64 latency,u16 extratime,u16 weight); + +int xc_sedf_domain_get (int xc_handle, +u32 domid, +u64 * period,u64 *slice,u64 *latency,u16 *extratime,u16 * weight); +typedef evtchn_status_t xc_evtchn_status_t ;/*\
tools/python/xen/lowlevel/xc/xc.c +70 -0
82 lines not on this page · raw message
tools/python/xen/xend/XendClient.py +9 -0
@@ -272,6 +272,15 @@ 'slice' : slice, 'latency' : latency, 'xtratime': xtratime }) + + def xend_domain_cpu_sedf_set(self, id, period, slice, latency, extratime, weight): + return self.xendPost(self.domainurl(id), + {'op' : 'cpu_sedf_set', + 'period' : period, + 'slice' : slice, + 'latency' : latency, + 'extratime' : extratime, + 'weight' : weight }) def xend_domain_maxmem_set(self, id, memory): return self.xendPost(self.domainurl(id),
tools/python/xen/xend/XendDomain.py +18 -0
@@ -663,6 +663,24 @@ return xc.atropos_domain_get(dominfo.dom) except Exception, ex: raise XendError(str(ex)) + + def domain_cpu_sedf_set(self, id, period, slice, latency, extratime, weight): + """Set Simple EDF scheduler parameters for a domain. + """ + dominfo = self.domain_lookup(id) + try: + return xc.sedf_domain_set(dominfo.dom, period, slice, latency, extratime, weight) + except Exception, ex: + raise XendError(str(ex)) + + def domain_cpu_sedf_get(self, id): + """Get Atropos scheduler parameters for a domain. + """ + dominfo = self.domain_lookup(id) + try: + return xc.sedf_domain_get(dominfo.dom) + except Exception, ex: + raise XendError(str(ex)) def domain_device_create(self, id, devconfig): """Create a new device for a domain.
tools/python/xen/xend/server/SrvDomain.py +11 -0
@@ -114,6 +114,17 @@ ['slice', 'int'], ['latency', 'int'], ['xtratime', 'int']]) + val = fn(req.args, {'dom': self.dom.id}) + return val + + def op_cpu_sedf_set(self, op, req): + fn = FormFn(self.xd.domain_cpu_sedf_set, + [['dom', 'str'], + ['period', 'int'], + ['slice', 'int'], + ['latency', 'int'], + ['extratime', 'int'], + ['weight', 'int']]) val = fn(req.args, {'dom': self.dom.id}) return val
tools/python/xen/xm/main.py +17 -0
@@ -600,6 +600,23 @@ xm.prog(ProgRrobin) +class ProgSedf(Prog): + group = 'scheduler' + name= "sedf" + info = """Set simple EDF parameters.""" + + def help(self, args): + print args[0], "DOM PERIOD SLICE LATENCY EXTRATIME WEIGHT" + print "\nSet simple EDF parameters." + + def main(self, args): + if len(args) != 7: self.err("%s: Invalid argument(s)" % args[0]) + dom = args[1] + v = map(int, args[2:7]) + server.xend_domain_cpu_sedf_set(dom, *v) + +xm.prog(ProgSedf) + class ProgInfo(Prog): group = 'host' name = "info"
xen/common/schedule.c +89 -5
166 lines not on this page · raw message
xen/include/public/sched_ctl.h +11 -0
@@ -11,6 +11,7 @@#define SCHED_BVT 0#define SCHED_ATROPOS 2#define SCHED_RROBIN 3 +#define SCHED_SEDF 4/* these describe the intended direction used for a scheduler control or domain * command */
@@ -64,6 +65,16 @@u64 latency;/* 32 */ u32 xtratime;/* 36 */ }PACKED atropos; + +struct sedf_adjdom + { +u64 period;/* 16 */ +u64 slice;/* 24 */ +u64 latency;/* 32 */ +u16 extratime;/* 36 */ +u16 weight;/* 38 */ + } PACKED sedf; + }PACKED u; }PACKED ;/* 40 bytes */
xen/include/xen/sched-if.h +8 -3
@@ -7,7 +7,9 @@* Portions by Mark Williamson are (C) 2004 Intel Research Cambridge */ -#define BUCKETS 10 +//#define ADV_SCHED_HISTO +#define BUCKETS 10 +/*300*/ typedef struct schedule_data_st {
@@ -17,6 +19,11 @@struct domain *idle;/* idle task for this cpu */ void * sched_priv;struct ac_timer s_timer;/* scheduling timer */ +#ifdef ADV_SCHED_HISTO +u32 to_hist[BUCKETS ]; +u32 from_hist[BUCKETS ]; +u64 save_tsc; +#endif #ifdef BUCKETS u32 hist[BUCKETS ];/* for scheduler latency histogram */ #endif
@@ -55,5 +62,3 @@/* per CPU scheduler information */ extern schedule_data_t schedule_data[]; - -
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Quoted 17 lines · Stephan
Quoted 17 lines
Quoted 11 lines
Quoted 7 lines
Quoted 4 lines
Quoted 4 lines
I am running xen-2.0-testing and would like to use the sedf scheduler, which is only in unstable right now. When will sedf appear in 2.0-testing?
It was not planed to release the sedf scheduler for 2.0-testing. But as some people have been asking about that, I might see what I can do!
Thank you! If it's not too much work for you, that would be fantastic! Although 3.0 is just around the corner, I might hold off upgrading until 3.0.1 due to my bias against initial releases. :-)
I'm quite busy fixing bugs for 3.0, so I just quickly tried some old diff and merged it with the current repository. Compiles, but not sure whether it works (esp. control tools).
Please try it out!
Quoted 5 lines
Quoted 5 lines
Cheers,
Stephan
P.S.: The code contains the most serious bugfixes, but again, it might contain bugs!
Sorry to report that the patch didn't work. I applied the patch to my Xen-2.0-testing tree and copied xen/common/sched_sedf.c from Xen-unstable. When compiling xen, sched_sedf.c generated these types of errors:
(1) dereferencing pointer to incomplete type (a lot of these)
(2) `PRIu64' undeclared (first use in this function)
See attachment for the complete list. So Mark is right. The API differences between testing and unstable is significant enough that back porting sched_sedf will involve more work. But thank you for trying!
Quoted 24 lines · At 03:11 PM 8/17/2005, I wrote:
Quoted 17 lines · Stephan
Quoted 17 lines
Quoted 11 lines
Quoted 7 lines
Quoted 4 lines
Quoted 4 lines
I am running xen-2.0-testing and would like to use the sedf scheduler, which is only in unstable right now. When will sedf appear in 2.0-testing?
It was not planed to release the sedf scheduler for 2.0-testing. But as some people have been asking about that, I might see what I can do!
Thank you! If it's not too much work for you, that would be fantastic! Although 3.0 is just around the corner, I might hold off upgrading until 3.0.1 due to my bias against initial releases. :-)
I'm quite busy fixing bugs for 3.0, so I just quickly tried some old diff and merged it with the current repository. Compiles, but not sure whether it works (esp. control tools).
Please try it out!Quoted 5 lines
Quoted 5 lines
Cheers,
Stephan
P.S.: The code contains the most serious bugfixes, but again, it might contain bugs!
Quoted 6 lines
Sorry to report that the patch didn't work. I applied the patch to my Xen-2.0-testing tree and copied
xen/common/sched_sedf.cfrom Xen-unstable. When compiling xen,sched_sedf.cgenerated these types of errors:(1) dereferencing pointer to incomplete type (a lot of these)
(2) `PRIu64' undeclared (first use in this function)See attachment for the complete list. So Mark is right. The API differences between testing and unstable is significant enough that back porting
sched_sedfwill involve more work. But thank you for trying!
Oops, forgot the attachment. Here it is.
sched_sedf.c: In function `extraq_on':
sched_sedf.c:144: error: dereferencing pointer to incomplete type
sched_sedf.c:145: error: dereferencing pointer to incomplete type
sched_sedf.c:145: error: dereferencing pointer to incomplete typesched_sedf.c: In function `extraq_add_head':
sched_sedf.c:150: error: dereferencing pointer to incomplete type
sched_sedf.c:150: error: dereferencing pointer to incomplete typesched_sedf.c: In function `extraq_add_tail':
sched_sedf.c:156: error: dereferencing pointer to incomplete type
sched_sedf.c:156: error: dereferencing pointer to incomplete typesched_sedf.c: In function `extraq_del':
sched_sedf.c:162: error: dereferencing pointer to incomplete type
sched_sedf.c:164: error: dereferencing pointer to incomplete type
sched_sedf.c:164: error: dereferencing pointer to incomplete typesched_sedf.c: In function `extraq_add_sort_update':
sched_sedf.c:182: error: syntax error before "PRIi64"
sched_sedf.c:182: error: `PRIi64' undeclared (first use in this function) sched_sedf.c:182: error: (Each undeclared identifier is reported only once sched_sedf.c:182: error: for each function it appears in.)
sched_sedf.c:188: error: dereferencing pointer to incomplete type
sched_sedf.c:188: error: dereferencing pointer to incomplete type
sched_sedf.c:191: error: dereferencing pointer to incomplete type
sched_sedf.c:194: error: dereferencing pointer to incomplete type
sched_sedf.c:194: error: dereferencing pointer to incomplete type
sched_sedf.c:200: error: dereferencing pointer to incomplete type
sched_sedf.c:203: error: dereferencing pointer to incomplete type
sched_sedf.c:204: error: dereferencing pointer to incomplete type
sched_sedf.c:209: error: dereferencing pointer to incomplete type
sched_sedf.c:209: error: dereferencing pointer to incomplete typesched_sedf.c: In function `extraq_check':
sched_sedf.c:217: error: dereferencing pointer to incomplete type
sched_sedf.c:217: error: dereferencing pointer to incomplete type
sched_sedf.c:218: error: dereferencing pointer to incomplete type
sched_sedf.c:219: error: dereferencing pointer to incomplete type
sched_sedf.c:221: error: dereferencing pointer to incomplete type
sched_sedf.c:221: error: dereferencing pointer to incomplete type
sched_sedf.c:225: error: dereferencing pointer to incomplete type
sched_sedf.c:225: error: dereferencing pointer to incomplete type
sched_sedf.c:227: error: dereferencing pointer to incomplete type
sched_sedf.c:227: error: dereferencing pointer to incomplete type
sched_sedf.c:237: error: dereferencing pointer to incomplete type
sched_sedf.c:237: error: dereferencing pointer to incomplete typesched_sedf.c: In function `extraq_check_add_unblocked':
sched_sedf.c:245: error: dereferencing pointer to incomplete typesched_sedf.c: In function `__task_on_queue':
sched_sedf.c:263: error: dereferencing pointer to incomplete type
sched_sedf.c:263: error: dereferencing pointer to incomplete type
sched_sedf.c:263: error: dereferencing pointer to incomplete typesched_sedf.c: In function `__del_from_queue':
sched_sedf.c:267: error: dereferencing pointer to incomplete type
sched_sedf.c:269: error: syntax error before "PRIu64"
sched_sedf.c:269: error: PRIu64' undeclared (first use in this function) sched_sedf.c: In function __add_to_waitqueue_sort':
sched_sedf.c:310: error: syntax error before "PRIu64"
sched_sedf.c:310: error: `PRIu64' undeclared (first use in this function) sched_sedf.c:312: error: dereferencing pointer to incomplete type
sched_sedf.c:312: error: dereferencing pointer to incomplete typesched_sedf.c: In function `__add_to_runqueue_sort':
sched_sedf.c:323: error: syntax error before "PRIu64"
sched_sedf.c:323: error: `PRIu64' undeclared (first use in this function) sched_sedf.c:325: error: dereferencing pointer to incomplete type
sched_sedf.c:325: error: dereferencing pointer to incomplete typesched_sedf.c: In function `sedf_alloc_task':
sched_sedf.c:330: error: dereferencing pointer to incomplete type
sched_sedf.c:330: error: dereferencing pointer to incomplete type
sched_sedf.c:332: error: dereferencing pointer to incomplete type
sched_sedf.c:333: error: dereferencing pointer to incomplete type
sched_sedf.c:334: error: syntax error before "struct"
sched_sedf.c:336: error: dereferencing pointer to incomplete type
sched_sedf.c:336: error: dereferencing pointer to incomplete type
sched_sedf.c:336: error: dereferencing pointer to incomplete type
sched_sedf.c:336: error: dereferencing pointer to incomplete type
sched_sedf.c:338: error: dereferencing pointer to incomplete type
sched_sedf.c:338: error: syntax error before "struct"
sched_sedf.c:340: error: dereferencing pointer to incomplete type
sched_sedf.c:340: error: dereferencing pointer to incomplete type
sched_sedf.c:340: error: dereferencing pointer to incomplete type
sched_sedf.c:340: error: dereferencing pointer to incomplete typesched_sedf.c: In function `sedf_add_task':
sched_sedf.c:347: error: dereferencing pointer to incomplete type
sched_sedf.c:350: error: dereferencing pointer to incomplete type
sched_sedf.c:350: error: dereferencing pointer to incomplete type
sched_sedf.c:354: error: dereferencing pointer to incomplete type
sched_sedf.c:356: error: dereferencing pointer to incomplete type
sched_sedf.c:357: error: syntax error before "struct"
sched_sedf.c:358: warning: implicit declaration of function `BUG_ON' sched_sedf.c:358: error: dereferencing pointer to incomplete type
sched_sedf.c:359: error: dereferencing pointer to incomplete type
sched_sedf.c:359: error: dereferencing pointer to incomplete type
sched_sedf.c:359: error: dereferencing pointer to incomplete type
sched_sedf.c:359: error: dereferencing pointer to incomplete type
sched_sedf.c:359: error: dereferencing pointer to incomplete type
sched_sedf.c:359: error: dereferencing pointer to incomplete type
sched_sedf.c:359: error: dereferencing pointer to incomplete type
sched_sedf.c:359: error: dereferencing pointer to incomplete type
sched_sedf.c:359: error: dereferencing pointer to incomplete type
sched_sedf.c:359: error: dereferencing pointer to incomplete type
sched_sedf.c:360: error: dereferencing pointer to incomplete type
sched_sedf.c:360: error: dereferencing pointer to incomplete type
sched_sedf.c:360: error: dereferencing pointer to incomplete type
sched_sedf.c:360: error: dereferencing pointer to incomplete type
sched_sedf.c:361: error: dereferencing pointer to incomplete type
sched_sedf.c:361: error: dereferencing pointer to incomplete type
sched_sedf.c:361: error: dereferencing pointer to incomplete type
sched_sedf.c:361: error: dereferencing pointer to incomplete type
sched_sedf.c:362: error: dereferencing pointer to incomplete type
sched_sedf.c:362: error: dereferencing pointer to incomplete type
sched_sedf.c:362: error: dereferencing pointer to incomplete type
sched_sedf.c:362: error: dereferencing pointer to incomplete type
sched_sedf.c:363: error: dereferencing pointer to incomplete type
sched_sedf.c:363: error: dereferencing pointer to incomplete type
sched_sedf.c:363: error: dereferencing pointer to incomplete type
sched_sedf.c:363: error: dereferencing pointer to incomplete type
sched_sedf.c:366: error: dereferencing pointer to incomplete type
sched_sedf.c:387: error: dereferencing pointer to incomplete type
sched_sedf.c:387: error: dereferencing pointer to incomplete type
sched_sedf.c:390: error: dereferencing pointer to incomplete type
sched_sedf.c:391: error: dereferencing pointer to incomplete typesched_sedf.c: In function `sedf_free_task':
sched_sedf.c:399: error: structure has no member named `domain_id'
sched_sedf.c:404: error: structure has no member named `vcpu'
sched_sedf.c:406: error: structure has no member named `vcpu'sched_sedf.c: In function `desched_edf_dom':
sched_sedf.c:412: error: dereferencing pointer to incomplete type
sched_sedf.c:421: error: dereferencing pointer to incomplete type
sched_sedf.c:453: error: dereferencing pointer to incomplete typesched_sedf.c: In function `update_queues':
sched_sedf.c:480: error: dereferencing pointer to incomplete type
sched_sedf.c:480: error: dereferencing pointer to incomplete type
sched_sedf.c:495: error: dereferencing pointer to incomplete type
sched_sedf.c:495: error: dereferencing pointer to incomplete type
sched_sedf.c:499: error: dereferencing pointer to incomplete type
sched_sedf.c:499: error: dereferencing pointer to incomplete type
sched_sedf.c:515: error: syntax error before "PRIu64"
sched_sedf.c:515: error: PRIu64' undeclared (first use in this function) sched_sedf.c: In function desched_extra_dom':
sched_sedf.c:555: error: dereferencing pointer to incomplete type
sched_sedf.c:584: error: syntax error before "PRIi64"
sched_sedf.c:584: error: `PRIi64' undeclared (first use in this function) sched_sedf.c:588: error: dereferencing pointer to incomplete type
sched_sedf.c:588: error: dereferencing pointer to incomplete type
sched_sedf.c:618: error: dereferencing pointer to incomplete typesched_sedf.c: At top level:
sched_sedf.c:645: error: return type is an incomplete typesched_sedf.c: In function `sedf_do_extra_schedule':
sched_sedf.c:646: error: storage size of `ret' isn't known
sched_sedf.c:680: warning: return' with a value, in function returning void sched_sedf.c:687: warning: return' with a value, in function returning void sched_sedf.c:646: warning: unused variable `ret'sched_sedf.c: At top level:
sched_sedf.c:695: error: return type is an incomplete typesched_sedf.c: In function `sedf_do_schedule':
sched_sedf.c:704: error: storage size of `ret' isn't known
sched_sedf.c:707: error: structure has no member named `domain'
sched_sedf.c:707: error: structure has no member named `domain'
sched_sedf.c:722: warning: passing arg 2 of desched_extra_dom' from incompatible pointer type sched_sedf.c:727: warning: passing arg 2 of desched_edf_dom' from incompatible pointer type sched_sedf.c:780: error: syntax error before "PRIi64"
sched_sedf.c:788: warning: return' with a value, in function returning void sched_sedf.c:704: warning: unused variable ret'sched_sedf.c: In function `sedf_sleep':
sched_sedf.c:792: error: dereferencing pointer to incomplete type
sched_sedf.c:792: error: dereferencing pointer to incomplete type
sched_sedf.c:794: error: dereferencing pointer to incomplete type
sched_sedf.c:794: error: dereferencing pointer to incomplete type
sched_sedf.c:797: error: dereferencing pointer to incomplete type
sched_sedf.c:799: error: `_VCPUF_running' undeclared (first use in this function) sched_sedf.c:799: error: dereferencing pointer to incomplete type
sched_sedf.c:799: error: dereferencing pointer to incomplete type
sched_sedf.c:800: error: dereferencing pointer to incomplete typesched_sedf.c: In function `get_run_type':
sched_sedf.c:1064: error: dereferencing pointer to incomplete type
sched_sedf.c:1065: error: dereferencing pointer to incomplete type
sched_sedf.c:1065: error: dereferencing pointer to incomplete typesched_sedf.c: In function `should_switch':
sched_sedf.c:1085: error: dereferencing pointer to incomplete type
sched_sedf.c:1086: error: dereferencing pointer to incomplete type
sched_sedf.c:1090: error: dereferencing pointer to incomplete typesched_sedf.c: In function `sedf_wake':
sched_sedf.c:1118: error: dereferencing pointer to incomplete type
sched_sedf.c:1120: error: dereferencing pointer to incomplete type
sched_sedf.c:1120: error: dereferencing pointer to incomplete type
sched_sedf.c:1123: error: dereferencing pointer to incomplete type
sched_sedf.c:1123: error: dereferencing pointer to incomplete type
sched_sedf.c:1127: error: dereferencing pointer to incomplete type
sched_sedf.c:1127: error: dereferencing pointer to incomplete type
sched_sedf.c:1140: error: syntax error before "PRIu64"
sched_sedf.c:1140: error: `PRIu64' undeclared (first use in this function) sched_sedf.c:1202: error: syntax error before "PRIu64"
sched_sedf.c:1231: error: dereferencing pointer to incomplete type
sched_sedf.c:1232: error: dereferencing pointer to incomplete typesched_sedf.c: In function `sedf_dump_domain':
sched_sedf.c:1237: error: dereferencing pointer to incomplete type
sched_sedf.c:1237: error: dereferencing pointer to incomplete type
sched_sedf.c:1238: error: `_VCPUF_running' undeclared (first use in this function) sched_sedf.c:1238: error: dereferencing pointer to incomplete type
sched_sedf.c:1238: error: dereferencing pointer to incomplete type
sched_sedf.c:1239: error: syntax error before "PRIu64"
sched_sedf.c:1244: error: dereferencing pointer to incomplete type
sched_sedf.c:1245: error: syntax error before "PRIu64"
sched_sedf.c:1245: error: PRIu64' undeclared (first use in this function) sched_sedf.c: In function sedf_dump_cpu_state':
sched_sedf.c:1277: error: syntax error before "PRIu64"
sched_sedf.c:1321: warning: implicit declaration of function `for_each_vcpu' sched_sedf.c:1322: error: syntax error before '{' tokensched_sedf.c: At top level:
sched_sedf.c:1327: error: syntax error before '}' tokensched_sedf.c: In function `sedf_adjust_weights':
sched_sedf.c:1343: error: syntax error before '{' token
sched_sedf.c:1354: error: dereferencing pointer to incomplete type
sched_sedf.c:1355: error: dereferencing pointer to incomplete type
sched_sedf.c:1356: error: dereferencing pointer to incomplete type
sched_sedf.c:1357: warning: no return statement in function returning non-void sched_sedf.c: At top level:
sched_sedf.c:1358: error: syntax error before '}' token
sched_sedf.c:1360: error: syntax error before '!=' token
sched_sedf.c:1360: warning: type defaults to int' in declaration of d' sched_sedf.c:1360: error: invalid type argument of `->'
sched_sedf.c:1360: error: syntax error before ')' token
sched_sedf.c:1365: error: syntax error before "struct"sched_sedf.c: In function `sedf_adjdom':
sched_sedf.c:1379: error: syntax error before "PRIu64"
sched_sedf.c:1379: error: `PRIu64' undeclared (first use in this function) sched_sedf.c:1392: error: syntax error before '{' token
sched_sedf.c:1394: error: dereferencing pointer to incomplete type
sched_sedf.c:1395: error: dereferencing pointer to incomplete type
sched_sedf.c:1396: error: dereferencing pointer to incomplete type
sched_sedf.c:1400: warning: redundant redeclaration of for_each_vcpu' in same scope sched_sedf.c:1392: warning: previous declaration of for_each_vcpu' sched_sedf.c:1401: error: dereferencing pointer to incomplete type
sched_sedf.c:1401: error: called object is not a function
sched_sedf.c:1406: warning: redundant redeclaration of for_each_vcpu' in same scope sched_sedf.c:1392: warning: previous declaration of for_each_vcpu' sched_sedf.c:1406: error: syntax error before '{' token
sched_sedf.c:1410: error: dereferencing pointer to incomplete type
sched_sedf.c:1411: error: dereferencing pointer to incomplete type
sched_sedf.c:1412: error: dereferencing pointer to incomplete type
sched_sedf.c:1413: error: dereferencing pointer to incomplete type
sched_sedf.c:1414: error: dereferencing pointer to incomplete type
sched_sedf.c:1415: error: dereferencing pointer to incomplete typesched_sedf.c: At top level:
sched_sedf.c:1418: error: syntax error before "if"
sched_sedf.c:1421: warning: return type defaults to `int'sched_sedf.c: In function `for_each_vcpu':
sched_sedf.c:1422: error: invalid type argument of `->'
sched_sedf.c:1423: error: invalid type argument of `->'
sched_sedf.c:1424: error: cmd' undeclared (first use in this function) sched_sedf.c:1425: error: invalid type argument of ->'
sched_sedf.c:1426: warning: passing arg 1 of `extraq_check' makes pointer from integer without a cast sched_sedf.c: At top level:
sched_sedf.c:1428: error: syntax error before '}' token
sched_sedf.c:1447: warning: initialization from incompatible pointer type sched_sedf.c:1448: warning: initialization from incompatible pointer type sched_sedf.c:1450: warning: initialization from incompatible pointer type sched_sedf.c:1452: warning: initialization from incompatible pointer type sched_sedf.c:1453: warning: initialization from incompatible pointer type
make[2]: *** [sched_sedf.o] Error 1
make[2]: Leaving directory `/usr/local/src/xen-2.0-testing.hg/xen/common'
make[1]: *** [/usr/local/src/xen-2.0-testing.hg/xen/xen] Error 2
make[1]: Leaving directory `/usr/local/src/xen-2.0-testing.hg/xen'
make: *** [xen] Error 2
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Quoted 5 lines · Andy Lee
Quoted 4 lines · At 03:11 PM 8/17/2005, I wrote:
Sorry to report that the patch didn't work. I applied the patch to my Xen-2.0-testing tree and copied
xen/common/sched_sedf.cfrom Xen-unstable. When compiling xen,sched_sedf.cgenerated these types of errors:
Outch. Now I see... For some reason (forgot to do 'hg add' ) sched_sedf.c wasn't included. You can't use the unstable one, as it has a different naming scheme.
Attached is the patch, this time WITH sched_sedf.c Signed-off by: Stephan.Diestelhorst@{cl.cam.ac.uk, inf.tu-dresden.de}
Cheers,
Stephan
tools/libxc/Makefile +1 -0
@@ -16,6 +16,7 @@ INCLUDES += -I $(XEN_LIBXUTIL) SRCS := +SRCS += xc_sedf.c SRCS += xc_atropos.c SRCS += xc_bvtsched.c SRCS += xc_domain.c
tools/libxc/xc.h +8 -0
@@ -245,6 +245,14 @@int xc_rrobin_global_get (int xc_handle,u64 *slice); +int xc_sedf_domain_set (int xc_handle, +u32 domid, +u64 period,u64 slice,u64 latency,u16 extratime,u16 weight); + +int xc_sedf_domain_get (int xc_handle, +u32 domid, +u64 * period,u64 *slice,u64 *latency,u16 *extratime,u16 * weight); +typedef evtchn_status_t xc_evtchn_status_t ;/*\
tools/python/xen/lowlevel/xc/xc.c +70 -0
82 lines not on this page · raw message
tools/python/xen/xend/XendClient.py +9 -0
@@ -272,6 +272,15 @@ 'slice' : slice, 'latency' : latency, 'xtratime': xtratime }) + + def xend_domain_cpu_sedf_set(self, id, period, slice, latency, extratime, weight): + return self.xendPost(self.domainurl(id), + {'op' : 'cpu_sedf_set', + 'period' : period, + 'slice' : slice, + 'latency' : latency, + 'extratime' : extratime, + 'weight' : weight }) def xend_domain_maxmem_set(self, id, memory): return self.xendPost(self.domainurl(id),
tools/python/xen/xend/XendDomain.py +18 -0
@@ -663,6 +663,24 @@ return xc.atropos_domain_get(dominfo.dom) except Exception, ex: raise XendError(str(ex)) + + def domain_cpu_sedf_set(self, id, period, slice, latency, extratime, weight): + """Set Simple EDF scheduler parameters for a domain. + """ + dominfo = self.domain_lookup(id) + try: + return xc.sedf_domain_set(dominfo.dom, period, slice, latency, extratime, weight) + except Exception, ex: + raise XendError(str(ex)) + + def domain_cpu_sedf_get(self, id): + """Get Atropos scheduler parameters for a domain. + """ + dominfo = self.domain_lookup(id) + try: + return xc.sedf_domain_get(dominfo.dom) + except Exception, ex: + raise XendError(str(ex)) def domain_device_create(self, id, devconfig): """Create a new device for a domain.
tools/python/xen/xend/server/SrvDomain.py +11 -0
@@ -114,6 +114,17 @@ ['slice', 'int'], ['latency', 'int'], ['xtratime', 'int']]) + val = fn(req.args, {'dom': self.dom.id}) + return val + + def op_cpu_sedf_set(self, op, req): + fn = FormFn(self.xd.domain_cpu_sedf_set, + [['dom', 'str'], + ['period', 'int'], + ['slice', 'int'], + ['latency', 'int'], + ['extratime', 'int'], + ['weight', 'int']]) val = fn(req.args, {'dom': self.dom.id}) return val
tools/python/xen/xm/main.py +17 -0
@@ -600,6 +600,23 @@ xm.prog(ProgRrobin) +class ProgSedf(Prog): + group = 'scheduler' + name= "sedf" + info = """Set simple EDF parameters.""" + + def help(self, args): + print args[0], "DOM PERIOD SLICE LATENCY EXTRATIME WEIGHT" + print "\nSet simple EDF parameters." + + def main(self, args): + if len(args) != 7: self.err("%s: Invalid argument(s)" % args[0]) + dom = args[1] + v = map(int, args[2:7]) + server.xend_domain_cpu_sedf_set(dom, *v) + +xm.prog(ProgSedf) + class ProgInfo(Prog): group = 'host' name = "info"
xen/common/schedule.c +89 -5
166 lines not on this page · raw message
xen/include/public/sched_ctl.h +11 -0
@@ -11,6 +11,7 @@#define SCHED_BVT 0#define SCHED_ATROPOS 2#define SCHED_RROBIN 3 +#define SCHED_SEDF 4/* these describe the intended direction used for a scheduler control or domain * command */
@@ -64,6 +65,16 @@u64 latency;/* 32 */ u32 xtratime;/* 36 */ }PACKED atropos; + +struct sedf_adjdom + { +u64 period;/* 16 */ +u64 slice;/* 24 */ +u64 latency;/* 32 */ +u16 extratime;/* 36 */ +u16 weight;/* 38 */ + } PACKED sedf; + }PACKED u; }PACKED ;/* 40 bytes */
xen/include/xen/sched-if.h +8 -3
@@ -7,7 +7,9 @@* Portions by Mark Williamson are (C) 2004 Intel Research Cambridge */ -#define BUCKETS 10 +//#define ADV_SCHED_HISTO +#define BUCKETS 10 +/*300*/ typedef struct schedule_data_st {
@@ -17,6 +19,11 @@struct domain *idle;/* idle task for this cpu */ void * sched_priv;struct ac_timer s_timer;/* scheduling timer */ +#ifdef ADV_SCHED_HISTO +u32 to_hist[BUCKETS ]; +u32 from_hist[BUCKETS ]; +u64 save_tsc; +#endif #ifdef BUCKETS u32 hist[BUCKETS ];/* for scheduler latency histogram */ #endif
@@ -55,5 +62,3 @@/* per CPU scheduler information */ extern schedule_data_t schedule_data[]; - -
xen/common/sched_sedf.c new file +1422 -0
1,422 lines not on this page · raw message
_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Quoted 7 lines · Stephan Diestelhorst
Quoted 5 lines · Andy Lee
Quoted 4 lines · At 03:11 PM 8/17/2005, I wrote:
Sorry to report that the patch didn't work. I applied the patch to my Xen-2.0-testing tree and copied
xen/common/sched_sedf.cfrom Xen-unstable. When compiling xen,sched_sedf.cgenerated these types of errors:
Quoted 5 lines
Outch. Now I see... For some reason (forgot to do 'hg add' )
sched_sedf.cwasn't included. You can't use the unstable one, as it has a different naming scheme.Attached is the patch, this time WITH
sched_sedf.c
Also missing is xen-2.0-testing.hg/tools/libxc/xc_sedf.c - but this time, I was able to use the xc_sedf.c from the unstable tree!!! :-)
It compiles, but I encountered this problem:
(Xen-2.0-testing)
# xm list Name Id Mem(MB) CPU State Time(s) Console Domain-0 0 251 0 r---- 14.1 Sarge 1 127 0 -b--- 3.1 9601
# xm sedf 1 0 0 0 1 128 Error: (22, 'Invalid argument')
Last night, I also compiled xen-unstable to see how sedf works:
(Xen-unstable)
# xm sedf 1 0 0 0 1 128 Unexpected error: exceptions.TypeError
Please report to [email protected]
Traceback (most recent call last):
File "/usr/sbin/xm", line 10, in ?
main.main(sys.argv)
File "/usr/lib/python/xen/xm/main.py", line 646, in main
rc = cmd(args)
File "/usr/lib/python/xen/xm/main.py", line 435, in xm_sedf
server.xend_domain_cpu_sedf_set(dom, *v)
TypeError: xend_domain_cpu_sedf_set() takes exactly 7 arguments (6 given)
That sounds like a problem I was getting in Xen-unstable. The patch I submitted a day or two ago should fix it, but it might be different in Xen-testing. The patch is on the message:
http://lists.xensource.com/archives/html/xen-tools/2005-08/msg00094.html
Cheers
Ross
Quoted 51 lines · Andy Lee
Quoted 7 lines · Stephan Diestelhorst
Quoted 5 lines · Andy Lee
Quoted 4 lines · At 03:11 PM 8/17/2005, I wrote:
Sorry to report that the patch didn't work. I applied the patch to my Xen-2.0-testing tree and copied
xen/common/sched_sedf.cfrom Xen-unstable. When compiling xen,sched_sedf.cgenerated these types of errors:Quoted 5 lines
Outch. Now I see... For some reason (forgot to do 'hg add' )
sched_sedf.cwasn't included. You can't use the unstable one, as it has a different naming scheme.Attached is the patch, this time WITH
sched_sedf.cAlso missing is
xen-2.0-testing.hg/tools/libxc/xc_sedf.c- but this time, I was able to use thexc_sedf.cfrom the unstable tree!!! :-)It compiles, but I encountered this problem:
(Xen-2.0-testing)
# xm list Name Id Mem(MB) CPU State Time(s) Console Domain-0 0 251 0 r---- 14.1 Sarge 1 127 0 -b--- 3.1 9601# xm sedf 1 0 0 0 1 128 Error: (22, 'Invalid argument')Last night, I also compiled xen-unstable to see how sedf works:
(Xen-unstable)
# xm sedf 1 0 0 0 1 128 Unexpected error: exceptions.TypeErrorPlease report to [email protected]
Traceback (most recent call last):
File "/usr/sbin/xm", line 10, in ?
main.main(sys.argv)
File "/usr/lib/python/xen/xm/main.py", line 646, in main
rc = cmd(args)
File "/usr/lib/python/xen/xm/main.py", line 435, inxm_sedf
server.xend_domain_cpu_sedf_set(dom, *v)
TypeError:xend_domain_cpu_sedf_set()takes exactly 7 arguments (6 given)_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel
Quoted 15 lines · Andy Lee
Quoted 10 lines
Quoted 4 lines
Quoted 4 lines
Sorry to report that the patch didn't work. I applied the patch to my Xen-2.0-testing tree and copied
xen/common/sched_sedf.cfrom Xen-unstable. When compiling xen,sched_sedf.cgenerated these types of errors:Outch. Now I see... For some reason (forgot to do 'hg add' )
sched_sedf.cwasn't included. You can't use the unstable one, as it has a different naming scheme.Attached is the patch, this time WITH
sched_sedf.cAlso missing is
xen-2.0-testing.hg/tools/libxc/xc_sedf.c- but this time, I was able to use thexc_sedf.cfrom the unstable tree!!! :-)It compiles, but I encountered this problem:
Quoted 8 lines
(Xen-2.0-testing)
# xm list Name Id Mem(MB) CPU State Time(s) Console Domain-0 0 251 0 r---- 14.1 Sarge 1 127 0 -b--- 3.1 9601# xm sedf 1 0 0 0 1 128 Error: (22, 'Invalid argument')
Oops, I placed "sched=sedf" on the wrong line in /boot/grub/menu.lst. Once I fixed it, the above xm command ("xm sedf Sarge 0 0 0 1 128") worked!!!
Thank you! Thank you! Thank you! :-)
Quoted 3 lines
(Xen-unstable)
# xm sedf 1 0 0 0 1 128 Unexpected error: exceptions.TypeError
Ross McIlroy pointed out the fix. Thank you also!