/* task is being executed on this host. so change the affinity now */
{
/* check it works. remove me if it works. */
- unsigned long affinity_mask = (unsigned long) xbt_dict_get_or_null_ext(task->simdata->affinity_mask_db, (char *) host, sizeof(msg_host_t));
- xbt_assert(affinity_mask == mask);
+ xbt_assert((unsigned long) xbt_dict_get_or_null_ext(task->simdata->affinity_mask_db, (char *) host, sizeof(msg_host_t)) == mask);
}
XBT_INFO("set affinity(0x%04lx@%s) for %s", mask, MSG_host_get_name(host), MSG_task_get_name(task));
// XBT_INFO("micro shutdown: mbox %s", mbox);
msg_error_t ret = MSG_task_send(task, mbox);
- xbt_assert(ret == MSG_OK);
+ if(ret != MSG_OK)
+ xbt_die("shutdown error - task not sent");
xbt_free(mbox);
// XBT_INFO("shutdown done");
// XBT_INFO("req overhead");
msg_error_t ret = MSG_task_send(task, mbox);
- xbt_assert(ret == MSG_OK);
+ if(ret != MSG_OK)
+ xbt_die("req overhead error - task not sent");
xbt_free(mbox);
}
request_overhead(comm_task, data_size * alpha);
msg_error_t ret = MSG_task_send(mtask, mbox);
- xbt_assert(ret == MSG_OK);
+ if(ret != MSG_OK)
+ xbt_die("migration error - task not sent");
xbt_free(mtask_name);
}
void SIMIX_vm_migrate(smx_host_t ind_vm, smx_host_t ind_dst_pm)
{
/* precopy migration makes the VM temporally paused */
- e_surf_vm_state_t state = SIMIX_vm_get_state(ind_vm);
- xbt_assert(state == SURF_VM_STATE_SUSPENDED);
+ xbt_assert(SIMIX_vm_get_state(ind_vm) == SURF_VM_STATE_SUSPENDED);
/* jump to vm_ws_xigrate(). this will update the vm location. */
surf_vm_workstation_migrate(ind_vm, ind_dst_pm);
eq = control_string;
control_string += strcspn(control_string, " ");
- xbt_assert(*dot == '.' && (*eq == '=' || *eq == ':'),
- "Invalid control string '%s'", orig_control_string);
+ if(*dot != '.' && (*eq == '=' || *eq == ':'))
+ xbt_die ("Invalid control string '%s'", orig_control_string);
if (!strncmp(dot + 1, "threshold", (size_t) (eq - dot - 1))) {
int i;