Why two 125 MHz oscillators with ±25 ppm tolerance can fill an asynchronous FIFO
Two oscillators rated at 125 MHz can drive independent read and write clocks at different rates over time. Verify both the clock-domain crossing and the average read and write rates. A finite buffer can absorb a sustained rate difference only for a limited time.
Calculation assumptions
Assume two independent clocks with a nominal frequency of 125 MHz and an allowed deviation of ±25 ppm each under the conditions used for this budget. The write clock is 25 ppm high and the read clock is 25 ppm low. Both sides remain enabled and transfer one word of the same width per cycle, with no stalls, backpressure, or rate compensation. These values are hypothetical.
The write frequency is fw = 125,000,000 × (1 + 25 × 10⁻⁶) = 125,003,125 Hz. The read frequency is fr = 125,000,000 × (1 − 25 × 10⁻⁶) = 124,996,875 Hz. The FIFO gains fw − fr = 6,250 words per second. The 50 ppm difference uses the nominal frequency as the denominator. If you calculate the relative difference using the actual read frequency, state that denominator explicitly.
Time to exhaust the available headroom
In the continuous-rate model, the net increase is ΔN = (fw − fr) × t. If 1,000 words of upper headroom remain after accounting for starting occupancy and the engineering reserve, the ideal time to exhaust it is 1,000 / 6,250 = 0.16 s, or 160 ms. The unit is words, and the calculation uses available headroom rather than the nominal FIFO depth.
| Time | Net increase in the continuous model | Integer count with zero initial phase |
|---|---|---|
| 10ms | 62.5 words | 63 words |
| 80ms | 500 words | 500 words |
| 160ms | 1,000 words | 1,000 words |
The continuous model describes the rate of accumulation. Actual transfers accumulate in whole words. In the simplified model with zero initial phase and no event counted at t = 0, round fw × t and fr × t down separately and subtract the results. Initial phase affects counts over short windows. The 62.5-word result represents the continuous model.
Reproducing the calculation in Python
from fractions import Fraction
f0 = 125_000_000
fw = Fraction(f0) * (1 + Fraction(25, 1_000_000))
fr = Fraction(f0) * (1 - Fraction(25, 1_000_000))
delta = fw - fr
print(float(delta))
print(float(Fraction(1000) / delta))
for ms in (10, 80, 160):
t = Fraction(ms, 1000)
print(ms, (fw*t).__floor__() - (fr*t).__floor__())
This code checks the frequency and event-count arithmetic. Hardware verification requires separate checks for RTL behavior, pointer synchronization, metastability, and actual waveforms.
Separate checks for CDC safety and rate balance
The Asynchronous section of AMD UG949 distinguishes clock relationships based on whether the clocks have a fixed phase relationship. The Clock Domain Crossing section explains that asynchronous crossings require appropriate CDC circuitry. Even when two independent clocks have the same nominal frequency, verify the safety of ordinary synchronous sampling paths before using them.
A correctly designed clock-domain crossing still leaves any sustained difference in average rates. A larger finite FIFO buys time if the average write rate remains higher than the read rate. Address the mismatch using protocol-supported backpressure, enable scheduling, rate compensation, or the clock architecture. If the clocks share a reference, check their actual phase relationships and timing constraints before treating paths as synchronous.
Operating margin beyond the 160 ms example
A real budget includes initial occupancy, full and empty flag synchronization delays, response time, data bursts, and engineering reserve. The 160 ms result excludes these effects. If the write side is slower, check lower headroom and underflow. Budget phase jitter and long-term frequency error separately.
In the selection handoff, record both complete part numbers, the conditions for the frequency tolerance guarantees, data width, the average fraction of enabled cycles, usable upper and lower headroom, and flow control. For electrical interface checks, see Differential oscillator interfaces, termination, and common mode。
Manufacturer methodology · AMD UG949 · Asynchronous and Clock Domain Crossing. These chapters cover clock relationships and CDC requirements. The 125 MHz, ±25 ppm, and 1,000-word figures are assumptions for this calculation. MERLIN used AI to help prepare this guide. Hardware performance, product compatibility, and availability require separate confirmation.
