diff options
author | Simon Marlow <marlowsd@gmail.com> | 2011-11-29 14:05:17 +0000 |
---|---|---|
committer | Simon Marlow <marlowsd@gmail.com> | 2011-11-29 14:22:28 +0000 |
commit | 1f7433b7b998dda4dde6d09f22a37f637745c079 (patch) | |
tree | a19c5247c1d7a4816afc8fbe7d15374209c39e6c /rts | |
parent | 1ed0dfa1fe8d50ece73ee9872aa045998ef6f0f5 (diff) | |
download | haskell-1f7433b7b998dda4dde6d09f22a37f637745c079.tar.gz |
Add a new primop: getCCCS# :: State# s -> (# State# s, Addr# #)
Returns a pointer to the current cost-centre stack when profiling,
NULL otherwise.
Diffstat (limited to 'rts')
-rw-r--r-- | rts/Capability.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/rts/Capability.c b/rts/Capability.c index fd9f64f147..6c84d1ec35 100644 --- a/rts/Capability.c +++ b/rts/Capability.c @@ -267,6 +267,8 @@ initCapability( Capability *cap, nat i ) #ifdef PROFILING cap->r.rCCCS = CCS_SYSTEM; +#else + cap->r.rCCCS = NULL; #endif traceCapsetAssignCap(CAPSET_OSPROCESS_DEFAULT, i); @@ -614,6 +616,7 @@ waitForReturnCapability (Capability **pCap, Task *task) #ifdef PROFILING cap->r.rCCCS = CCS_SYSTEM; #endif + ASSERT_FULL_CAPABILITY_INVARIANTS(cap,task); debugTrace(DEBUG_sched, "resuming capability %d", cap->no); |