[commit: ghc] master: RTS: delete BlockedOnGA* + dead code (a2970f8)

git at git.haskell.org git at git.haskell.org
Fri Apr 29 08:46:47 UTC 2016


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

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/a2970f883d1018107f745531aab56e872311d8c7/ghc

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

commit a2970f883d1018107f745531aab56e872311d8c7
Author: Thomas Miedema <thomasmiedema at gmail.com>
Date:   Sat Feb 27 22:02:22 2016 +0100

    RTS: delete BlockedOnGA* + dead code
    
    Some old stuff related to the PAR way.
    
    Reviewed by: austin, simonmar
    
    Differential Revision: https://phabricator.haskell.org/D2137


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

a2970f883d1018107f745531aab56e872311d8c7
 includes/rts/Constants.h             |  5 -----
 includes/rts/storage/ClosureMacros.h |  6 ------
 includes/rts/storage/InfoTables.h    |  4 ++--
 includes/rts/storage/TSO.h           | 11 +----------
 rts/sm/Scav.c                        |  4 ----
 5 files changed, 3 insertions(+), 27 deletions(-)

diff --git a/includes/rts/Constants.h b/includes/rts/Constants.h
index 6e44410..b65b8d3 100644
--- a/includes/rts/Constants.h
+++ b/includes/rts/Constants.h
@@ -212,11 +212,6 @@
 /* Win32 only: */
 #define BlockedOnDoProc     7
 
-/* Only relevant for PAR: */
-  /* blocked on a remote closure represented by a Global Address: */
-#define BlockedOnGA         8
-  /* same as above but without sending a Fetch message */
-#define BlockedOnGA_NoSend  9
 /* Only relevant for THREADED_RTS: */
 #define BlockedOnCCall      10
 #define BlockedOnCCall_Interruptible 11
diff --git a/includes/rts/storage/ClosureMacros.h b/includes/rts/storage/ClosureMacros.h
index d534873..03589f2 100644
--- a/includes/rts/storage/ClosureMacros.h
+++ b/includes/rts/storage/ClosureMacros.h
@@ -177,12 +177,6 @@ STATIC_LINK(const StgInfoTable *info, StgClosure *p)
     }
 }
 
-INLINE_HEADER StgClosure *STATIC_LINK2(const StgInfoTable *info,
-                                       StgClosure *p) {
-    return (*(StgClosure**)(&((p)->payload[info->layout.payload.ptrs +
-                            info->layout.payload.nptrs + 1])));
-}
-
 /* -----------------------------------------------------------------------------
    INTLIKE and CHARLIKE closures.
    -------------------------------------------------------------------------- */
diff --git a/includes/rts/storage/InfoTables.h b/includes/rts/storage/InfoTables.h
index 3de63c8..b165be2 100644
--- a/includes/rts/storage/InfoTables.h
+++ b/includes/rts/storage/InfoTables.h
@@ -17,7 +17,7 @@
    position-independent code.
 
    Note [x86-64-relative]
-   There is a complication on the x86_64 platform, where pointeres are
+   There is a complication on the x86_64 platform, where pointers are
    64 bits, but the tools don't support 64-bit relative relocations.
    However, the default memory model (small) ensures that all symbols
    have values in the lower 2Gb of the address space, so offsets all
@@ -208,7 +208,7 @@ typedef struct StgInfoTable_ {
 #ifdef TABLES_NEXT_TO_CODE
     StgCode         code[];
 #endif
-} *StgInfoTablePtr;
+} *StgInfoTablePtr; // StgInfoTable defined in rts/Types.h
 
 
 /* -----------------------------------------------------------------------------
diff --git a/includes/rts/storage/TSO.h b/includes/rts/storage/TSO.h
index aa3d057..fd32919 100644
--- a/includes/rts/storage/TSO.h
+++ b/includes/rts/storage/TSO.h
@@ -184,7 +184,7 @@ typedef struct StgTSO_ {
     StgWord32 saved_winerror;
 #endif
 
-} *StgTSOPtr;
+} *StgTSOPtr; // StgTSO defined in rts/Types.h
 
 typedef struct StgStack_ {
     StgHeader  header;
@@ -242,8 +242,6 @@ void dirty_STACK (Capability *cap, StgStack *stack);
         BlockedOnRead          NULL                 blocked_queue
         BlockedOnWrite         NULL                 blocked_queue
         BlockedOnDelay         NULL                 blocked_queue
-        BlockedOnGA            closure TSO blocks on   BQ of that closure
-        BlockedOnGA_NoSend     closure TSO blocks on   BQ of that closure
 
       tso->link == END_TSO_QUEUE, if the thread is currently running.
 
@@ -258,13 +256,6 @@ void dirty_STACK (Capability *cap, StgStack *stack);
       (tso->sp is left pointing at the top word on the stack so that
       the return value or exception will be retained by a GC).
 
-   The 2 cases BlockedOnGA and BlockedOnGA_NoSend are needed in a GUM
-   setup only. They mark a TSO that has entered a FETCH_ME or
-   FETCH_ME_BQ closure, respectively; only the first TSO hitting the
-   closure will send a Fetch message.
-   Currently we have no separate code for blocking on an RBH; we use the
-   BlockedOnBlackHole case for that.   -- HWL
-
  ---------------------------------------------------------------------------- */
 
 /* this is the NIL ptr for a TSO queue (e.g. runnable queue) */
diff --git a/rts/sm/Scav.c b/rts/sm/Scav.c
index abb7726..7f64ea6 100644
--- a/rts/sm/Scav.c
+++ b/rts/sm/Scav.c
@@ -1702,10 +1702,6 @@ scavenge_static(void)
 
     ASSERT(LOOKS_LIKE_CLOSURE_PTR(p));
     info = get_itbl(p);
-    /*
-        if (info->type==RBH)
-        info = REVERT_INFOPTR(info); // if it's an RBH, look at the orig closure
-    */
     // make sure the info pointer is into text space
 
     /* Take this object *off* the static_objects list,



More information about the ghc-commits mailing list