From ec6fdef5a46f450c8b7a52b491de6a17155101df Mon Sep 17 00:00:00 2001 From: Mark Wielaard Date: Tue, 14 Jul 2009 00:30:55 +0200 Subject: Make kernel opt-level the default again. * main.cxx (main): Default gcc_flags to kernel opt-level (empty). * buildrun.cxx (compile_pass): Add -freorder-blocks back, document choices. * stap.1.in: Document new default opt-level. * testsuite/systemtap.base/cache.exp: Adjust for new caching results. --- testsuite/systemtap.base/cache.exp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'testsuite/systemtap.base') diff --git a/testsuite/systemtap.base/cache.exp b/testsuite/systemtap.base/cache.exp index e70f3334..8b4cb4e6 100644 --- a/testsuite/systemtap.base/cache.exp +++ b/testsuite/systemtap.base/cache.exp @@ -105,10 +105,11 @@ stap_compile TIMING2 [F_CACHED_COMPILE] $basic_script1 -t # Using '-O[0123s]' (C compile optimizations) should change the hash # unless they are the same stap_compile OPTO [F_UNCACHED_COMPILE] $basic_script1 -O -# -O0 is the default, so will have been cached by BASIC1 -stap_compile OPTZERO [F_CACHED_COMPILE] $basic_script1 -O0 +stap_compile OPTZERO [F_UNCACHED_COMPILE] $basic_script1 -O0 # -O is an alias for -O1, so already cached stap_compile OPTONE [F_CACHED_COMPILE] $basic_script1 -O1 +# Either -O2 or -Os could be the kernel opt-level default, +# so don't assume either is already there. stap_compile OPTTWO [F_UNCACHED_COMPILE] $basic_script1 -O2 stap_compile OPTTHREE [F_UNCACHED_COMPILE] $basic_script1 -O3 stap_compile OPTSMALL [F_UNCACHED_COMPILE] $basic_script1 -Os -- cgit From 011165968c00e4125dfb9ee132e79f65dbea50c4 Mon Sep 17 00:00:00 2001 From: Mark Wielaard Date: Tue, 14 Jul 2009 11:47:46 +0200 Subject: Remove -O[0123s] gcc optimization flags for gcc pass 4 speedups again. We cannot guarantee that (un)optimized code compiles and/or generates fully functional code, so don't tempt the user to try it out. * session.h (struct systemtap_session): Remove gcc_flags string field. * hash.cxx (find_script_hash): Don't add gcc_flags. * main.cxx (usage): Remove -O[0123s] documentation. (main): Don't use gcc_flags. * buildrun.cxx (compile_pass): Don't add gcc_flags to EXTRA_CFLAGS. * stap1.in: Remove -O[0123s] documentation. * testsuite/systemtap.base/cache.exp: Remove tests for -O[0123s]. --- testsuite/systemtap.base/cache.exp | 16 ---------------- 1 file changed, 16 deletions(-) (limited to 'testsuite/systemtap.base') diff --git a/testsuite/systemtap.base/cache.exp b/testsuite/systemtap.base/cache.exp index 8b4cb4e6..5c5c1441 100644 --- a/testsuite/systemtap.base/cache.exp +++ b/testsuite/systemtap.base/cache.exp @@ -102,22 +102,6 @@ stap_compile MERGE2 [F_CACHED_COMPILE] $basic_script1 -b -M stap_compile TIMING1 [F_UNCACHED_COMPILE] $basic_script1 -t stap_compile TIMING2 [F_CACHED_COMPILE] $basic_script1 -t -# Using '-O[0123s]' (C compile optimizations) should change the hash -# unless they are the same -stap_compile OPTO [F_UNCACHED_COMPILE] $basic_script1 -O -stap_compile OPTZERO [F_UNCACHED_COMPILE] $basic_script1 -O0 -# -O is an alias for -O1, so already cached -stap_compile OPTONE [F_CACHED_COMPILE] $basic_script1 -O1 -# Either -O2 or -Os could be the kernel opt-level default, -# so don't assume either is already there. -stap_compile OPTTWO [F_UNCACHED_COMPILE] $basic_script1 -O2 -stap_compile OPTTHREE [F_UNCACHED_COMPILE] $basic_script1 -O3 -stap_compile OPTSMALL [F_UNCACHED_COMPILE] $basic_script1 -Os -# Bad -O argument should be rejected -stap_compile OPTBAD [F_UNCACHED_NO_COMPILE] $basic_script1 -OX - -stap_compile TIMING2 [F_CACHED_COMPILE] $basic_script1 -t - # Changing the runtime directory should change the hash set new_runtime [exec pwd]/.cache_test_runtime exec /bin/rm -f $new_runtime -- cgit