projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix crash in nested callbacks (#4038)
[ghc-hetmet.git]
/
rts
/
Interpreter.c
diff --git
a/rts/Interpreter.c
b/rts/Interpreter.c
index
5197510
..
5a564ba
100644
(file)
--- a/
rts/Interpreter.c
+++ b/
rts/Interpreter.c
@@
-11,16
+11,17
@@
// internal headers
#include "sm/Storage.h"
// internal headers
#include "sm/Storage.h"
+#include "sm/Sanity.h"
#include "RtsUtils.h"
#include "Schedule.h"
#include "Updates.h"
#include "RtsUtils.h"
#include "Schedule.h"
#include "Updates.h"
-#include "Sanity.h"
#include "Prelude.h"
#include "Stable.h"
#include "Printer.h"
#include "Disassembler.h"
#include "Interpreter.h"
#include "ThreadPaused.h"
#include "Prelude.h"
#include "Stable.h"
#include "Printer.h"
#include "Disassembler.h"
#include "Interpreter.h"
#include "ThreadPaused.h"
+#include "Threads.h"
#include <string.h> /* for memcpy */
#ifdef HAVE_ERRNO_H
#include <string.h> /* for memcpy */
#ifdef HAVE_ERRNO_H
@@
-269,14
+270,13
@@
eval_obj:
debugBelch("\n\n");
);
debugBelch("\n\n");
);
- IF_DEBUG(sanity,checkStackChunk(Sp, cap->r.rCurrentTSO->stack+cap->r.rCurrentTSO->stack_size));
+// IF_DEBUG(sanity,checkStackChunk(Sp, cap->r.rCurrentTSO->stack+cap->r.rCurrentTSO->stack_size));
+ IF_DEBUG(sanity,checkStackFrame(Sp));
switch ( get_itbl(obj)->type ) {
case IND:
switch ( get_itbl(obj)->type ) {
case IND:
- case IND_OLDGEN:
case IND_PERM:
case IND_PERM:
- case IND_OLDGEN_PERM:
case IND_STATIC:
{
tagged_obj = ((StgInd*)obj)->indirectee;
case IND_STATIC:
{
tagged_obj = ((StgInd*)obj)->indirectee;
@@
-442,7
+442,8
@@
do_return:
// to a PAP by the GC, violating the invariant that PAPs
// always contain a tagged pointer to the function.
INTERP_TICK(it_retto_UPDATE);
// to a PAP by the GC, violating the invariant that PAPs
// always contain a tagged pointer to the function.
INTERP_TICK(it_retto_UPDATE);
- UPD_IND(((StgUpdateFrame *)Sp)->updatee, tagged_obj);
+ updateThunk(cap, cap->r.rCurrentTSO,
+ ((StgUpdateFrame *)Sp)->updatee, tagged_obj);
Sp += sizeofW(StgUpdateFrame);
goto do_return;
Sp += sizeofW(StgUpdateFrame);
goto do_return;