/* DEFS: message CkQdMsg;
 */
#ifndef CK_TEMPLATES_ONLY
void *CMessage_CkQdMsg::operator new(size_t s){
  return CkQdMsg::alloc(__idx, s, 0, 0);
}
void *CMessage_CkQdMsg::operator new(size_t s,const int pb){
  return CkQdMsg::alloc(__idx, s, 0, pb);
}
void *CMessage_CkQdMsg::operator new(size_t s, int* sz){
  return CkQdMsg::alloc(__idx, s, sz, 0);
}
void *CMessage_CkQdMsg::operator new(size_t s, int* sz,const int pb){
  return CkQdMsg::alloc(__idx, s, sz, pb);
}
void* CMessage_CkQdMsg::alloc(int msgnum, size_t sz, int *sizes, int pb) {
  int offsets[1];
  offsets[0] = ALIGN8(sz);
  CkQdMsg *newmsg = (CkQdMsg *) CkAllocMsg(msgnum, offsets[0], pb);
  return (void *) newmsg;
}
void* CMessage_CkQdMsg::pack(CkQdMsg *msg) {
  return (void *) msg;
}
CkQdMsg* CMessage_CkQdMsg::unpack(void* buf) {
  CkQdMsg *msg = (CkQdMsg *) buf;
  return msg;
}
int CMessage_CkQdMsg::__idx=0;
#endif

/* DEFS: message FutureInitMsg;
 */
#ifndef CK_TEMPLATES_ONLY
void *CMessage_FutureInitMsg::operator new(size_t s){
  return FutureInitMsg::alloc(__idx, s, 0, 0);
}
void *CMessage_FutureInitMsg::operator new(size_t s,const int pb){
  return FutureInitMsg::alloc(__idx, s, 0, pb);
}
void *CMessage_FutureInitMsg::operator new(size_t s, int* sz){
  return FutureInitMsg::alloc(__idx, s, sz, 0);
}
void *CMessage_FutureInitMsg::operator new(size_t s, int* sz,const int pb){
  return FutureInitMsg::alloc(__idx, s, sz, pb);
}
void* CMessage_FutureInitMsg::alloc(int msgnum, size_t sz, int *sizes, int pb) {
  int offsets[1];
  offsets[0] = ALIGN8(sz);
  FutureInitMsg *newmsg = (FutureInitMsg *) CkAllocMsg(msgnum, offsets[0], pb);
  return (void *) newmsg;
}
void* CMessage_FutureInitMsg::pack(FutureInitMsg *msg) {
  return (void *) msg;
}
FutureInitMsg* CMessage_FutureInitMsg::unpack(void* buf) {
  FutureInitMsg *msg = (FutureInitMsg *) buf;
  return msg;
}
int CMessage_FutureInitMsg::__idx=0;
#endif

/* DEFS: group FutureBOC{
FutureBOC(FutureInitMsg*);
void SetFuture(FutureInitMsg*);
};
 */
#ifndef CK_TEMPLATES_ONLY
int CProxy_FutureBOC::__idx=0;
#endif
#ifndef CK_TEMPLATES_ONLY
    void CProxy_FutureBOC::__register(const char *s, size_t size) {
      __idx = CkRegisterChare(s, size);
    /* REG: FutureBOC(FutureInitMsg*);
*/
      __idx_FutureBOC_FutureInitMsg = CkRegisterEp("FutureBOC", (CkCallFnPtr)_call_FutureBOC_FutureInitMsg, CMessage_FutureInitMsg::__idx, __idx);

    /* REG: void SetFuture(FutureInitMsg*);
*/
      __idx_SetFuture_FutureInitMsg = CkRegisterEp("SetFuture", (CkCallFnPtr)_call_SetFuture_FutureInitMsg, CMessage_FutureInitMsg::__idx, __idx);
    }
#endif
#ifndef CK_TEMPLATES_ONLY
/* DEFS: FutureBOC(FutureInitMsg*);
 */
int CProxy_FutureBOC::__idx_FutureBOC_FutureInitMsg=0;
CkGroupID CProxy_FutureBOC::ckNew(FutureInitMsg*msg)
{
  return CkCreateGroup(__idx, __idx_FutureBOC_FutureInitMsg, msg, 0, 0);
}
CkGroupID CProxy_FutureBOC::ckNewSync(FutureInitMsg*msg)
{
  return CkCreateGroupSync(__idx, __idx_FutureBOC_FutureInitMsg, msg);
}
  CProxy_FutureBOC::CProxy_FutureBOC(FutureInitMsg*msg, int retEP, CkChareID *cid)
{
  _ck_gid = CkCreateGroup(__idx, __idx_FutureBOC_FutureInitMsg, msg, retEP, cid);
  _setChare(0);
}
  CProxy_FutureBOC::CProxy_FutureBOC(FutureInitMsg*msg)
{
  _ck_gid = CkCreateGroup(__idx, __idx_FutureBOC_FutureInitMsg, msg, 0, 0);
  _setChare(0);
}
void CProxy_FutureBOC::_call_FutureBOC_FutureInitMsg(void* msg, FutureBOC* obj)
{
  new (obj) FutureBOC((FutureInitMsg*)msg);
}

/* DEFS: void SetFuture(FutureInitMsg*);
 */
int CProxy_FutureBOC::__idx_SetFuture_FutureInitMsg=0;
void CProxy_FutureBOC::_call_SetFuture_FutureInitMsg(void* msg, FutureBOC* obj)
{
  obj->SetFuture((FutureInitMsg*)msg);
}
#endif /*CK_TEMPLATES_ONLY*/

/* DEFS: mainchare FutureMain{
FutureMain();
};
 */
#ifndef CK_TEMPLATES_ONLY
int CProxy_FutureMain::__idx=0;
#endif
#ifndef CK_TEMPLATES_ONLY
    void CProxy_FutureMain::__register(const char *s, size_t size) {
      __idx = CkRegisterChare(s, size);
    /* REG: FutureMain();
*/
      __idx_FutureMain = CkRegisterEp("FutureMain", (CkCallFnPtr)_call_FutureMain, 0, __idx);
      CkRegisterMainChare(__idx, __idx_FutureMain);
    }
#endif
#ifndef CK_TEMPLATES_ONLY
/* DEFS: FutureMain();
 */
int CProxy_FutureMain::__idx_FutureMain=0;
void CProxy_FutureMain::ckNew(int onPE)
{
      void *msg = CkAllocSysMsg();
  CkCreateChare(__idx, __idx_FutureMain, msg, 0, onPE);
}
void CProxy_FutureMain::ckNew(CkChareID* pcid, int onPE)
{
      void *msg = CkAllocSysMsg();
  CkCreateChare(__idx, __idx_FutureMain, msg, pcid, onPE);
}
  CProxy_FutureMain::CProxy_FutureMain(int onPE)
{
      void *msg = CkAllocSysMsg();
  CkCreateChare(__idx, __idx_FutureMain, msg, &_ck_cid, onPE);
}
void CProxy_FutureMain::_call_FutureMain(CkArgMsg* msg, FutureMain* obj)
{
  new (obj) FutureMain((CkArgMsg*)msg);
}
#endif /*CK_TEMPLATES_ONLY*/

/* DEFS: readonly CkGroupID _fbocID;
 */
extern CkGroupID _fbocID;

#ifndef CK_TEMPLATES_ONLY
void _registerCkFutures(void)
{
  static int _done = 0; if(_done) return; _done = 1;
/* REG: message CkQdMsg;
*/
CMessage_CkQdMsg::__register("CkQdMsg", sizeof(CkQdMsg),(CkPackFnPtr) CkQdMsg::pack,(CkUnpackFnPtr) CkQdMsg::unpack);

/* REG: message FutureInitMsg;
*/
CMessage_FutureInitMsg::__register("FutureInitMsg", sizeof(FutureInitMsg),(CkPackFnPtr) FutureInitMsg::pack,(CkUnpackFnPtr) FutureInitMsg::unpack);

/* REG: group FutureBOC{
FutureBOC(FutureInitMsg*);
void SetFuture(FutureInitMsg*);
};
*/
  CProxy_FutureBOC::__register("FutureBOC", sizeof(FutureBOC));

/* REG: mainchare FutureMain{
FutureMain();
};
*/
  CProxy_FutureMain::__register("FutureMain", sizeof(FutureMain));

  CkRegisterReadonly(sizeof(CkGroupID), (void *) &_fbocID);

}
#endif
