/* --------------------------------------------------------------------------
- Time-stamp: <Sat Dec 04 1999 01:26:45 Stardate: [-30]3995.30 hwloidl>
- $Id: GranSimRts.h,v 1.2 2000/01/13 14:34:07 hwloidl Exp $
+ Time-stamp: <Tue Mar 06 2001 00:18:30 Stardate: [-30]6285.06 hwloidl>
Variables and functions specific to GranSim.
----------------------------------------------------------------------- */
//* Statistics gathering::
//* Prototypes::
//@end menu
+//*/ fool highlight
//@node Event queue, Spark handling routines, Headers for GranSim objs used only in the RTS internally, Headers for GranSim objs used only in the RTS internally
//@subsection Event queue
nat tot_sparks_created, sparks_created_on_PE[MAX_PROC];
/* scheduling stats */
- nat tot_yields;
+ nat tot_yields, tot_stackover, tot_heapover;
/* blocking queue statistics */
rtsTime tot_bq_processing_time;
/* Communication related routines */
rtsFetchReturnCode fetchNode(StgClosure* node, PEs from, PEs to);
rtsFetchReturnCode handleFetchRequest(StgClosure* node, PEs curr_proc, PEs p, StgTSO* tso);
-rtsFetchReturnCode blockFetch(StgTSO* tso, PEs proc, StgClosure* bh);
void handleIdlePEs(void);
long int random(void); /* used in stealSpark() and stealThread() in GranSim.c */
/* For debugging */
rtsBool is_on_queue (StgTSO *tso, PEs proc);
+#endif
-/* Interface for dumping routines (i.e. writing to log file) */
+#if defined(GRAN) || defined(PAR)
+/*
+ Interface for dumping routines (i.e. writing to log file).
+ These routines are shared with GUM (and could also be used for SMP).
+*/
void DumpGranEvent(GranEventType name, StgTSO *tso);
void DumpEndEvent(PEs proc, StgTSO *tso, rtsBool mandatory_thread);
void DumpTSO(StgTSO *tso);
void DumpRawGranEvent(PEs proc, PEs p, GranEventType name,
- StgTSO *tso, StgClosure *node, StgInt sparkname, StgInt len);
-
+ StgTSO *tso, StgClosure *node,
+ StgInt sparkname, StgInt len);
+void DumpVeryRawGranEvent(rtsTime time, PEs proc, PEs p, GranEventType name,
+ StgTSO *tso, StgClosure *node,
+ StgInt sparkname, StgInt len);
#endif
#endif /* GRANSIM_RTS_H */