backports: add a 120 second timeout rule to Coccinelle
authorLuis R. Rodriguez <mcgrof@do-not-panic.com>
Tue, 15 Apr 2014 19:52:02 +0000 (19:52 +0000)
committerLuis R. Rodriguez <mcgrof@do-not-panic.com>
Thu, 17 Apr 2014 23:23:08 +0000 (16:23 -0700)
Our current overall run time is less than 120 seconds so lets
add a trigger to fail if we have a rule taking longer. Adding
this has no extra incurred overhead cost.

mcgrof@drvbp1 ~/backports (git::master)$ time ./gentree.py --clean
/home/mcgrof/linux-next /home/mcgrof/build/next-20140411
Copy original source files ...
Apply patches ...
Modify Kconfig tree ...
Rewrite Makefiles and Kconfig files ...
Done!

real    1m15.463s
user    10m49.100s
sys     0m37.100s

Cc: Peter Senna <peter.senna@gmail.com>
Cc: Julia Lawall <julia.lawall@lip6.fr>
Cc: Gilles Muller <Gilles.Muller@lip6.fr>
Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com>
lib/bpcoccinelle.py

index 75a0b37eba88d1a78ad97710d291974b6c8883d7..2e0153ebeb522c43ec4f0cccfbcbb60f67e1c0a5 100644 (file)
@@ -35,6 +35,7 @@ def spatch(cocci_file, outdir,
             '--recursive-includes',
             '--relax-include-path',
             '--use-coccigrep',
+            '--timeout', '120',
             '--backup-suffix', '.cocci_backup', '--dir', '.']
 
     if (max_threads > 1):