From 99e0f1589aaf90679813af7ab86409eaf1bf9715 Mon Sep 17 00:00:00 2001 From: Andy Jost Date: Mon, 17 Aug 2026 13:58:46 -0700 Subject: [PATCH] test(cuda.core): synchronize IPC buffer initialization Ensure the exporting process completes asynchronous allocation and initialization before an importing child accesses the shared buffer. --- cuda_core/tests/memory_ipc/test_peer_access.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cuda_core/tests/memory_ipc/test_peer_access.py b/cuda_core/tests/memory_ipc/test_peer_access.py index 4dc04a8bd0b..c54ace82c54 100644 --- a/cuda_core/tests/memory_ipc/test_peer_access.py +++ b/cuda_core/tests/memory_ipc/test_peer_access.py @@ -82,6 +82,8 @@ def test_main(self, ipc_mempool_device_x2, grant_access_in_parent): buffer = mr.allocate(NBYTES, stream=dev1.default_stream) pgen = PatternGen(dev1, NBYTES) pgen.fill_buffer(buffer, seed=False) + # IPC import does not carry the exporting process's stream ordering. + dev1.sync() # Spawn child process process = mp.Process(target=self.child_main, args=(mr, buffer))