Host *HostL07Model::createHost(const char *name,RoutingEdge *netElm, Cpu *cpu)
{
- HostL07 *host = new HostL07(this, name, NULL, netElm, cpu);
-
- surf_callback_emit(hostCreatedCallbacks, host);
- xbt_lib_set(host_lib, name, SURF_HOST_LEVEL, host);
-
- return host;
+ return new HostL07(this, name, NULL, netElm, cpu);
}
Action *NetworkL07Model::communicate(RoutingEdge *src, RoutingEdge *dst,
xbt_dict_t cpu_properties)
{
double power_initial = xbt_dynar_get_as(powerPeak, pstate, double);
- sg_host_t sg_host = sg_host_by_name(name);
-
CpuL07 *cpu = new CpuL07(this, name, cpu_properties,
power_initial, power_scale, power_trace,
core, state_initial, state_trace);
- sg_host_surfcpu_register(sg_host, cpu);
return cpu;
}
host_list[0] = sg_host_by_name(getName());
flops_amount[0] = size;
- return static_cast<HostL07Model*>(getModel())->executeParallelTask(1, host_list,
- flops_amount,
- bytes_amount, -1);
+ return static_cast<CpuL07Model*>(getModel())
+ ->p_hostModel
+ ->executeParallelTask( 1, host_list, flops_amount, bytes_amount, -1);
}
Action *CpuL07::sleep(double duration)