Bug fixes for gc
[IRC.git] / Robust / src / Runtime / bamboo / multicoreruntime.c
index 496fc086bc14d43c33df6bbfb534ec17276438b9..89a2dbe21f1adef0963552351ab31ea120447061 100644 (file)
@@ -777,12 +777,16 @@ inline void run(int argc, char** argv) {
     BAMBOO_DEBUGPRINT(0xee00);
 #endif
 
-#ifdef MGC
        if(STARTUPCORE == BAMBOO_NUM_OF_CORE) {
+#ifdef TASK
+         // run the initStaticAndGlobal method to initialize the static blocks and
+         // global fields
+         initStaticAndGlobal();
+#elif defined MGC
          // run the main method in the specified mainclass
          mgc_main(argc, argv);
+#endif // TASK
        }
-#endif
 
     while(true) {