|
1 | | -# SPDX-FileCopyrightText: Copyright (c) 2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved. |
| 1 | +# SPDX-FileCopyrightText: Copyright (c) 2025-2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved. |
2 | 2 | # SPDX-License-Identifier: Apache-2.0 |
3 | 3 |
|
4 | 4 | import multiprocessing as mp |
5 | 5 |
|
| 6 | +import pytest |
6 | 7 | from cuda.core import Buffer, DeviceMemoryResource |
7 | 8 | from helpers.buffers import PatternGen |
8 | 9 |
|
9 | | -CHILD_TIMEOUT_SEC = 20 |
| 10 | +CHILD_TIMEOUT_SEC = 30 |
10 | 11 | NBYTES = 64 |
11 | 12 | NWORKERS = 2 |
12 | 13 | NTASKS = 2 |
13 | 14 |
|
14 | 15 |
|
15 | 16 | class TestIpcMempool: |
| 17 | + @pytest.mark.flaky(reruns=2) |
16 | 18 | def test_main(self, ipc_device, ipc_memory_resource): |
17 | 19 | """Test IPC with memory pools.""" |
18 | 20 | # Set up the IPC-enabled memory pool and share it. |
@@ -54,6 +56,7 @@ def child_main(self, device, mr, queue): |
54 | 56 |
|
55 | 57 |
|
56 | 58 | class TestIPCMempoolMultiple: |
| 59 | + @pytest.mark.flaky(reruns=2) |
57 | 60 | def test_main(self, ipc_device, ipc_memory_resource): |
58 | 61 | """Test IPC with memory pools using multiple processes.""" |
59 | 62 | # Construct an IPC-enabled memory resource and share it with two children. |
@@ -104,6 +107,7 @@ def child_main(self, device, mr, seed, queue): |
104 | 107 |
|
105 | 108 |
|
106 | 109 | class TestIPCSharedAllocationHandleAndBufferDescriptors: |
| 110 | + @pytest.mark.flaky(reruns=2) |
107 | 111 | def test_main(self, ipc_device, ipc_memory_resource): |
108 | 112 | """ |
109 | 113 | Demonstrate that a memory pool allocation handle can be reused for IPC |
@@ -154,6 +158,7 @@ def child_main(self, device, alloc_handle, seed, queue): |
154 | 158 |
|
155 | 159 |
|
156 | 160 | class TestIPCSharedAllocationHandleAndBufferObjects: |
| 161 | + @pytest.mark.flaky(reruns=2) |
157 | 162 | def test_main(self, ipc_device, ipc_memory_resource): |
158 | 163 | """ |
159 | 164 | Demonstrate that a memory pool allocation handle can be reused for IPC |
|
0 commit comments