From: Chris F. <cfr...@no...> - 2008-08-26 16:56:16
|
Peter Zijlstra wrote: > On Tue, 2008-08-26 at 03:20 +0530, Subrata Modak wrote: > >>Hi Vatsa, >> >>2.6.26 has seen commits to implement SMP nice support for the full group >>hierarchy. Did you use any specific regression/benchmark test cases of >>your own for this ? > > > Some hand crafted scenarios at times, but chris friesen (CCed) wrote a > nice test program - he might be willing to share ;-) Sure...the more people that are testing in a systematic way, the better results we're likely to see in mainline. I've attached my test app, along with some sample config files. It lets you specify some number of groups, set the share for each group, and specify 0/1/n cpu hogs for each group (where n is the number of cpus online). To save resources I've arbitrarily set the limit at 10 groups and 4 cpus, but that can easily be changed. Basically it sets up the groups, spawns a bunch of cpu hogs, and then after a specified amount of time it pauses all of the hogs and gathers cpu usage and latency data from /proc/<pid>/sched. The tool must be run as root. In the simplest case you just give it the name of the config file and it will use the default options--cpu hogs are pure hogs, are not affined, and run in SCHED_OTHER with nice -10. The app can handle multiple levels of group hierarchy. To simplify things, it will only allow scenarios where all the cpu hogs are in the leaf groups, and will bail out if this is violated. You can use the "-v" option to dump more information, and "-V" to give the verbose version and also dump out the /proc/<pid>/sched files for manual parsing. Chris |