parsec icon indicating copy to clipboard operation
parsec copied to clipboard

Provide mechanism to discard data

Open devreal opened this issue 1 year ago • 3 comments

Add a function parsec_data_discard that releases the data such that the host copy remains intact but does not prevent destruction of the data once all device copies have been released. This keeps the host copy available for device copies to inspect and avoids potential race conditions in the release process. During an eviction, copies of data with a discarded host copy are not transfered but put directly into the lru.

Replaces some duplicated code with a call to parsec_device_release_gpu_copy.

devreal avatar Nov 08 '24 19:11 devreal

will review that it doesn't break dplasma and merge

abouteiller avatar Jan 30 '25 16:01 abouteiller

I modified this PR so that parsec_data_discard notifies the device(s) about discarded data. If the device finds that it has discarded data, it will try to release that data. Otherwise we don't the pay the cost of iterating through the LRU. This simplified the w2r task creation back to something sane(r) I had earlier.

devreal avatar Feb 14 '25 21:02 devreal

This may not be needed anymore if we get parsec_data_release_self_contained_data from #671: https://github.com/ICLDisco/parsec/pull/671/files#diff-b76b62ea20f19d97740a2221cabf57210f9f97991c0ef635ca0cafcc4c3c40d1R596

devreal avatar Feb 25 '25 16:02 devreal