Commit a84e0ff2 authored by Misbah Mubarak's avatar Misbah Mubarak

updates to i/o lang: modifying i/o lang-codes workload API to return correct...

updates to i/o lang: modifying i/o lang-codes workload API to return correct offsets according to the ranks
parent 2b5f713e
......@@ -275,7 +275,7 @@ int64_t ex(
var[1] = t1;
*inst_ready = 1;
return *group_rank;
return 1;
}
case GETGROUPSIZE:
{
......@@ -284,6 +284,7 @@ int64_t ex(
var[1] = t1;
*inst_ready = 1;
printf("\n group size is %d ", (int)var[1]);
return *group_size;
}
case GETCURTIME:
......
......@@ -147,9 +147,8 @@ void bgp_io_workload_get_next(int rank, struct codes_workload_op *op)
case CODES_WK_WRITE:
{
op->u.write.file_id = (next_wrkld->next_event).var[0];
op->u.write.offset = (next_wrkld->next_event).var[2];
op->u.write.offset = rank * (next_wrkld->next_event).var[2];
op->u.write.size = (next_wrkld->next_event).var[1];
//printf("\n Write size %d offset %d file id %d ", op->write.size, op->write.offset, op->write.file_id);
}
break;
case CODES_WK_DELAY:
......@@ -187,7 +186,7 @@ void bgp_io_workload_get_next(int rank, struct codes_workload_op *op)
case CODES_WK_READ:
{
op->u.read.file_id = (next_wrkld->next_event).var[0];
op->u.read.offset = (next_wrkld->next_event).var[2];
op->u.read.offset = rank * (next_wrkld->next_event).var[2];
op->u.read.size = (next_wrkld->next_event).var[1];
}
break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment