-
Notifications
You must be signed in to change notification settings - Fork 295
Revisit user object lifetime testing #2044
Copy link
Copy link
Open
Labels
P1Medium priority - Should doMedium priority - Should docuda.coreEverything related to the cuda.core moduleEverything related to the cuda.core moduletestImprovements or additions to testsImprovements or additions to tests
Milestone
Metadata
Metadata
Assignees
Labels
P1Medium priority - Should doMedium priority - Should docuda.coreEverything related to the cuda.core moduleEverything related to the cuda.core moduletestImprovements or additions to testsImprovements or additions to tests
Type
Fields
Give feedbackNo fields configured for Enhancement.
User objects attached to graphs require testing to ensure they are freed. The CUDA driver deallocates user objects asynchronously —
cuUserObjectCreaterequiresCU_USER_OBJECT_NO_DESTRUCTOR_SYNCas the only legal flag — making it difficult to write such tests. The current approach, used incuda_core/tests/graph/test_graph_definition_lifetime.py::test_kernel_args_buffer_lifetime(added in #2041 to address Rob's review comment on the original fix for #2039), relies on polling to observe cleanup. Leo flagged the polling pattern as unreliable for SWQA. Consider other approaches; the broader graph-ownership rework planned for #1330 is a likely place to revisit this.