1. Gyanastra
  2. Computer Organisation and Architecture
  3. Memory Interfacing
  4. Concept of Memory Interleaving Across Modules
Free lesson, no account needed 6 min read 7 practice questions after it
Asked in past papers6 times
  • GATE CSE200619911990
  • ISRO2009
  • UGC NET20222012

Computer Organisation and Architecture · Memory Interfacing

Concept of Memory Interleaving Across Modules

Overview

Memory interleaving distributes the words of memory across several independent memory modules instead of storing them consecutively in one module, so that consecutive words can be accessed in parallel.
It matters because programs typically request blocks of consecutive words, and interleaving reduces the time for such a block from one access per word to a single access time.

Key concepts

  • Memory interleaving: a technique in which the words of memory are distributed across several independent memory modules rather than stored consecutively in a single module; the modules can be accessed in parallel, so a request for several consecutive words is served in the time of one access instead of one access per word.
  • Motivation: a program rarely reads just one word; it typically requests kk consecutive words (for example 4 words or 10 words).
    If those words all lie in one module they must be read one after another; if they lie in different modules that can be accessed in parallel, they are read together.
  • Round-robin distribution: consecutive words are placed in successive modules — word 1 in module 1, word 2 in module 2, word 3 in module 3, word 4 in module 4, then word 5 in module 1, word 6 in module 2, word 7 in module 3, word 8 in module 4, and so on.
  • Hard disk application: the same idea can be applied to a hard disk by distributing words across platters/surfaces, each with its own read/write head; the detailed disk case is a separate topic.

How it works

  1. The request: the processor asks for a block of consecutive words — word 1, word 2, word 3, word 4.
  2. Non-interleaved (single-module) arrangement: all four words are placed in one memory module and must be read sequentially — word 1, then word 2, then word 3, then word 4, one after the other.
    The total time is the sum of four access times, so the program runs slower.
  3. Interleaved arrangement: the words are distributed over four different modules — module 1 holds word 1, module 2 holds word 2, module 3 holds word 3, module 4 holds word 4.
    The next group repeats the pattern: word 5 in module 1, word 6 in module 2, word 7 in module 3, word 8 in module 4, and so on.
  4. Parallel access: because words 1–4 sit in four distinct modules, all four are fetched simultaneously in one memory access time. Operating the modules in parallel is exactly what gives the efficiency.

Formulas

  • Tserial=k×taccessT_{serial} = k \times t_{access} — time for kk consecutive words without interleaving, where kk is the number of consecutive words requested and taccesst_{access} is the access time of one memory module.

  • Tparallel=taccessT_{parallel} = t_{access} — time for kk words with interleaving (one word per module, all accessed in parallel); valid when the number of modules is at least kk and all kk modules can be driven simultaneously.

  • Speedup=TserialTparallel=k×taccesstaccess=kSpeedup = \dfrac{T_{serial}}{T_{parallel}} = \dfrac{k \times t_{access}}{t_{access}} = k — speedup from interleaving.

Worked examples

4 consecutive words, access time = 100 ns.

Non-interleaved case (all 4 words in one module):

WordModuleTime spent
word 1module 1100 ns
word 2module 1100 ns
word 3module 1100 ns
word 4module 1100 ns
Total100 + 100 + 100 + 100 = 400 ns

Interleaved case (words spread over four modules):

WordModuleTime spent
word 1module 1100 ns (parallel)
word 2module 2100 ns (parallel)
word 3module 3100 ns (parallel)
word 4module 4100 ns (parallel)
Total100 ns (all four fetched in parallel)

The pattern continues: word 5 → module 1, word 6 → module 2, word 7 → module 3, word 8 → module 4, and so on.

Result: 400 ns → 100 ns, a speedup of 4 for k=4k = 4 words.

Comparison

AspectWords in a single module (no interleaving)Words distributed over modules (interleaving)
Access of kk consecutive wordsSequential, one after anotherParallel, all at once
Time for 4 words at 100 ns400 ns100 ns
SpeedSlowerFaster (speedup ≈ number of modules used)
RequirementOne moduleMultiple independent modules that can be accessed in parallel

Revision summary

  • Programs request blocks of consecutive words (kk words, e.g. 4 or 10), not single words — this is why interleaving helps.
  • Memory interleaving means multiple memory modules with the words distributed among them so that consecutive words fall in different modules.
  • Consecutive words go round-robin: word 1 → module 1, word 2 → module 2, word 3 → module 3, word 4 → module 4, word 5 → module 1, and so on.
  • With kk words in kk modules accessed in parallel, time is one access time instead of kk access times; speedup is kk.
  • Numerical anchor: 4 words at 100 ns access time → 400 ns without interleaving, 100 ns with interleaving.
  • The parallel-time formula holds only when the number of modules is at least kk and all kk modules can be driven simultaneously.
  • The same interleaving idea applies to hard disks (distribution across platters/surfaces with separate read/write heads).

Previous-year exam insights

  • In low-order (address) interleaving, consecutive addresses go to consecutive banks (address mod m selects the bank); in high-order interleaving, each bank holds a contiguous block of addresses, so consecutive words fall in the same bank and cannot be fetched in parallel.
    Asked inGATE 2006UGC NET 2022
  • With m banks and a block of k consecutive words, the number of parallel rounds is ⌈k/m⌉;
    accesses to the same bank must be serialized, so total time = ⌈k/m⌉·(bank cycle time) + (k−1)·(bus transfer time).
    Asked inGATE 2006
  • Interleaved memory average access time per word: if successive requests go to different banks (for example consecutive addresses, address spacing 1 with n banks), the average time per word approaches T/n (T = bank cycle time);
    if successive requests all fall in the same bank (spacing a multiple of n), the average time is T.
    Asked inUGC NET 2022
  • Cached memory best suits small loops (high temporal locality, small working set); interleaved memory best suits large sequential code (streaming consecutive words).
    Asked inUGC NET 2012
  • Organizing memory into two banks so that 8-bit and 16-bit data operations are both possible is called two-way memory interleaving (bank switching is a different concept).
    Asked inISRO 2009
  • Interleaving increases effective bandwidth (words per unit time) by overlapping bank accesses; it does not reduce the access time of a single isolated word, which is still one bank cycle time.
Pages 1–2 of 2