TDEB Top Bar

Trending
Semiconductor Industry News — The Digital Electronics Blog
Follow Us

TDEB Masthead

The Semiconductor Hub

Semiconductors.  Chips and Systems.  Innovation.

Indexed by leading Search Engines, AI and referenced by Engineers worldwide 500+ Articles 10M+ Pageviews 30+ Reports 50+ Citations

How to Benchmark an FPGA Accelerator on Performance, Power and Accuracy

Murugavel Ganesan
by
1
Share Facebook X LinkedIn WhatsApp Email

To benchmark an FPGA accelerator fairly, measure three things on the same realistic workload: performance (throughput, latency and speedup over a baseline), power and energy (measured at the board or wall, not only estimated), and accuracy (error against a trusted reference). Report them together, because an FPGA design can trade one against the others, for example by using lower-precision arithmetic to gain speed and save power at some cost in accuracy. Above all, define the baseline, the data set and what is included in the timing and power boundary, so others can reproduce the result.

FPGA accelerators are popular for applications that need high performance, low power and good accuracy. Evaluating and benchmarking them is not trivial, as there are many factors and metrics to consider. This post covers the challenges and best practices, with examples of how to measure each metric.

Key takeaways

  • State the measurement boundary: kernel only, kernel plus host-device transfers, or the full application.
  • Report throughput and latency separately. Batching raises throughput but usually raises latency too.
  • Performance per watt (operations per second per watt) and energy per operation (operations per joule) are the same quantity in different units.
  • Measure power on hardware where possible. Tool estimates are useful during design but are not a substitute.
  • Accuracy matters most when the FPGA uses fixed-point or reduced-precision arithmetic. Compare against a double-precision or framework reference.

Performance in plain words

Performance shows how fast the accelerator processes input data and produces results. Three numbers cover most cases: how much work it does per second (throughput), how long one piece of work takes from start to finish (latency), and how much faster it is than a baseline such as a CPU or GPU (speedup). Use realistic input data, include the time to move data to and from the card if a real application would pay it, and compare against a well-tuned competitor, not a naive one.

Power in plain words

Power shows how much electrical energy the accelerator uses while it works. What matters for most comparisons is not the power alone but the work done per unit of energy: a card that draws more watts but finishes much sooner can still use less energy per task. Measure on real hardware where you can, and say whether the figure covers just the card or the whole server.

Accuracy in plain words

FPGA designs often use narrower numbers than a CPU (8-bit or 16-bit fixed point instead of 32-bit or 64-bit floating point) because narrower arithmetic is smaller, faster and uses less power. The cost is some error. Accuracy measures that error against a trusted reference, so readers can see what the speed and power savings cost.

A simple benchmarking checklist

  1. Fix the workload, data set, batch size and numeric precision, and record them.
  2. Choose a baseline that is well optimized, not a naive single-threaded version.
  3. Define the timing boundary and the power boundary, and use the same ones for every platform.
  4. Warm up, then run long enough for stable results; repeat runs and report the spread.
  5. Record board, FPGA part, clock frequency, tool version and resource use (LUTs, DSPs, BRAM).
  6. Report performance, power, energy and accuracy together in one table.

Deep dive: the numbers and details

This part holds the metric definitions with units, the roofline model, worked examples for performance per watt and PSNR, and common mistakes. Skip it if the overview is all you need.

Performance metrics

  • Throughput is the amount of data or work processed per unit time, usually expressed in megabytes per second (MB/s), gigabytes per second (GB/s), operations per second (OPS), or a domain unit such as frames or inferences per second.
  • Latency is the time elapsed between the start and the end of a computation, usually expressed in milliseconds (ms), microseconds (µs) or nanoseconds (ns). Report percentiles (for example median and 99th percentile), not only the average.
  • Speedup is the ratio of the execution time of a baseline system (such as a CPU or a GPU) to the execution time of the FPGA accelerator, a dimensionless number.

Consider the overheads and bottlenecks that can affect performance, such as data transfer over PCIe, memory access, host communication and synchronization. Compare the FPGA accelerator with competing solutions, such as CPUs, GPUs and ASICs, using fair and consistent benchmarks.

Where performance is lost: the roofline model

The roofline model from Williams, Waterman and Patterson (UC Berkeley technical report UCB/EECS-2008-134) gives a quick upper bound. A kernel's operational intensity I is the number of operations it performs per byte fetched from off-chip memory. Then:

attainable performance = min( peak compute ,  memory bandwidth x I )

Worked example with illustrative numbers. Suppose an FPGA design can do 2 TOPS peak, and the card's DDR memory gives 40 GB/s.

  • A kernel with I = 10 operations per byte is limited to 40 x 10 = 400 GOPS, far below the 2 TOPS peak. It is memory bound; adding more DSP blocks will not help, but on-chip buffering to raise I will.
  • A kernel with I = 100 operations per byte could reach 4 TOPS from memory, so it is capped at the 2 TOPS compute peak. It is compute bound.
  • The crossover is at I = 2,000 / 40 = 50 operations per byte.

If the measured throughput is far below both limits, the problem is usually in the pipeline (stalls, a poor initiation interval, a low clock frequency) or in the host interface.

Power and energy metrics

  • Power consumption is the rate at which the accelerator uses electrical energy, expressed in watts (W) or milliwatts (mW). Distinguish static (idle) power from dynamic power under load.
  • Power efficiency is performance divided by power, expressed in operations per second per watt (OPS/W). Because one watt is one joule per second, OPS/W is numerically the same as operations per joule (OP/J). Operations per kilowatt-hour (OP/kWh) is the same idea in a larger energy unit.
  • Energy consumption is the electrical energy used for a given task, expressed in joules (J) or kilojoules (kJ). It equals average power multiplied by run time.
  • Energy efficiency is the work done per unit of energy, expressed in operations per joule (OP/J) or operations per kilojoule (OP/kJ). Its inverse, energy per operation (for example nanojoules per inference), is often easier to compare.

To measure power, use equipment that can capture the dynamic power variations of the accelerator. On many accelerator cards, on-board current and voltage sensors can be read through the vendor's management tools. An external power meter at the card's supply or at the wall gives a system-level figure. Consider the power of the entire system, including the host, memory subsystem and cooling, and compare against competing solutions using the same boundary.

For machine learning, MLCommons publishes a power measurement method alongside its MLPerf benchmarks. The MLPerf Power paper (arXiv 2410.12032) describes how it covers systems from microwatt devices to data center clusters, and the MLCommons power-dev repository holds the measurement tooling.

Worked example: performance per watt

The numbers below are illustrative, for an image-classification workload.

PlatformThroughput (images/s)Average power (W)Images per jouleEnergy per image (mJ)
CPU baseline4001203.3300
FPGA accelerator2,000405020

Speedup is 2,000 / 400 = 5. Energy efficiency is 2,000 / 40 = 50 images per joule for the FPGA against 400 / 120, about 3.3, for the CPU, a 15 times improvement. If the FPGA figure covered only the card but the CPU figure covered the whole server, the comparison would be unfair, which is why the boundary must be stated.

Accuracy metrics

  • Error rate is the percentage of incorrect results compared with a reference solution, expressed as a percentage (%). For classifiers, top-1 and top-5 accuracy are the usual forms.
  • Mean squared error (MSE) is the average of the squared differences between the accelerator's results and a reference. It is in the squared units of the output, and becomes dimensionless only if the data are normalized.
  • Mean absolute error (MAE) is the average of the absolute differences between the accelerator's results and a reference, in the same units as the output.
  • Root mean squared error (RMSE) is the square root of the MSE, again in the same units as the output.
  • Peak signal-to-noise ratio (PSNR) compares the maximum possible signal value with the error between the accelerator's results and a reference, expressed in decibels (dB). It is calculated as 10 log10(MAX2 / MSE).

Use high-quality reference solutions, such as a double-precision software model or the original framework model. Higher accuracy may need wider data paths, more DSP blocks and more memory bandwidth.

Worked example: PSNR for an 8-bit image filter

Suppose a fixed-point FPGA filter produces 8-bit output pixels (MAX = 255) and the MSE against a floating-point reference is 4.0. PSNR = 10 log10(2552 / 4) = 10 log10(16,256), which is about 42.1 dB. RMSE is 2.0 gray levels. Halving the MSE to 2.0 would add 10 log10(2), about 3 dB. These numbers are illustrative.

Common mistakes

  • Quoting kernel-only time while ignoring data transfer to and from the card.
  • Comparing against an unoptimized CPU or GPU baseline.
  • Using tool power estimates as if they were measurements.
  • Reporting peak throughput with large batches alongside latency measured at batch size one, as if both held at once.
  • Changing precision on the FPGA without reporting the accuracy impact.

FAQ

Are there standard benchmarks for accelerators?

For machine learning, MLCommons publishes the MLPerf suites, which define workloads, accuracy targets and run rules, and include a power measurement methodology. For other domains, teams usually define an application-level benchmark of their own and publish its rules.

Should I report OPS/W or energy per operation?

Either, since one is the inverse of the other. Energy per operation is often easier to read and to add up across a pipeline.

How long should a power measurement run?

Long enough to cover several complete passes of the workload at steady temperature, so that start-up spikes and thermal drift do not dominate the average.

Further reading

Murugavel Ganesan
About the Author
Murugavel Ganesan
Product Director | SerDes · IVN · Edge AI · Compute | Ex Intel · Infineon

A semiconductor product leader working across product architecture, definition, strategy, and silicon and software execution, from concept through volume production. He has worked with teams across Asia, Europe and the USA, including at Intel, Infineon and ArrayComm.

His work covers ASICs, SoCs, FPGAs and chiplets for wireless, wireline, automotive, IoT and AI, including PCIe, CXL and DDR interfaces alongside RF and mixed-signal design.

Share Facebook X LinkedIn WhatsApp Email

Post a Comment

1 Comments

Your comments will be moderated before it appears here.

Post a Comment

#buttons=(Ok, Go it!) #days=(20)

Our website uses cookies to enhance your experience. Learn more
Ok, Go it!