summaryrefslogtreecommitdiff
path: root/rts/Schedule.c
diff options
context:
space:
mode:
authorSimon Marlow <marlowsd@gmail.com>2014-05-04 20:27:42 +0100
committerSimon Marlow <marlowsd@gmail.com>2014-05-04 20:28:58 +0100
commitf0fcc41d755876a1b02d1c7c79f57515059f6417 (patch)
tree89cce0cfc61744b1c7b732619ea9de04f21fdcfe /rts/Schedule.c
parent5141baf76132fe0d8f88cfa0a62698cc3b37e48a (diff)
downloadhaskell-f0fcc41d755876a1b02d1c7c79f57515059f6417.tar.gz
Revert "Per-thread allocation counters and limits"
Problems were found on 32-bit platforms, I'll commit again when I have a fix. This reverts the following commits: 54b31f744848da872c7c6366dea840748e01b5cf b0534f78a73f972e279eed4447a5687bd6a8308e
Diffstat (limited to 'rts/Schedule.c')
-rw-r--r--rts/Schedule.c19
1 files changed, 0 insertions, 19 deletions
diff --git a/rts/Schedule.c b/rts/Schedule.c
index b1b489a6d1..adf2b5cb39 100644
--- a/rts/Schedule.c
+++ b/rts/Schedule.c
@@ -481,10 +481,6 @@ run_thread:
// happened. So find the new location:
t = cap->r.rCurrentTSO;
- // cap->r.rCurrentTSO is charged for calls to allocate(), so we
- // don't want it set during scheduler operations.
- cap->r.rCurrentTSO = NULL;
-
// And save the current errno in this thread.
// XXX: possibly bogus for SMP because this thread might already
// be running again, see code below.
@@ -1082,21 +1078,6 @@ schedulePostRunThread (Capability *cap, StgTSO *t)
}
}
- //
- // If the current thread's allocation limit has run out, send it
- // the AllocationLimitExceeded exception.
-
- if (t->alloc_limit < 0 && (t->flags & TSO_ALLOC_LIMIT)) {
- // Use a throwToSelf rather than a throwToSingleThreaded, because
- // it correctly handles the case where the thread is currently
- // inside mask. Also the thread might be blocked (e.g. on an
- // MVar), and throwToSingleThreaded doesn't unblock it
- // correctly in that case.
- throwToSelf(cap, t, allocationLimitExceeded_closure);
- t->alloc_limit = (StgInt64)RtsFlags.GcFlags.allocLimitGrace
- * BLOCK_SIZE;
- }
-
/* some statistics gathering in the parallel case */
}