int run_storage_tests(const ArrayModifier& modifier) { run_configuration(boost::c_storage_order(), boost::c_storage_order(),modifier); run_configuration(boost::fortran_storage_order(), boost::fortran_storage_order(),modifier); std::size_t ordering[] = {2,0,1,3}; bool ascending[] = {false,true,true,true}; run_configuration(boost::general_storage_order<3>(ordering,ascending), boost::general_storage_order<4>(ordering,ascending), modifier); return boost::exit_success; }
/** a: ACTOR $challenge {n:$counter} SEND $a $a **/ void test_erlang_challenge(int counter) { CONFIG* cfg; CONS* actor; int n; int m; DBUG_ENTER("test_erlang_challenge"); cfg = new_configuration(10); actor = CFG_ACTOR(cfg, challenge, map_put(NIL, ATOM("n"), NUMBER(counter))); CFG_SEND(cfg, actor, actor); for (m = 1; m < 1000000; ++m) { n = run_configuration(cfg, 1000000); if (cfg->q_count <= 0) { /* queue empty */ break; } } TRACE(printf("~%dM messages delivered.\n", m)); report_actor_usage(cfg); DBUG_RETURN; }