Messages.h 944 Bytes
Newer Older
1 2 3 4 5 6 7 8
/* ---------------------------------------------------------------------------
 *
 * (c) The GHC Team, 2010
 *
 * Inter-Capability message passing
 *
 * --------------------------------------------------------------------------*/

9
#include "BeginPrivate.h"
10 11

nat messageBlackHole(Capability *cap, MessageBlackHole *msg);
12
StgTSO * blackHoleOwner (StgClosure *bh);
13 14 15 16 17 18

#ifdef THREADED_RTS
void executeMessage (Capability *cap, Message *m);
void sendMessage    (Capability *from_cap, Capability *to_cap, Message *msg);
#endif

19 20 21 22 23 24 25 26 27 28 29
#include "Capability.h"
#include "Updates.h" // for DEBUG_FILL_SLOP

INLINE_HEADER void
doneWithMsgThrowTo (MessageThrowTo *m)
{
    OVERWRITING_CLOSURE((StgClosure*)m);
    unlockClosure((StgClosure*)m, &stg_MSG_NULL_info);
    LDV_RECORD_CREATE(m);
}

30
#include "EndPrivate.h"
31 32 33 34 35 36 37 38

// Local Variables:
// mode: C
// fill-column: 80
// indent-tabs-mode: nil
// c-basic-offset: 4
// buffer-file-coding-system: utf-8-unix
// End: