[commit: ghc] wip/eventlog-heap-profile: Allow prof, eventlog, and threaded ways to coexist (a2dd1c3)

git at git.haskell.org git at git.haskell.org
Sat Mar 26 00:58:15 UTC 2016


Repository : ssh://git@git.haskell.org/ghc

On branch  : wip/eventlog-heap-profile
Link       : http://ghc.haskell.org/trac/ghc/changeset/a2dd1c3d2ae4e318ab1f4a83015eb11381560f80/ghc

>---------------------------------------------------------------

commit a2dd1c3d2ae4e318ab1f4a83015eb11381560f80
Author: Ben Gamari <ben at smart-cactus.org>
Date:   Thu Dec 31 10:15:26 2015 +0100

    Allow prof, eventlog, and threaded ways to coexist


>---------------------------------------------------------------

a2dd1c3d2ae4e318ab1f4a83015eb11381560f80
 compiler/main/DynFlags.hs | 1 +
 mk/config.mk.in           | 2 +-
 mk/ways.mk                | 9 ++++++++-
 3 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/compiler/main/DynFlags.hs b/compiler/main/DynFlags.hs
index 9c67045..e4451f4 100644
--- a/compiler/main/DynFlags.hs
+++ b/compiler/main/DynFlags.hs
@@ -1259,6 +1259,7 @@ allowed_combination way = and [ x `allowedWith` y
         (WayCustom {}) `allowedWith` _          = True
         WayThreaded `allowedWith` WayProf       = True
         WayThreaded `allowedWith` WayEventLog   = True
+        WayProf     `allowedWith` WayEventLog   = True
         _ `allowedWith` _                       = False
 
 mkBuildTag :: [Way] -> String
diff --git a/mk/config.mk.in b/mk/config.mk.in
index d2bf321..d811359 100644
--- a/mk/config.mk.in
+++ b/mk/config.mk.in
@@ -289,7 +289,7 @@ GhcRTSWays += debug
 # We always have the threaded versions, but note that SMP support may be disabled
 # (see GhcWithSMP).
 GhcRTSWays += thr thr_debug thr_l
-GhcRTSWays += $(if $(findstring p, $(GhcLibWays)),thr_p,)
+GhcRTSWays += $(if $(findstring p, $(GhcLibWays)),thr_p p_l thr_p_l,)
 GhcRTSWays += $(if $(findstring dyn, $(GhcLibWays)),dyn debug_dyn thr_dyn thr_debug_dyn l_dyn thr_l_dyn,)
 
 # We can only build GHCi threaded if we have a threaded RTS:
diff --git a/mk/ways.mk b/mk/ways.mk
index 996530e..80301f7 100644
--- a/mk/ways.mk
+++ b/mk/ways.mk
@@ -22,7 +22,7 @@
 #
 # The ways currently defined.
 #
-ALL_WAYS=v p l debug dyn thr thr_l p_dyn debug_dyn thr_dyn thr_p_dyn thr_debug_dyn thr_p thr_debug debug_p thr_debug_p l_dyn thr_l_dyn
+ALL_WAYS=v p l debug dyn thr thr_l p_dyn p_l debug_dyn thr_dyn thr_p_dyn thr_debug_dyn thr_p thr_debug debug_p thr_debug_p l_dyn thr_l_dyn p_l thr_p_l
 
 #
 # The following ways currently are treated specially,
@@ -68,6 +68,10 @@ WAY_debug_HC_OPTS= -static -optc-DDEBUG -ticky -DTICKY_TICKY
 WAY_debug_p_NAME=debug profiled
 WAY_debug_p_HC_OPTS= -static -optc-DDEBUG -prof
 
+# Way 'p_l':
+WAY_p_l_NAME=profiling event logging
+WAY_p_l_HC_OPTS= -static -prof -eventlog
+
 # Way 'thr_debug':
 WAY_thr_debug_NAME=threaded debug
 WAY_thr_debug_HC_OPTS= -static -optc-DTHREADED_RTS -optc-DDEBUG
@@ -106,3 +110,6 @@ WAY_l_dyn_HC_OPTS= -fPIC -dynamic -eventlog
 WAY_thr_l_dyn_NAME=threaded event logging dynamic
 WAY_thr_l_dyn_HC_OPTS= -fPIC -dynamic -optc-DTHREADED_RTS -eventlog
 
+# Way 'thr_p_l':
+WAY_thr_p_l_NAME=threaded profiling event logging
+WAY_thr_p_l_HC_OPTS= -static -prof -optc-DTHREADED_RTS -eventlog



More information about the ghc-commits mailing list