Thawan Kooburat
2011-Mar-04 01:30 UTC
[Xen-users] Why CPU intensive domain gets 60ms time slice?
Hi, My understanding is that the credit scheduler should let each domain runs at most 30 ms at time. However, when I set domain cap to 50% and pin it to a single CPU then run CPU intensive job on that domain, I saw that the domain is running 60 ms at a time. The log show that r_time is 30000000, so credit scheduler should wake up after 30 ms. However the domain continue to run until 60 ms. Is this normal or I miss configure something. I am using Xen 4.0.2-rc1-pre on Fedora 13 Below is the scheduler log from xentrace CPU2 35923150108817 (+133384208) switch_infprev [ old_domid 0x00007fff, runtime = 53493895 ] CPU2 35923150109319 (+ 502) switch_infnext [ new_domid 0x00000001, time = 1189, r_time = 30000000 ] CPU2 35923150109874 (+ 555) __enter_scheduler [ prev<domid:edomid> = 0x00007fff : 0x00000002, next<domid:edomid> 0x00000001 : 0x00000000 ] CPU2 35923150110264 (+ 390) running_to_runnable [ dom:vcpu = 0x7fff0002 ] CPU2 35923150111082 (+ 818) runnable_to_running [ dom:vcpu = 0x00010000 ] CPU2 35923224919179 (+74808097) unknown (0x0000000000021002) [ 0x00010000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 ] CPU2 0 (+ 0) cpu_change 0x00000002 CPU2 35923299725334 (+74806155) unknown (0x0000000000021002) [ 0x00010000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 ] CPU2 35923299737972 (+ 12638) switch_infprev [ old_domid 0x00000001, runtime = 60007693 ] CPU2 35923299738504 (+ 532) switch_infnext [ new_domid 0x00007fff, time = 60007693, r_time = 4294967295 ] -- Thawan Kooburat Graduate Student Department of Computer Science UW-Madison _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Thawan Kooburat
2011-Mar-04 02:26 UTC
[Xen-users] Re: Why CPU intensive domain gets 60ms time slice?
Found the reason, I added TRC_SCHED_CONTINUE_RUNNING into the formats used to print the log. Now, it made more sense. CPU2 1663536439522 (+149622930) switch_infprev [ old_domid 0x00007fff, runtime = 60006279 ] CPU2 1663536440024 (+ 502) switch_infnext [ new_domid 0x00000001, time = 1100, r_time = 30000000 ] CPU2 1663536440557 (+ 533) __enter_scheduler [ prev<domid:edomid> = 0x00007fff : 0x00000002, next<domid:edomid> 0x00000001 : 0x00000000 ] CPU2 1663536441067 (+ 510) running_to_runnable [ dom:vcpu = 0x7fff0002 ] CPU2 1663536441809 (+ 742) runnable_to_running [ dom:vcpu = 0x00010000 ] CPU2 0 (+ 0) cpu_change 0x00000002 CPU2 1663611251009 (+74809200) continue_running [ vcpu:dom = 0x00010000 ] CPU2 1663685986987 (+74735978) continue_running [ vcpu:dom = 0x00010000 ] CPU2 1663685997997 (+ 11010) switch_infprev [ old_domid 0x00000001, runtime = 60007641 ] CPU2 1663685998590 (+ 593) switch_infnext [ new_domid 0x00007fff, time = 60007641, r_time = 4294967295 ] -- Thawan Kooburat Graduate Student Department of Computer Science UW-Madison _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users