-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove superfluous checks for input data in kernel_pop() #673
base: master
Are you sure you want to change the base?
Conversation
parsec/mca/device/device_gpu.c
Outdated
@@ -2126,7 +2126,6 @@ parsec_device_kernel_pop( parsec_device_gpu_module_t *gpu_device, | |||
/* We need to manage all data that has been used as input, even if they were read only */ | |||
|
|||
/* Make sure data_in is not NULL */ | |||
if( NULL == this_task->data[i].data_in ) continue; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In PTG, we use this to detect that this flow is a control flow. Removing this line will probably create an issue with PTGs with control flows...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed the line from the PR. I have to check that this doesn't collide with TTG. If it does, I'll open an issue. Should not hold up this PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I checked the generated code in PTG, and we also initialize data_out
to NULL
by default. I think you can change this test for
if( NULL == this_task->data[i].data_in && NULL == this_task->data[i].data_out ) continue;
And that should keep the feature of control flows skipping in PTG, while allowing you to send flows that don't have a data_in
in TTG.
These checks have no relevance and cause problems in TTG because the input data pointers may change. Signed-off-by: Joseph Schuchart <joseph.schuchart@stonybrook.edu>
0fa4e0f
to
454413e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can remove the NULL check (this_task->data[i].data_in == NULL
) because it cannot happen due to the if
above, but the second part (original == this_task->data[i].data_in->original
) is helpful to detect the gpu copy has not been repurposed and attached to another data.
The index i
in the data is talking about a particular piece of data, allowing us to understand how it is going in and how it is affected by the kernel. But it talks about the same logical data, potentially different views of the same logical data, which is that having the same original
guarantee. Why do you want to reuse an existing data_out for a different copy instead of adding a new flow all ?
These checks have no relevance and cause problems in TTG because the input data pointers may change.