The complete minimal reproducer follows. Both source files are identical to the files compiled and run in this experiment, with no omissions. Save them in the same directory, then use the build and run commands below. The shared-memory size and compilation target match the tested B200 configuration.
Save the following CUDA kernel as shared_memory_kernel.cu:
extern "C" __global__ void shared_memory_probe(unsigned int *output,
unsigned int count) {
extern __shared__ unsigned int scratch[];
for (unsigned int i = threadIdx.x; i < count; i += blockDim.x)