3 * - By John Hodge (thePowersGang)
6 * - One-time construction API
12 #define FLAG_INIT_COMPLETE (1<<0)
13 #define FLAG_INIT_LOCKED (1<<1)
15 extern "C" int __cxa_guard_acquire ( int64_t *guard_object )
18 if( *guard_object == FLAG_INIT_COMPLETE )
20 if( *guard_object == FLAG_INIT_LOCKED ) {
21 _SysDebug("ERROR: __cxa_guard_acquire - nested");
23 *guard_object = FLAG_INIT_LOCKED;
27 extern "C" void __cxa_guard_release ( int64_t *guard_object )
29 *guard_object = FLAG_INIT_COMPLETE;
32 extern "C" void __cxa_guard_abort ( int64_t *guard_object )
34 *guard_object = FLAG_INIT_COMPLETE;
35 _SysDebug("__cxa_guard_abort");