From 976e8703b3f0f94c94e9eecf3b64c90f1406d462 Mon Sep 17 00:00:00 2001 From: "Luis R. Rodriguez" Date: Wed, 19 Dec 2012 16:36:38 -0800 Subject: [PATCH] compat: add ionice to ckmake again This adds back the ionice settings on the make call. The copying of content on the thread is not yet reniced and although Python has utilities to modify niceness and ionice there are privileged requirements on the levels we want and I'm not too sure yet how to resolve this in a reasonable way. This for example fails: p = psutil.Process(os.getpid()) delta = -20 - os.nice(0) p.set_nice(delta) p.set_ionice(psutil.IOPRIO_CLASS_RT) This improves perfomance by about 1 minute. real 17m53.079s user 446m12.733s sys 66m13.372s Since ckmake is multithreaded now though it meant that we had to copy the content of the code that we want to compile for each kernel on a new directory. This work is not reprioritized as it is nice so the best thing I can think of is we renice the ckmake process our ourselves and therefore children would properly inherit the priority. ionice -c 3 nice -n 20 ckmake Can we do better without networking the solution ? Signed-off-by: Luis R. Rodriguez --- bin/ckmake | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/ckmake b/bin/ckmake index 97227763c00b..34bfb09f0225 100755 --- a/bin/ckmake +++ b/bin/ckmake @@ -144,7 +144,8 @@ def process_kernel(num, kset): # XXX: figure out how to properly address logging # without this nasty ass hack. log = ' > %(log)s 2>&1' % { "log": log_file } - cmd = 'make ' + jobs + make_args + log + nice = 'ionice -c 3 nice -n 20 ' + cmd = nice + 'make ' + jobs + make_args + log kset.baking(rel) -- 2.30.2