File tree Expand file tree Collapse file tree 2 files changed +13
-3
lines changed
Expand file tree Collapse file tree 2 files changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -50,8 +50,10 @@ CUB_NAMESPACE_BEGIN
5050
5151/* *
5252 * \brief GridBarrier implements a software global barrier among thread blocks within a CUDA grid
53+ *
54+ * deprecated [Since 2.9.0]
5355 */
54- class GridBarrier
56+ class CCCL_DEPRECATED_BECAUSE ( " Use the APIs from cooperative groups instead " ) GridBarrier
5557{
5658protected:
5759 using SyncFlag = unsigned int ;
@@ -131,8 +133,11 @@ public:
131133 *
132134 * Uses RAII for lifetime, i.e., device resources are reclaimed when
133135 * the destructor is called.
136+ *
137+ * deprecated [Since 2.9.0]
134138 */
135- class GridBarrierLifetime : public GridBarrier
139+ _CCCL_SUPPRESS_DEPRECATED_PUSH
140+ class CCCL_DEPRECATED_BECAUSE (" Use the APIs from cooperative groups instead" ) GridBarrierLifetime : public GridBarrier
136141{
137142protected:
138143 // Number of bytes backed by d_sync
@@ -211,5 +216,6 @@ public:
211216 return retval;
212217 }
213218};
219+ _CCCL_SUPPRESS_DEPRECATED_POP
214220
215221CUB_NAMESPACE_END
Original file line number Diff line number Diff line change @@ -47,7 +47,9 @@ using namespace cub;
4747/* *
4848 * Kernel that iterates through the specified number of software global barriers
4949 */
50- __global__ void Kernel (GridBarrier global_barrier, int iterations)
50+ _CCCL_SUPPRESS_DEPRECATED_PUSH
51+ __global__ void Kernel (GridBarrier global_barrier, int iterations) //
52+ _CCCL_SUPPRESS_DEPRECATED_POP
5153{
5254 for (int i = 0 ; i < iterations; i++)
5355 {
@@ -126,7 +128,9 @@ int main(int argc, char** argv)
126128 fflush (stdout);
127129
128130 // Init global barrier
131+ _CCCL_SUPPRESS_DEPRECATED_PUSH
129132 GridBarrierLifetime global_barrier;
133+ _CCCL_SUPPRESS_DEPRECATED_POP
130134 global_barrier.Setup (grid_size);
131135
132136 // Time kernel
You can’t perform that action at this time.
0 commit comments