- task->surf_action = NULL;
- if ((task->workstation_nb == 1)
- && (cost_or_zero(task->communication_amount, 0) == 0.0)) {
- task->surf_action =
- surf_workstation_model->extension.
- workstation.execute(surf_workstations[0],
- cost_or_zero(task->computation_amount, 0));
- } else if ((task->workstation_nb == 1)
- && (cost_or_zero(task->computation_amount, 0) == 0.0)) {
-
- task->surf_action =
- surf_workstation_model->extension.
- workstation.communicate(surf_workstations[0], surf_workstations[0],
- cost_or_zero(task->communication_amount,
- 0), task->rate);
- } else if ((task->workstation_nb == 2)
- && (cost_or_zero(task->computation_amount, 0) == 0.0)
- && (cost_or_zero(task->computation_amount, 1) == 0.0)) {
- int nb = 0;
- double value = 0.0;
-
- for (i = 0; i < task->workstation_nb * task->workstation_nb; i++) {
- if (cost_or_zero(task->communication_amount, i) > 0.0) {
- nb++;
- value = cost_or_zero(task->communication_amount, i);
- }
- }
- if (nb == 1) {
- task->surf_action =
- surf_workstation_model->extension.
- workstation.communicate(surf_workstations[0],
- surf_workstations[1], value, task->rate);
- }
- }
-#undef cost_or_zero