Merge branch 'master' of http://darcs.haskell.org/ghc
[ghc.git] / includes / stg / MiscClosures.h
1 /* ----------------------------------------------------------------------------
2 *
3 * (c) The GHC Team, 1998-2009
4 *
5 * Declarations for various symbols exported by the RTS.
6 *
7 * ToDo: many of the symbols in here don't need to be exported, but
8 * our Cmm code generator doesn't know how to generate local symbols
9 * for the RTS bits (it assumes all RTS symbols are external).
10 *
11 * See wiki:Commentary/Compiler/Backends/PprC#Prototypes
12 *
13 * Do not #include this file directly: #include "Rts.h" instead.
14 *
15 * To understand the structure of the RTS headers, see the wiki:
16 * http://hackage.haskell.org/trac/ghc/wiki/Commentary/SourceTree/Includes
17 *
18 * --------------------------------------------------------------------------*/
19
20 #ifndef STGMISCCLOSURES_H
21 #define STGMISCCLOSURES_H
22
23 #if IN_STG_CODE
24 # define RTS_RET_INFO(i) extern W_(i)[]
25 # define RTS_FUN_INFO(i) extern W_(i)[]
26 # define RTS_THUNK_INFO(i) extern W_(i)[]
27 # define RTS_INFO(i) extern W_(i)[]
28 # define RTS_CLOSURE(i) extern W_(i)[]
29 # define RTS_FUN_DECL(f) extern DLL_IMPORT_RTS StgFunPtr f(void)
30 #else
31 # define RTS_RET_INFO(i) extern DLL_IMPORT_RTS const StgRetInfoTable i
32 # define RTS_FUN_INFO(i) extern DLL_IMPORT_RTS const StgFunInfoTable i
33 # define RTS_THUNK_INFO(i) extern DLL_IMPORT_RTS const StgThunkInfoTable i
34 # define RTS_INFO(i) extern DLL_IMPORT_RTS const StgInfoTable i
35 # define RTS_CLOSURE(i) extern DLL_IMPORT_RTS StgClosure i
36 # define RTS_FUN_DECL(f) extern DLL_IMPORT_RTS StgFunPtr f(void)
37 #endif
38
39 #ifdef TABLES_NEXT_TO_CODE
40 # define RTS_RET(f) RTS_INFO(f##_info)
41 # define RTS_ENTRY(f) RTS_INFO(f##_info)
42 # define RTS_FUN(f) RTS_FUN_INFO(f##_info)
43 # define RTS_THUNK(f) RTS_THUNK_INFO(f##_info)
44 #else
45 # define RTS_RET(f) RTS_INFO(f##_info); RTS_FUN_DECL(f##_ret)
46 # define RTS_ENTRY(f) RTS_INFO(f##_info); RTS_FUN_DECL(f##_entry)
47 # define RTS_FUN(f) RTS_FUN_INFO(f##_info); RTS_FUN_DECL(f##_entry)
48 # define RTS_THUNK(f) RTS_THUNK_INFO(f##_info); RTS_FUN_DECL(f##_entry)
49 #endif
50
51 /* Stack frames */
52 RTS_RET(stg_upd_frame);
53 RTS_RET(stg_bh_upd_frame);
54 RTS_RET(stg_marked_upd_frame);
55 RTS_RET(stg_noupd_frame);
56 RTS_RET(stg_catch_frame);
57 RTS_RET(stg_catch_retry_frame);
58 RTS_RET(stg_atomically_frame);
59 RTS_RET(stg_atomically_waiting_frame);
60 RTS_RET(stg_catch_stm_frame);
61 RTS_RET(stg_unmaskAsyncExceptionszh_ret);
62 RTS_RET(stg_maskUninterruptiblezh_ret);
63 RTS_RET(stg_maskAsyncExceptionszh_ret);
64 RTS_RET(stg_stack_underflow_frame);
65 RTS_RET(stg_restore_cccs);
66
67 // RTS_FUN(stg_interp_constr_entry);
68 //
69 // This is referenced using the FFI in the compiler (ByteCodeItbls),
70 // so we can't give it the correct type here because the prototypes
71 // would clash (FFI references are always declared with type StgWord[]
72 // in the generated C code).
73
74 /* Magic glue code for when compiled code returns a value in R1/F1/D1
75 or a VoidRep to the interpreter. */
76 RTS_RET(stg_ctoi_R1p);
77 RTS_RET(stg_ctoi_R1unpt);
78 RTS_RET(stg_ctoi_R1n);
79 RTS_RET(stg_ctoi_F1);
80 RTS_RET(stg_ctoi_D1);
81 RTS_RET(stg_ctoi_L1);
82 RTS_RET(stg_ctoi_V);
83
84 RTS_RET(stg_apply_interp);
85
86 RTS_ENTRY(stg_IND);
87 RTS_ENTRY(stg_IND_direct);
88 RTS_ENTRY(stg_IND_STATIC);
89 RTS_ENTRY(stg_IND_PERM);
90 RTS_ENTRY(stg_BLACKHOLE);
91 RTS_ENTRY(stg_CAF_BLACKHOLE);
92 RTS_ENTRY(__stg_EAGER_BLACKHOLE);
93 RTS_ENTRY(stg_WHITEHOLE);
94 RTS_ENTRY(stg_BLOCKING_QUEUE_CLEAN);
95 RTS_ENTRY(stg_BLOCKING_QUEUE_DIRTY);
96
97 RTS_FUN(stg_BCO);
98 RTS_ENTRY(stg_EVACUATED);
99 RTS_ENTRY(stg_WEAK);
100 RTS_ENTRY(stg_DEAD_WEAK);
101 RTS_ENTRY(stg_STABLE_NAME);
102 RTS_ENTRY(stg_MVAR_CLEAN);
103 RTS_ENTRY(stg_MVAR_DIRTY);
104 RTS_ENTRY(stg_TSO);
105 RTS_ENTRY(stg_STACK);
106 RTS_ENTRY(stg_ARR_WORDS);
107 RTS_ENTRY(stg_MUT_ARR_WORDS);
108 RTS_ENTRY(stg_MUT_ARR_PTRS_CLEAN);
109 RTS_ENTRY(stg_MUT_ARR_PTRS_DIRTY);
110 RTS_ENTRY(stg_MUT_ARR_PTRS_FROZEN);
111 RTS_ENTRY(stg_MUT_ARR_PTRS_FROZEN0);
112 RTS_ENTRY(stg_MUT_VAR_CLEAN);
113 RTS_ENTRY(stg_MUT_VAR_DIRTY);
114 RTS_ENTRY(stg_END_TSO_QUEUE);
115 RTS_ENTRY(stg_MSG_TRY_WAKEUP);
116 RTS_ENTRY(stg_MSG_THROWTO);
117 RTS_ENTRY(stg_MSG_BLACKHOLE);
118 RTS_ENTRY(stg_MSG_NULL);
119 RTS_ENTRY(stg_MVAR_TSO_QUEUE);
120 RTS_ENTRY(stg_catch);
121 RTS_ENTRY(stg_PAP);
122 RTS_ENTRY(stg_AP);
123 RTS_ENTRY(stg_AP_NOUPD);
124 RTS_ENTRY(stg_AP_STACK);
125 RTS_ENTRY(stg_AP_STACK_NOUPD);
126 RTS_ENTRY(stg_dummy_ret);
127 RTS_ENTRY(stg_raise);
128 RTS_ENTRY(stg_raise_ret);
129 RTS_ENTRY(stg_TVAR_WATCH_QUEUE);
130 RTS_ENTRY(stg_INVARIANT_CHECK_QUEUE);
131 RTS_ENTRY(stg_ATOMIC_INVARIANT);
132 RTS_ENTRY(stg_TVAR);
133 RTS_ENTRY(stg_TREC_CHUNK);
134 RTS_ENTRY(stg_TREC_HEADER);
135 RTS_ENTRY(stg_END_STM_WATCH_QUEUE);
136 RTS_ENTRY(stg_END_INVARIANT_CHECK_QUEUE);
137 RTS_ENTRY(stg_END_STM_CHUNK_LIST);
138 RTS_ENTRY(stg_NO_TREC);
139
140 /* closures */
141
142 RTS_CLOSURE(stg_END_TSO_QUEUE_closure);
143 RTS_CLOSURE(stg_NO_FINALIZER_closure);
144 RTS_CLOSURE(stg_dummy_ret_closure);
145 RTS_CLOSURE(stg_forceIO_closure);
146
147 RTS_CLOSURE(stg_END_STM_WATCH_QUEUE_closure);
148 RTS_CLOSURE(stg_END_INVARIANT_CHECK_QUEUE_closure);
149 RTS_CLOSURE(stg_END_STM_CHUNK_LIST_closure);
150 RTS_CLOSURE(stg_NO_TREC_closure);
151
152 RTS_ENTRY(stg_NO_FINALIZER_entry);
153
154 #if IN_STG_CODE
155 extern DLL_IMPORT_RTS StgWordArray stg_CHARLIKE_closure;
156 extern DLL_IMPORT_RTS StgWordArray stg_INTLIKE_closure;
157 #else
158 extern DLL_IMPORT_RTS StgIntCharlikeClosure stg_CHARLIKE_closure[];
159 extern DLL_IMPORT_RTS StgIntCharlikeClosure stg_INTLIKE_closure[];
160 #endif
161
162 /* StgStartup */
163
164 RTS_RET(stg_forceIO);
165 RTS_RET(stg_noforceIO);
166
167 /* standard entry points */
168
169 /* standard selector thunks */
170
171 RTS_RET(stg_sel_ret_0_upd);
172 RTS_RET(stg_sel_ret_1_upd);
173 RTS_RET(stg_sel_ret_2_upd);
174 RTS_RET(stg_sel_ret_3_upd);
175 RTS_RET(stg_sel_ret_4_upd);
176 RTS_RET(stg_sel_ret_5_upd);
177 RTS_RET(stg_sel_ret_6_upd);
178 RTS_RET(stg_sel_ret_7_upd);
179 RTS_RET(stg_sel_ret_8_upd);
180 RTS_RET(stg_sel_ret_9_upd);
181 RTS_RET(stg_sel_ret_10_upd);
182 RTS_RET(stg_sel_ret_11_upd);
183 RTS_RET(stg_sel_ret_12_upd);
184 RTS_RET(stg_sel_ret_13_upd);
185 RTS_RET(stg_sel_ret_14_upd);
186 RTS_RET(stg_sel_ret_15_upd);
187
188 RTS_ENTRY(stg_sel_0_upd);
189 RTS_ENTRY(stg_sel_1_upd);
190 RTS_ENTRY(stg_sel_2_upd);
191 RTS_ENTRY(stg_sel_3_upd);
192 RTS_ENTRY(stg_sel_4_upd);
193 RTS_ENTRY(stg_sel_5_upd);
194 RTS_ENTRY(stg_sel_6_upd);
195 RTS_ENTRY(stg_sel_7_upd);
196 RTS_ENTRY(stg_sel_8_upd);
197 RTS_ENTRY(stg_sel_9_upd);
198 RTS_ENTRY(stg_sel_10_upd);
199 RTS_ENTRY(stg_sel_11_upd);
200 RTS_ENTRY(stg_sel_12_upd);
201 RTS_ENTRY(stg_sel_13_upd);
202 RTS_ENTRY(stg_sel_14_upd);
203 RTS_ENTRY(stg_sel_15_upd);
204
205 RTS_ENTRY(stg_sel_0_noupd);
206 RTS_ENTRY(stg_sel_1_noupd);
207 RTS_ENTRY(stg_sel_2_noupd);
208 RTS_ENTRY(stg_sel_3_noupd);
209 RTS_ENTRY(stg_sel_4_noupd);
210 RTS_ENTRY(stg_sel_5_noupd);
211 RTS_ENTRY(stg_sel_6_noupd);
212 RTS_ENTRY(stg_sel_7_noupd);
213 RTS_ENTRY(stg_sel_8_noupd);
214 RTS_ENTRY(stg_sel_9_noupd);
215 RTS_ENTRY(stg_sel_10_noupd);
216 RTS_ENTRY(stg_sel_11_noupd);
217 RTS_ENTRY(stg_sel_12_noupd);
218 RTS_ENTRY(stg_sel_13_noupd);
219 RTS_ENTRY(stg_sel_14_noupd);
220 RTS_ENTRY(stg_sel_15_noupd);
221
222 /* standard ap thunks */
223
224 RTS_THUNK(stg_ap_1_upd);
225 RTS_THUNK(stg_ap_2_upd);
226 RTS_THUNK(stg_ap_3_upd);
227 RTS_THUNK(stg_ap_4_upd);
228 RTS_THUNK(stg_ap_5_upd);
229 RTS_THUNK(stg_ap_6_upd);
230 RTS_THUNK(stg_ap_7_upd);
231
232 /* standard application routines (see also rts/gen_apply.py,
233 * and compiler/codeGen/CgStackery.lhs).
234 */
235 RTS_RET(stg_ap_v);
236 RTS_RET(stg_ap_f);
237 RTS_RET(stg_ap_d);
238 RTS_RET(stg_ap_l);
239 RTS_RET(stg_ap_n);
240 RTS_RET(stg_ap_p);
241 RTS_RET(stg_ap_pv);
242 RTS_RET(stg_ap_pp);
243 RTS_RET(stg_ap_ppv);
244 RTS_RET(stg_ap_ppp);
245 RTS_RET(stg_ap_pppv);
246 RTS_RET(stg_ap_pppp);
247 RTS_RET(stg_ap_ppppp);
248 RTS_RET(stg_ap_pppppp);
249
250 RTS_FUN_DECL(stg_ap_0_fast);
251 RTS_FUN_DECL(stg_ap_v_fast);
252 RTS_FUN_DECL(stg_ap_f_fast);
253 RTS_FUN_DECL(stg_ap_d_fast);
254 RTS_FUN_DECL(stg_ap_l_fast);
255 RTS_FUN_DECL(stg_ap_n_fast);
256 RTS_FUN_DECL(stg_ap_p_fast);
257 RTS_FUN_DECL(stg_ap_pv_fast);
258 RTS_FUN_DECL(stg_ap_pp_fast);
259 RTS_FUN_DECL(stg_ap_ppv_fast);
260 RTS_FUN_DECL(stg_ap_ppp_fast);
261 RTS_FUN_DECL(stg_ap_pppv_fast);
262 RTS_FUN_DECL(stg_ap_pppp_fast);
263 RTS_FUN_DECL(stg_ap_ppppp_fast);
264 RTS_FUN_DECL(stg_ap_pppppp_fast);
265 RTS_FUN_DECL(stg_PAP_apply);
266
267 /* standard GC & stack check entry points, all defined in HeapStackCheck.hc */
268
269 RTS_RET(stg_enter);
270 RTS_RET(stg_enter_checkbh);
271
272 RTS_RET(stg_gc_void);
273
274 RTS_FUN_DECL(__stg_gc_enter_1);
275 RTS_FUN_DECL(stg_gc_noregs);
276
277 RTS_RET(stg_gc_unpt_r1);
278 RTS_FUN_DECL(stg_gc_unpt_r1);
279
280 RTS_RET(stg_gc_unbx_r1);
281 RTS_FUN_DECL(stg_gc_unbx_r1);
282
283 RTS_RET(stg_gc_f1);
284 RTS_FUN_DECL(stg_gc_f1);
285
286 RTS_RET(stg_gc_d1);
287 RTS_FUN_DECL(stg_gc_d1);
288
289 RTS_RET(stg_gc_l1);
290 RTS_FUN_DECL(stg_gc_l1);
291
292 RTS_RET(stg_gc_fun);
293 RTS_FUN_DECL(__stg_gc_fun);
294
295 RTS_RET(stg_gc_gen);
296 RTS_FUN_DECL(stg_gc_gen);
297
298 RTS_RET(stg_ut_1_0_unreg);
299
300 RTS_FUN_DECL(stg_gc_gen_hp);
301 RTS_FUN_DECL(stg_gc_ut);
302 RTS_FUN_DECL(stg_gen_yield);
303 RTS_FUN_DECL(stg_yield_noregs);
304 RTS_FUN_DECL(stg_yield_to_interpreter);
305 RTS_FUN_DECL(stg_gen_block);
306 RTS_FUN_DECL(stg_block_noregs);
307 RTS_FUN_DECL(stg_block_1);
308 RTS_FUN_DECL(stg_block_blackhole);
309 RTS_FUN_DECL(stg_block_blackhole_finally);
310 RTS_FUN_DECL(stg_block_takemvar);
311 RTS_RET(stg_block_takemvar);
312 RTS_FUN_DECL(stg_block_putmvar);
313 RTS_RET(stg_block_putmvar);
314 #ifdef mingw32_HOST_OS
315 RTS_FUN_DECL(stg_block_async);
316 RTS_RET(stg_block_async);
317 RTS_FUN_DECL(stg_block_async_void);
318 RTS_RET(stg_block_async_void);
319 #endif
320 RTS_FUN_DECL(stg_block_stmwait);
321 RTS_FUN_DECL(stg_block_throwto);
322 RTS_RET(stg_block_throwto);
323
324 /* Entry/exit points from StgStartup.cmm */
325
326 RTS_RET(stg_stop_thread);
327
328 RTS_FUN_DECL(stg_returnToStackTop);
329 RTS_FUN_DECL(stg_returnToSched);
330 RTS_FUN_DECL(stg_returnToSchedNotPaused);
331 RTS_FUN_DECL(stg_returnToSchedButFirst);
332 RTS_FUN_DECL(stg_threadFinished);
333
334 RTS_FUN_DECL(stg_init_finish);
335 RTS_FUN_DECL(stg_init);
336
337 RTS_FUN_DECL(StgReturn);
338
339 /* -----------------------------------------------------------------------------
340 PrimOps
341 -------------------------------------------------------------------------- */
342
343 RTS_FUN_DECL(stg_plusIntegerzh);
344 RTS_FUN_DECL(stg_minusIntegerzh);
345 RTS_FUN_DECL(stg_timesIntegerzh);
346 RTS_FUN_DECL(stg_gcdIntegerzh);
347 RTS_FUN_DECL(stg_quotRemIntegerzh);
348 RTS_FUN_DECL(stg_quotIntegerzh);
349 RTS_FUN_DECL(stg_remIntegerzh);
350 RTS_FUN_DECL(stg_divExactIntegerzh);
351 RTS_FUN_DECL(stg_divModIntegerzh);
352
353 RTS_FUN_DECL(stg_cmpIntegerIntzh);
354 RTS_FUN_DECL(stg_cmpIntegerzh);
355 RTS_FUN_DECL(stg_integer2Intzh);
356 RTS_FUN_DECL(stg_integer2Wordzh);
357 RTS_FUN_DECL(stg_gcdIntegerIntzh);
358 RTS_FUN_DECL(stg_gcdIntzh);
359
360 RTS_FUN_DECL(stg_int2Integerzh);
361 RTS_FUN_DECL(stg_word2Integerzh);
362
363 RTS_FUN_DECL(stg_decodeFloatzuIntzh);
364 RTS_FUN_DECL(stg_decodeDoublezh);
365 RTS_FUN_DECL(stg_decodeDoublezu2Intzh);
366
367 RTS_FUN_DECL(stg_andIntegerzh);
368 RTS_FUN_DECL(stg_orIntegerzh);
369 RTS_FUN_DECL(stg_xorIntegerzh);
370 RTS_FUN_DECL(stg_complementIntegerzh);
371
372 #if SIZEOF_HSINT == 4
373
374 RTS_FUN_DECL(stg_int64ToIntegerzh);
375 RTS_FUN_DECL(stg_word64ToIntegerzh);
376
377 #endif
378
379 RTS_FUN_DECL(stg_unsafeThawArrayzh);
380 RTS_FUN_DECL(stg_newByteArrayzh);
381 RTS_FUN_DECL(stg_newPinnedByteArrayzh);
382 RTS_FUN_DECL(stg_newAlignedPinnedByteArrayzh);
383 RTS_FUN_DECL(stg_newArrayzh);
384 RTS_FUN_DECL(stg_newArrayArrayzh);
385
386 RTS_FUN_DECL(stg_newMutVarzh);
387 RTS_FUN_DECL(stg_atomicModifyMutVarzh);
388 RTS_FUN_DECL(stg_casMutVarzh);
389
390 RTS_FUN_DECL(stg_isEmptyMVarzh);
391 RTS_FUN_DECL(stg_newMVarzh);
392 RTS_FUN_DECL(stg_takeMVarzh);
393 RTS_FUN_DECL(stg_putMVarzh);
394 RTS_FUN_DECL(stg_tryTakeMVarzh);
395 RTS_FUN_DECL(stg_tryPutMVarzh);
396
397 RTS_FUN_DECL(stg_waitReadzh);
398 RTS_FUN_DECL(stg_waitWritezh);
399 RTS_FUN_DECL(stg_delayzh);
400 #ifdef mingw32_HOST_OS
401 RTS_FUN_DECL(stg_asyncReadzh);
402 RTS_FUN_DECL(stg_asyncWritezh);
403 RTS_FUN_DECL(stg_asyncDoProczh);
404 #endif
405
406 RTS_FUN_DECL(stg_catchzh);
407 RTS_FUN_DECL(stg_raisezh);
408 RTS_FUN_DECL(stg_raiseIOzh);
409
410 RTS_FUN_DECL(stg_makeStableNamezh);
411 RTS_FUN_DECL(stg_makeStablePtrzh);
412 RTS_FUN_DECL(stg_deRefStablePtrzh);
413
414 RTS_FUN_DECL(stg_forkzh);
415 RTS_FUN_DECL(stg_forkOnzh);
416 RTS_FUN_DECL(stg_yieldzh);
417 RTS_FUN_DECL(stg_killThreadzh);
418 RTS_FUN_DECL(stg_getMaskingStatezh);
419 RTS_FUN_DECL(stg_maskAsyncExceptionszh);
420 RTS_FUN_DECL(stg_maskUninterruptiblezh);
421 RTS_FUN_DECL(stg_unmaskAsyncExceptionszh);
422 RTS_FUN_DECL(stg_myThreadIdzh);
423 RTS_FUN_DECL(stg_labelThreadzh);
424 RTS_FUN_DECL(stg_isCurrentThreadBoundzh);
425 RTS_FUN_DECL(stg_threadStatuszh);
426
427 RTS_FUN_DECL(stg_mkWeakzh);
428 RTS_FUN_DECL(stg_mkWeakForeignzh);
429 RTS_FUN_DECL(stg_mkWeakForeignEnvzh);
430 RTS_FUN_DECL(stg_finalizzeWeakzh);
431 RTS_FUN_DECL(stg_deRefWeakzh);
432
433 RTS_FUN_DECL(stg_newBCOzh);
434 RTS_FUN_DECL(stg_mkApUpd0zh);
435
436 RTS_FUN_DECL(stg_retryzh);
437 RTS_FUN_DECL(stg_catchRetryzh);
438 RTS_FUN_DECL(stg_catchSTMzh);
439 RTS_FUN_DECL(stg_atomicallyzh);
440 RTS_FUN_DECL(stg_newTVarzh);
441 RTS_FUN_DECL(stg_readTVarzh);
442 RTS_FUN_DECL(stg_readTVarIOzh);
443 RTS_FUN_DECL(stg_writeTVarzh);
444 RTS_FUN_DECL(stg_checkzh);
445
446 RTS_FUN_DECL(stg_unpackClosurezh);
447 RTS_FUN_DECL(stg_getApStackValzh);
448 RTS_FUN_DECL(stg_getSparkzh);
449 RTS_FUN_DECL(stg_numSparkszh);
450
451 RTS_FUN_DECL(stg_noDuplicatezh);
452
453 RTS_FUN_DECL(stg_traceCcszh);
454 RTS_FUN_DECL(stg_traceEventzh);
455
456 /* Other misc stuff */
457 // See wiki:Commentary/Compiler/Backends/PprC#Prototypes
458
459 #if IN_STG_CODE && !IN_STGCRUN
460
461 // Interpreter.c
462 extern StgWord rts_stop_next_breakpoint[];
463 extern StgWord rts_stop_on_exception[];
464 extern StgWord rts_breakpoint_io_action[];
465
466 // Schedule.c
467 extern StgWord RTS_VAR(blocked_queue_hd), RTS_VAR(blocked_queue_tl);
468 extern StgWord RTS_VAR(sleeping_queue);
469 extern StgWord RTS_VAR(blackhole_queue);
470 extern StgWord RTS_VAR(sched_mutex);
471
472 // Apply.cmm
473 // canned bitmap for each arg type
474 extern StgWord stg_arg_bitmaps[];
475 extern StgWord stg_ap_stack_entries[];
476 extern StgWord stg_stack_save_entries[];
477
478 // Storage.c
479 extern unsigned int RTS_VAR(g0);
480 extern unsigned int RTS_VAR(large_alloc_lim);
481 extern StgWord RTS_VAR(weak_ptr_list);
482 extern StgWord RTS_VAR(atomic_modify_mutvar_mutex);
483
484 // RtsFlags
485 extern StgWord RTS_VAR(RtsFlags); // bogus type
486
487 // Stable.c
488 extern StgWord RTS_VAR(stable_ptr_table);
489
490 // Profiling.c
491 extern unsigned int RTS_VAR(era);
492 extern unsigned int RTS_VAR(entering_PAP);
493 extern StgWord RTS_VAR(CC_LIST); /* registered CC list */
494 extern StgWord RTS_VAR(CCS_LIST); /* registered CCS list */
495 extern StgWord CCS_SYSTEM[];
496 extern unsigned int RTS_VAR(CC_ID); /* global ids */
497 extern unsigned int RTS_VAR(CCS_ID);
498
499 #endif
500
501 #endif /* STGMISCCLOSURES_H */