0% found this document useful (0 votes)
167 views43 pages

A Real World Clock Generator Class For UVM

The document discusses a proposed class-based clock generator for UVM that addresses irregularities in clock signals during design verification. It describes the importance of accurate clock modeling by using a serializer-deserializer example and explaining how non-ideal clocks can affect simulation results. Various types of clock irregularities like jitter, wander, spread spectrum clocking are explained. The proposed generator uses a generic class-based architecture instead of separate modules for flexibility during verification of designs that require complex clock modeling.

Uploaded by

Sam Honey
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
167 views43 pages

A Real World Clock Generator Class For UVM

The document discusses a proposed class-based clock generator for UVM that addresses irregularities in clock signals during design verification. It describes the importance of accurate clock modeling by using a serializer-deserializer example and explaining how non-ideal clocks can affect simulation results. Various types of clock irregularities like jitter, wander, spread spectrum clocking are explained. The proposed generator uses a generic class-based architecture instead of separate modules for flexibility during verification of designs that require complex clock modeling.

Uploaded by

Sam Honey
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 43

A real-world clock generator

class for UVM


Rhitam Datta, Design Engineer
Ankit Somani, Design Lead

© Accellera Systems Initiative 1


Topics
• Introduction
• Importance of clocking signal in design verification: SerDes
Illustration
• Irregularities in clock
• Module based clock generator
• Proposed class based clock generator
• Generic architecture of class based clock generator
• Simulation results
• Summary
© Accellera Systems Initiative 2
Introduction
• A particular type of signal that toggles between a
high state and low state, typically used to manage
various operations in digital circuits.

• A typical example is a periodic square wave with 50%


duty cycle.
Time period

Frequency

© Accellera Systems Initiative 3


Introduction
• It can have duty cycle not equal to 50%.
High time

Low time

• It can have different rise time and fall time.

© Accellera Systems Initiative 4


Importance of clocking signal in design
verification: SerDes Illustration

parallel_data[7:0]

parallel_clk serial_data
Serializer
serial_clk

© Accellera Systems Initiative 5


Importance of clocking signal in design
verification: SerDes Illustration

parallel_data[7:0]

serial_data parallel_clk
DeSerializer

serial_clk

© Accellera Systems Initiative 6


Importance of clocking signal in design
verification: SerDes Illustration

Exhibits low pass


characteristics
and includes
noise

par_data par_data
Channel
clk Serializer DeSerializer clk

© Accellera Systems Initiative 7


Importance of clocking signal in design
verification: SerDes Illustration

par_data par_data

clk Serializer Channel DeSerializer clk


A B

© Accellera Systems Initiative 8


Importance of clocking signal in design
verification: SerDes Illustration
Exhibits low pass
characteristics and
includes noise

Channel
1 UI A B

Transmission of Lone 1 data stream over channel

© Accellera Systems Initiative 9


Importance of clocking signal in design
verification: SerDes Illustration
Exhibits low pass
characteristics and
includes noise
Analog waveform
of data

Channel
1 UI A B

Transmission of Lone 1 data stream over channel

© Accellera Systems Initiative 10


Importance of clocking signal in design
verification: SerDes Illustration
Exhibits low pass
characteristics and
includes noise

Channel
1 UI A B <1 UI

Transmission of Lone 1 data stream over channel

© Accellera Systems Initiative 11


Importance of clocking signal in design
verification: SerDes Illustration

parallel_data[7:0]

serial_data parallel_clk
DeSerializer

serial_clk

1 UI

Stimulus : Ideal datastream Ideal scenario simulation

© Accellera Systems Initiative 12


Importance of clocking signal in design
verification: SerDes Illustration

parallel_data[7:0]

serial_data parallel_clk
DeSerializer

serial_clk

<1 UI

Stimulus : Real datastream Real scenario simulation

© Accellera Systems Initiative 13


Importance of clocking signal in design
verification: SerDes Illustration

Ideal clock

Ideal Stimulus
1 UI
Non- Ideal clock

Non- Ideal Stimulus


<1UI

© Accellera Systems Initiative 14


Importance of clocking signal in design
verification: SerDes Illustration

Ideal clock

Non- Ideal clock

© Accellera Systems Initiative 15


Importance of clocking signal in design
verification: SerDes Illustration

Ideal clock

Non- Ideal clock

© Accellera Systems Initiative 16


Irregularities in clock
• Causes the deviation from the periodicity of a
periodic signal, often in relation to a reference signal.
• Sourced by crystal, electromagnetic interference ,
cross talk with other signals etc.
• May effect the time period or the phase of the clock.
• Can be classified in two categories,
– Unintentional deviations are always present.
– Intentional deviations are introduced to counter certain
undesired phenomenon as EMI.

© Accellera Systems Initiative 17


Irregularities in clock
• Crystal PPM error

The deviation from the nominal clock frequency,


expressed in terms of parts per million (PPM).

© Accellera Systems Initiative 18


Irregularities in clock
• Wander error

Slow noise components, frequency less than 10


Hz, often are considered as Wander.

{
𝑡 𝑜𝑏𝑠= 𝑡 0 ± 𝑤𝑎𝑛𝑑𝑒𝑟 _ 𝑎𝑚𝑜𝑢𝑛𝑡 ,∧𝑐𝑙𝑜𝑐𝑘 _ 𝑐𝑦𝑐𝑙𝑒 _ 𝑛𝑜=𝑚𝑛
𝑡 0 ,∧𝑒𝑙𝑠𝑒

© Accellera Systems Initiative 19


Irregularities in clock
• High probability jitter (HPJ)

Consists of various components such as duty cycle


distortion, data dependent jitter, periodic jitter etc.

Generated by passing PRBS data pattern


through a low pass filter.

© Accellera Systems Initiative 20


Irregularities in clock
• Tonal jitter

Comprised of a single fundamental frequency and


prominent in the context of jitter tolerance test of RX.

© Accellera Systems Initiative 21


Irregularities in clock
• Gaussian jitter

Caused by silicon imperfection, certain types of cross talk,


thermal vibration etc., can be bounded or unbounded.

where τ = x-µ

© Accellera Systems Initiative 22


Irregularities in clock
• Gaussian jitter

Caused by silicon imperfection, certain types of cross talk,


thermal vibration etc., can be bounded or unbounded.

{
2
𝜏
1 −
2𝜎
2

𝐶𝐵𝐺𝐽 ( 𝑥 ) = 𝑒 ,∧¿ 𝜏 ∨¿ 𝜏 𝑚𝑎𝑥


𝜎 √2 𝜋
0 ,∧¿ 𝜏 ∨≥ 𝜏𝑚𝑎𝑥

© Accellera Systems Initiative 23


Irregularities in clock
• Spread spectrum clocking

Spectrum is spread around the center frequency of


clock, to counter effect of EMI.

© Accellera Systems Initiative 24


Module based clock generator
Interface

DUT
(Module)

Base Test

Clock Generator
(Module)

Test Bench UVM Test case


(Module)

© Accellera Systems Initiative 25


Module based clock generator
Interface

DUT
(Module)

Base Test

Clock Generator
(Module)

Adding clock
control signals
Test Bench UVM Test case
(Module)

© Accellera Systems Initiative 26


Module based clock generator
Interface

DUT
(Module)

Base Test

Clock Generator
(Module)

Adding clock
control signals
Test Bench UVM Test case
(Module)

© Accellera Systems Initiative 27


Module based clock generator
Interface

DUT
(Module)

Base Test

Clock Generator
(Module)

Adding clock
control signals
Test Bench UVM Test case
(Module)

© Accellera Systems Initiative 28


Module based clock generator
Interface

DUT
(Module)

Base Test

Clock Generator
(Module)

Adding clock
control signals
Test Bench UVM Test case
(Module) Interface
becoming
bulkier!

© Accellera Systems Initiative 29


Proposed Class based clock generator

Interface

Base Test
DUT
(Module) Clock Generator
(Class)

Interface size
reduced!
Test Bench UVM Test case
(Module) Clock control
signals not
required!

© Accellera Systems Initiative 30


Generic architecture of class based
clock generator
class clock_gen ();
// Contents of the class clock gen
endclass : clock_gen
class uvm_base_test extends uvm_test ;
/// Other declarations
clock_gen clk_gen_h ;
function void build_phase (uvm_phase phase) ;
// Other functionalities
clk_gen_h.build () ;
endfunction : build_phase
task run_phase (uvm_phase phase);
// Other tasks
clk_gen_h.configure () ;
clk_gen_h.run () ;
endtask : run_phase
endclass : uvm_base_test

© Accellera Systems Initiative 31


Simulation results
• Crystal PPM error

© Accellera Systems Initiative 32


Simulation results
• Crystal PPM error

© Accellera Systems Initiative 33


Simulation results
• Crystal PPM error

© Accellera Systems Initiative 34


Simulation results
• Wander error

© Accellera Systems Initiative 35


Simulation results
• Wander error

© Accellera Systems Initiative 36


Simulation results
• Wander error

© Accellera Systems Initiative 37


Simulation results
• High probability jitter

• Tonal jitter

© Accellera Systems Initiative 38


Simulation results
• Gaussian jitter

© Accellera Systems Initiative 39


Simulation results
• Spread spectrum clocking

© Accellera Systems Initiative 40


Simulation results
• Frequency configurability

• Duty cycle configurability

© Accellera Systems Initiative 41


Summary
• Clocking signals plays important role in verification.
• In test bench clocks can be generated by module
based clock generator or class based clock generator.
• In the proposed method, class based clock generator
is instantiated inside the base test of UVM.
• This gives direct control over clock generator.
• Interface becomes lighter as no clock control signals
are required.
• Class based clock generator is configurable and can
inject non-idealities in clock signals.
© Accellera Systems Initiative 42
Questions ?

© Accellera Systems Initiative 43

You might also like