[commit: ghc] master: Various RTS bug fixes: (d9a26c7)
git at git.haskell.org
git at git.haskell.org
Fri Sep 7 06:59:14 UTC 2018
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/d9a26c7e8d9bb96ccb676d6a23da21b64559c7c2/ghc
>---------------------------------------------------------------
commit d9a26c7e8d9bb96ccb676d6a23da21b64559c7c2
Author: Ömer Sinan Ağacan <omeragacan at gmail.com>
Date: Fri Sep 7 09:28:36 2018 +0300
Various RTS bug fixes:
- Retainer profiler: init_srt_thunk() should mark the stack entry as SRT
- Retainer profiler: Remove an incorrect assertion about FUN_STATIC.
FUN_STATIC does not have to have an SRT.
- Fix nptrs of BCO
Test Plan: validate
Reviewers: simonmar, bgamari, erikd
Reviewed By: simonmar
Subscribers: rwbarton, carter
Differential Revision: https://phabricator.haskell.org/D5134
>---------------------------------------------------------------
d9a26c7e8d9bb96ccb676d6a23da21b64559c7c2
rts/RetainerProfile.c | 3 +--
rts/StgMiscClosures.cmm | 2 +-
2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/rts/RetainerProfile.c b/rts/RetainerProfile.c
index d67eeb4..23f46e0 100644
--- a/rts/RetainerProfile.c
+++ b/rts/RetainerProfile.c
@@ -337,6 +337,7 @@ init_srt_fun( stackPos *info, const StgFunInfoTable *infoTable )
static INLINE void
init_srt_thunk( stackPos *info, const StgThunkInfoTable *infoTable )
{
+ info->type = posTypeSRT;
if (infoTable->i.srt) {
info->next.srt.srt = (StgClosure*)GET_SRT(infoTable);
} else {
@@ -489,8 +490,6 @@ push( StgClosure *c, retainer c_child_r, StgClosure **first_child )
// layout.payload.ptrs, SRT
case FUN_STATIC:
- ASSERT(get_itbl(c)->srt != 0);
- /* fallthrough */
case FUN: // *c is a heap object.
case FUN_2_0:
init_ptrs(&se.info, get_itbl(c)->layout.payload.ptrs, (StgPtr)c->payload);
diff --git a/rts/StgMiscClosures.cmm b/rts/StgMiscClosures.cmm
index e645442..36fd669 100644
--- a/rts/StgMiscClosures.cmm
+++ b/rts/StgMiscClosures.cmm
@@ -211,7 +211,7 @@ INFO_TABLE_RET( stg_apply_interp, RET_BCO )
Entry code for a BCO
------------------------------------------------------------------------- */
-INFO_TABLE_FUN( stg_BCO, 4, 0, BCO, "BCO", "BCO", ARG_BCO )
+INFO_TABLE_FUN( stg_BCO, 3, 0, BCO, "BCO", "BCO", ARG_BCO )
/* explicit stack */
{
/* entering a BCO means "apply it", same as a function */
More information about the ghc-commits
mailing list