// BAMBOO_COORDS(c, x, y): convert the cpu # to coords (*x, *y) //
// BAMBOO_DEBUGPRINT(x): print out integer x //
// BAMBOO_DEBUGPRINT_REG(x): print out value of variable x //
-// BAMBOO_EXIT(x): exit routine //
-// BAMBOO_DIE(x): error exit routine //
+// BAMBOO_EXIT_APP(x): exit the whole application //
+// BAMBOO_EXIT(x): error exit routine with error # //
+// BAMBOO_DIE(x): error exit routine with error msg //
// BAMBOO_GET_EXE_TIME(): rountine to get current clock cycle number //
// BAMBOO_MSG_AVAIL(): checking if there are msgs coming in //
// BAMBOO_GCMSG_AVAIL(): checking if there are gcmsgs coming in //
BAMBOO_DEBUGPRINT(0xee05);
#endif
corestatus[BAMBOO_NUM_OF_CORE] = 1;
+ waitconfirm = true;
+ numconfirm = NUMCORESACTIVE - 1;
+ BAMBOO_ENTER_CLIENT_MODE_FROM_RUNTIME();
for(i = 1; i < NUMCORESACTIVE; ++i) {
corestatus[i] = 1;
// send status confirm msg to core i
send_msg_1(i, STATUSCONFIRM);
} // for(i = 1; i < NUMCORESACTIVE; ++i)
- waitconfirm = true;
- numconfirm = NUMCORESACTIVE - 1;
+ return;
} else {
// all the core status info are the latest
// terminate; for profiling mode, send request to all
while(halt--) {
}
} else {
+ BAMBOO_ENTER_CLIENT_MODE_FROM_RUNTIME();
break;
} // if(!allStall)
} // while(true)
#endif // #ifdef GC_PROFILE
#endif // #ifdef MULTICORE_GC
disruntimedata();
+ BAMBOO_ENTER_CLIENT_MODE_FROM_RUNTIME();
terminate(); // All done.
} // if(!waitconfirm)
} else {
// cache the msg first
//if(isMsgSending) {
cache_msg_5(STARTUPCORE, STATUSREPORT,
- busystatus?1:0, BAMBOO_NUM_OF_CORE,
- self_numsendobjs, self_numreceiveobjs);
+ busystatus?1:0, BAMBOO_NUM_OF_CORE,
+ self_numsendobjs, self_numreceiveobjs);
/*} else {
send_msg_5(STARTUPCORE, STATUSREPORT, busystatus?1:0,
BAMBOO_NUM_OF_CORE, self_numsendobjs,
#endif
#endif
disruntimedata();
- BAMBOO_EXIT(0);
+ BAMBOO_EXIT_APP(0);
}
INLINE void processmsg_memrequest_I() {