diff options
author | Ömer Sinan Ağacan <omeragacan@gmail.com> | 2018-04-11 11:35:43 +0300 |
---|---|---|
committer | Ömer Sinan Ağacan <omeragacan@gmail.com> | 2018-04-11 11:35:43 +0300 |
commit | 74e768ea39c9b9b42ced7848f4d499f06d9fca29 (patch) | |
tree | 9d33bdc436bdc82f9adb469cc6b76a161e1cf476 /rts/Schedule.c | |
parent | ed57a347e428570f639094c705e2b5dcf4c55b03 (diff) | |
download | haskell-74e768ea39c9b9b42ced7848f4d499f06d9fca29.tar.gz |
Schedule.c: remove some unused parameters
Diffstat (limited to 'rts/Schedule.c')
-rw-r--r-- | rts/Schedule.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/rts/Schedule.c b/rts/Schedule.c index 27ef6a62e4..0ef1047e2f 100644 --- a/rts/Schedule.c +++ b/rts/Schedule.c @@ -151,11 +151,11 @@ static bool scheduleHandleThreadFinished( Capability *cap, Task *task, static bool scheduleNeedHeapProfile(bool ready_to_gc); static void scheduleDoGC(Capability **pcap, Task *task, bool force_major); -static void deleteThread (Capability *cap, StgTSO *tso); -static void deleteAllThreads (Capability *cap); +static void deleteThread (StgTSO *tso); +static void deleteAllThreads (void); #if defined(FORKPROCESS_PRIMOP_SUPPORTED) -static void deleteThread_(Capability *cap, StgTSO *tso); +static void deleteThread_(StgTSO *tso); #endif /* --------------------------------------------------------------------------- @@ -347,7 +347,7 @@ schedule (Capability *initialCapability, Task *task) // in a foreign call returns. if (sched_state >= SCHED_INTERRUPTING && !(t->what_next == ThreadComplete || t->what_next == ThreadKilled)) { - deleteThread(cap,t); + deleteThread(t); } // If this capability is disabled, migrate the thread away rather @@ -1252,7 +1252,7 @@ scheduleHandleThreadBlocked( StgTSO *t * -------------------------------------------------------------------------- */ static bool -scheduleHandleThreadFinished (Capability *cap STG_UNUSED, Task *task, StgTSO *t) +scheduleHandleThreadFinished (Capability *cap, Task *task, StgTSO *t) { /* Need to check whether this was a main thread, and if so, * return with the return value. @@ -1341,7 +1341,7 @@ scheduleHandleThreadFinished (Capability *cap STG_UNUSED, Task *task, StgTSO *t) * -------------------------------------------------------------------------- */ static bool -scheduleNeedHeapProfile( bool ready_to_gc STG_UNUSED ) +scheduleNeedHeapProfile( bool ready_to_gc ) { // When we have +RTS -i0 and we're heap profiling, do a census at // every GC. This lets us get repeatable runs for debugging. @@ -1743,7 +1743,7 @@ delete_threads_and_gc: * Checking for major_gc ensures that the last GC is major. */ if (sched_state == SCHED_INTERRUPTING && major_gc) { - deleteAllThreads(cap); + deleteAllThreads(); #if defined(THREADED_RTS) // Discard all the sparks from every Capability. Why? // They'll probably be GC'd anyway since we've killed all the @@ -2038,7 +2038,7 @@ forkProcess(HsStablePtr *entry // don't allow threads to catch the ThreadKilled // exception, but we do want to raiseAsync() because these // threads may be evaluating thunks that we need later. - deleteThread_(t->cap,t); + deleteThread_(t); // stop the GC from updating the InCall to point to // the TSO. This is only necessary because the @@ -2262,7 +2262,7 @@ setNumCapabilities (uint32_t new_n_capabilities USED_IF_THREADS) * ------------------------------------------------------------------------- */ static void -deleteAllThreads ( Capability *cap ) +deleteAllThreads () { // NOTE: only safe to call if we own all capabilities. @@ -2273,7 +2273,7 @@ deleteAllThreads ( Capability *cap ) for (g = 0; g < RtsFlags.GcFlags.generations; g++) { for (t = generations[g].threads; t != END_TSO_QUEUE; t = next) { next = t->global_link; - deleteThread(cap,t); + deleteThread(t); } } @@ -2784,7 +2784,7 @@ void wakeUpRts(void) -------------------------------------------------------------------------- */ static void -deleteThread (Capability *cap STG_UNUSED, StgTSO *tso) +deleteThread (StgTSO *tso) { // NOTE: must only be called on a TSO that we have exclusive // access to, because we will call throwToSingleThreaded() below. @@ -2799,7 +2799,7 @@ deleteThread (Capability *cap STG_UNUSED, StgTSO *tso) #if defined(FORKPROCESS_PRIMOP_SUPPORTED) static void -deleteThread_(Capability *cap, StgTSO *tso) +deleteThread_(StgTSO *tso) { // for forkProcess only: // like deleteThread(), but we delete threads in foreign calls, too. @@ -2808,7 +2808,7 @@ deleteThread_(Capability *cap, StgTSO *tso) tso->what_next = ThreadKilled; appendToRunQueue(tso->cap, tso); } else { - deleteThread(cap,tso); + deleteThread(tso); } } #endif |