Shared memory bank conflict
A shared memory bank conflict occurs when concurrent GPU threads access different addresses mapped to the same memory bank, requiring additional or serialized servicing.
Grokking GPU Programming
A bank conflict occurs when threads in the same GPU warp access different data assigned to the same shared-memory bank, requiring serialized service.
- How it is used
- Diagnoses slow shared-memory accesses and guides padding fixes for conflicting access patterns.
- How deep it goes
- Explains bank mapping, warp access patterns, serialized conflicts, padding, and limits of the example’s assumptions.
- Examples
- Uses stride-1 and stride-2 reads, a 32×32 column-access tile, and padding to 32×33 elements.
- What you can do after
- Diagnose serialized shared-memory accesses and choose padding after checking the bank mapping.
Read how Grokking GPU Programming explains shared memory bank conflict →
CUDA for LLMs
A shared memory bank conflict occurs when concurrent GPU memory requests contend for the same shared-memory bank and require additional servicing.
- How it is used
- Identifies shared-memory access patterns that may hinder tiled GEMM performance.
- How deep it goes
- Defines same-bank contention and asks learners to locate potentially conflicting accesses and propose a layout change.
- Examples
- Examines As and Bs accesses in a tiled GEMM inner loop.
- What you can do after
- Diagnose potential conflicts in As and Bs accesses and propose a shared-memory layout modification.
Read how CUDA for LLMs explains shared memory bank conflict →
Also covered in
- GPU Programming with TritonIn early access (MEAP)
What to know first
- hardware registerA hardware register is a small, rapidly accessible storage location within a processor or processing device that holds data, addresses, or control information during execution.
- GPU memoryGPU memory is memory available to a graphics processing unit for storing data and state used in graphics or computation.
- shared memoryShared memory is a memory region accessible to multiple processes, threads, or other concurrent execution contexts for sharing data.
- thread blockA thread block is a group of GPU threads organized to execute together and cooperate using shared resources.
Related concepts
- paddingaddressed by · Padding is the provision of extra values, characters, bytes, or space around or within data or an element to meet length, boundary, block-size, spacing, or alignment requirements.
- blelloch algorithmproduced by · The Blelloch algorithm is a work-efficient parallel algorithm for computing a scan using an up-sweep followed by a down-sweep.
- shared memory broadcastcontrasts with · A shared memory broadcast supplies one shared-memory value to multiple threads in a warp reading the same address.
- uncoalesced memory accessequivalent to · Uncoalesced memory access is a GPU access pattern in which threads access addresses that cannot be efficiently combined into a small number of memory transactions.
- tileproduced by · A tile is a bounded block of elements from a larger array, matrix, or tensor that is treated as a unit of computation.
Questions about shared memory bank conflict
What is shared memory bank conflict?
A shared memory bank conflict occurs when concurrent GPU threads access different addresses mapped to the same memory bank, requiring additional or serialized servicing.
Which Manning books explain shared memory bank conflict?
Grokking GPU Programming and CUDA for LLMs.
What should I know before learning shared memory bank conflict?
Manning books that teach shared memory bank conflict usually introduce hardware register, GPU memory, shared memory and thread block first.
What is the difference between shared memory bank conflict and shared memory broadcast?
A shared memory bank conflict occurs when concurrent GPU threads access different addresses mapped to the same memory bank, requiring additional or serialized servicing. A shared memory broadcast supplies one shared-memory value to multiple threads in a warp reading the same address.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.

