From: simonmar Date: Fri, 10 Aug 2001 15:25:49 +0000 (+0000) Subject: [project @ 2001-08-10 15:25:49 by simonmar] X-Git-Tag: Approximately_9120_patches~1282 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=858fd614eaf37c9bcc91961d6998df23a66b7650;p=ghc-hetmet.git [project @ 2001-08-10 15:25:49 by simonmar] Fix bug with +RTS -P --- diff --git a/ghc/rts/RtsFlags.c b/ghc/rts/RtsFlags.c index 3f44ccb..40221e1 100644 --- a/ghc/rts/RtsFlags.c +++ b/ghc/rts/RtsFlags.c @@ -1,5 +1,5 @@ /* ----------------------------------------------------------------------------- - * $Id: RtsFlags.c,v 1.46 2001/08/08 14:14:08 simonmar Exp $ + * $Id: RtsFlags.c,v 1.47 2001/08/10 15:25:49 simonmar Exp $ * * (c) The AQUA Project, Glasgow University, 1994-1997 * (c) The GHC Team, 1998-1999 @@ -774,9 +774,6 @@ error = rtsTrue; /* =========== PROFILING ========================== */ case 'P': /* detailed cost centre profiling (time/alloc) */ - COST_CENTRE_USING_BUILD_ONLY( - RtsFlags.CcFlags.doCostCentres = COST_CENTRES_VERBOSE; - ) case 'p': /* cost centre profiling (time/alloc) */ COST_CENTRE_USING_BUILD_ONLY( switch (rts_argv[arg][2]) { @@ -787,8 +784,14 @@ error = rtsTrue; RtsFlags.CcFlags.doCostCentres = COST_CENTRES_ALL; break; default: - RtsFlags.CcFlags.doCostCentres = COST_CENTRES_SUMMARY; - break; + if (rts_argv[arg][1] == 'P') { + RtsFlags.CcFlags.doCostCentres = + COST_CENTRES_VERBOSE; + } else { + RtsFlags.CcFlags.doCostCentres = + COST_CENTRES_SUMMARY; + } + break; } ) break;