ECE1756 lecture10 part1 2026: ram dsp and other blocks
Overview
The lecture explains how FPGA block RAM and LUT RAM architectures trade storage density, port flexibility, routing cost, and mapping efficiency. It compares SRAM port designs, Altera and Xilinx RAM implementations, and physical RAM sizes, showing why common FPGA designs prioritize one-read/one-write access and offer multiple memory sizes rather than maximizing flexibility in every block.
Key takeaways
- Simple dual-port SRAM is a strong FPGA default because it supports simultaneous FIFO reads and writes at eight transistors per bit, while its added routing cost is modest compared with the extra data connections required by wider port configurations.
- True dual-port RAM can reuse the same eight-transistor cells as simple dual-port RAM, but two full-width read and write paths make routing expensive; FPGA CAD tools commonly restrict its maximum word width instead.
- Altera reduces LUT RAM routing overhead by converting a whole 10-ALM logic block into a shared-address memory, enabling 64-by-10 or 32-by-20 configurations with about 15% extra block area.
- Different physical RAM sizes improve mapping efficiency: a 2,048-by-72 memory fits one 144-kilobit Stratix IV block, while a 1,024-by-8 memory fits a 9-kilobit block much more efficiently.
- LUT RAM is useful for small memories, achieving roughly 30 times the area efficiency of register-based implementations, while large block RAMs are substantially better for larger storage needs.
- FPGA on-chip memory capacity has increased from roughly 10 bits per logic element in 1995 to more than 100 in newer devices, but vendors continue to tune block size and port features rather than converging on one universal RAM architecture.
Chapters
- The lecture moves from FPGA logic blocks into physical RAM architecture, with further RAM mapping experiments planned for assignment three.
- RAM area depends on bit count, word width, and fixed peripheral overhead such as timing and control circuitry.
- Large RAMs reduce cost per bit but can be underused, while small RAMs waste less capacity but have higher cost per bit.
- A single read/write port uses one address bus, a write-data input, and a read-data output; modern FPGA connections generally avoid bidirectional data buses.
- A single-port SRAM cell uses six transistors per bit: four for cross-coupled inverters and two access transistors.
- A 1,024-word RAM needs 10 address bits; a 32-bit word adds 32 write-data inputs and 32 read-data outputs.
- Program memory and constants are good single-port use cases because they are written infrequently and read repeatedly.
- Simple dual-port RAM provides one dedicated read port and one dedicated write port, allowing a read and a write in the same cycle.
- FIFOs are a key use case because streaming hardware commonly reads and writes queue data simultaneously.
- The SRAM core rises from six to eight transistors per bit, while routing adds a second address bus and the write-data inputs.
- The second data bus adds less routing cost than it might seem because single-port FPGA RAMs already use separate read and write data connections.
- True dual-port RAM lets each of its two ports perform reads or writes, so a cycle can contain two reads, two writes, or one of each.
- Caches can benefit from the flexibility because they perform frequent lookups and occasional updates.
- The cell remains at eight transistors per bit, but true dual-port operation requires two sets of read sense amplifiers and write drivers.
- Two simultaneous reads or writes require wider data connections than simple dual-port mode, increasing routing-port cost.
- Simple quad-port RAM has two dedicated read ports and two dedicated write ports, supporting register files and shared-memory packet switches.
- Its SRAM cells require 12 transistors per bit: four for storage and eight for four pairs of access transistors.
- The four-port interface needs four address buses and two data words in each direction, making it too costly for many FPGA designs.
- Stratix 10 and Agilex use time-domain multiplexing with a simple dual-port RAM; at operating rates below roughly 600 MHz, the block can provide two accesses per cycle.
- Routing ports are expensive, so FPGA architectures commonly avoid providing the full two-word input and output width needed to use true dual-port RAM at maximum width.
- A proposed compromise is to support two reads but only one write, reflecting the common pattern of more reads than writes.
- Xilinx also uses internal broadcast connections to share some signals and reduce the number of external routing connections.
- Most architectures prioritize common RAM modes instead of paying for rarely used combinations such as two full-width writes.
- A physical RAM built with 32-bit data connections can support simple dual-port mode at 32 bits wide, but true dual-port use is restricted to narrower words.
- With configurable width circuitry, a 1,024-word by 32-bit block can become a 2,048-word by 16-bit block, enabling two simultaneous data operations.
- The CAD mapper enforces the width restriction because the physical RAM lacks enough routing ports for two full-width data paths.
- Benchmark examples indicate roughly 80% of requested RAMs use one read and one write, while about 10% use true dual-port behavior.
- A six-input LUT stores 64 one-bit values and acts as a ROM when its configuration bits are read through the LUT inputs.
- A fracturable LUT can also represent two 32-word by one-bit tables, giving a combined 32-word by two-bit configuration.
- Making a six-LUT writable requires a six-bit write address and one write-data bit in addition to its read inputs, for 13 total routing connections.
- The extra connections are expensive across millions of LUTs, motivating designs that share write-address signals.
- Altera converts all 10 ALMs in a logic block into RAM together, allowing the ALMs to share a write address while retaining separate write-data bits.
- In six-LUT mode, the logic block forms a 64-word by 10-bit RAM; fracturable mode can form a 32-word by 20-bit RAM.
- The shared address is assembled from spare connections across ALMs and broadcast internally, avoiding additional external routing ports.
- This LUT RAM approach adds about 15% to logic-block area.
- LUT RAM is about 30 times smaller than implementing comparable small memories with registers and logic, and complements block RAM for small storage needs.
- Xilinx UltraScale LUTs have fewer spare routing connections than Altera ALMs, so Xilinx sacrifices some LUT capacity to provide RAM write connections.
- For a single read/write port, Xilinx can connect the read and write addresses internally, forming RAMs such as 64 words by 8 bits.
- For one-read/one-write use, Xilinx can reserve one LUT in a logic block for write-address routing, leaving seven LUTs available as RAM.
- Stratix IV places LUT RAM capability in half of its logic blocks, limiting the maximum share of the device usable for LUT RAM.
- The architecture includes 144-kilobit and 9-kilobit block RAMs to accommodate different logical memory sizes and widths.
- Large physical RAMs amortize peripheral circuitry efficiently for large memories, while smaller blocks reduce capacity waste for smaller or unusually wide memories.
- The assignment-three architecture is modeled on this kind of mix of RAM resources.
- A 2,048-word by 72-bit simple dual-port RAM fits one Stratix IV 144-kilobit block, using about 0.22 mm² and reaching 336 MHz.
- Mapping the same memory to 9-kilobit blocks requires 18 blocks and nearly twice the area, though the smaller blocks can run faster.
- LUT RAM uses about 13 times the area of the large block RAM and runs at roughly 40% of its speed; registers and logic take about 313 times the area.
- For a 1,024-word by 8-bit RAM, one 9-kilobit block is a near fit and about 10 times smaller than using a 144-kilobit block.
- Altera architecture experiments found that one 20-kilobit RAM per 10 logic blocks performed best on average for the tested benchmark set.
- A mix of large and small RAMs could outperform a single 40-kilobit size, but the gain must justify the extra layout complexity.
- A 20-kilobit block also suited error-correcting-code circuitry, with a maximum word width of 36 bits.
- FPGA memory capacity has grown from about 10 memory bits per logic element in 1995 to more than 100 in newer devices, although block sizes still vary by architecture.
- Recent Altera devices use 20-kilobit main block RAMs, while Xilinx devices use 18-kilobit blocks configurable from 18,000 words by 1 bit to 512 words by 36 bits.
- Like Altera, Xilinx restricts true dual-port mode to a maximum width of 18 bits to avoid adding more routing ports.
- Xilinx can combine two 18-kilobit blocks into a 36-kilobit RAM using dedicated hard circuitry rather than soft logic.
- Newer Xilinx devices also include 288-kilobit blocks, with configurations such as 4,000 words by 72 bits.
- LUT RAM writes are synchronized to a clock because arbitrary-time writes are difficult to implement efficiently, while LUT reads remain combinational.
- Early Altera LUT RAM reused existing logic-block registers on the write path, but programmable interconnect between those registers and RAM circuitry limited write speed.
- Later Stratix 10 designs embedded registers directly in the write circuitry, improving timing at the cost of dedicated registers.
- Xilinx also synchronizes LUT RAM writes to a write clock, though the exact register implementation is not detailed here.
Transcript excerpt
0:00 Okay. Uh, let's see. I'm going to turn off some of these lights. Okay, seems reasonable. Uh, okay. Welcome, everybody. So, we let's see. Last week's reading was about uh Xilinx's Versal architecture. Um, and this week's reading is about Altera's uh latest architecture. Uh, well they actually just released a a new version of Agilex, but there's no paper on that. So, this is their almost latest architecture, which is the one that you actually used in uh assignment one and two. Um, and we'll be gradually talking about features. We've been talking about some features in these chips. We'll keep talking about them as we uh go through the last few lectures of the course. Uh, okay. So, where are we? So, we made it through uh basically we're down in this red part of
0:47 the course about the detailed architecture of how you make good FPGAs. And we've talked about uh logic blocks now. And we've talked about we're kind of halfway through maybe a little more than halfway through RAM blocks. We'll talk about a few other kinds of blocks that you put in, and then we'll get started but not get all the way through how you make routing architectures. Uh, so yeah, we're down into detailed components of everything right now. Okay, so hopefully you remember how you build backup. Do you remember how you build a RAM uh in general? So, we went through what an SRAM looks like inside. So, you have a model of the cost. Uh, its area goes up as you have more bits. Its area goes up as you have wider words uh cuz you need more sense amps and so on. Uh, and there's some fixed area just to
1:34 put in like the timers and the overall
This is the start of the transcript. Save this video free for the whole transcript, searchable and time-coded.
In this course
Related notes
Summary, takeaways, and chapters were generated by AI from the video's transcript and may contain errors. The video belongs to its creator, Vaughn Betz.