# What is the maximum run length in PCIe gen 3 serial stream? [closed]

PCIe gen 2 uses 8b/10b and the run length is 5. What is it for Gen 3? Thank you for help.

## closed as too broad by Bence Kaulics, Daniel Grillo, Sparky256, Voltage Spike, Dave Tweed♦Jul 23 '16 at 16:05

Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

• 128/130b encoding. Don't know what the run length is. – Tom Carpenter Jul 18 '16 at 23:36
• Yes! Thx. But what is the worst case run length? I suspect some sort of scrambling is also done on the data. – shparekh Jul 18 '16 at 23:43
• Scrambling is done, yes, using the polynomial $G(X) = X^{23} + X^{21} + X^{16} + X^8 + X^5 + X^2 + 1$. If you can find a copy of the PCIe Base Spec Rev 3.0, the scrambler is described on page 213 onwards. – Tom Carpenter Jul 18 '16 at 23:47
• This might also be useful reading. – Tom Carpenter Jul 18 '16 at 23:48

## 1 Answer

PCIe gen 3 uses 128b/130b line coding, so absolute worst case run length would be 129 bits (128 scrambled bits + half of the 2 bit sync header). This assumes that the scrambling PRBS and transmit data exactly coincide and cancel to zeros for the entire 128 bit data block, which is possible but extremely unlikely. Note that in contrast with 64b/66b, the 128b/130b line code does not use a self-synchronizing scrambler. The DC wander is statistically bounded (as opposed to absolutely bounded) due to the scrambling.