https://obrazki.elektroda.pl/10_1320307338.jpg
which edge will be considered for hold slack calculation ( positive edge or negative edge)?
Since we are launching the data and capturing in the same cycle, how is hold defined. will hold not depend half clock period in half cycle path?
https://obrazki.elektroda.pl/10_1320307338.jpg
which edge will be considered for hold slack calculation ( positive edge or negative edge)?
Since we are launching the data and capturing in the same cycle, how is hold defined. will hold not depend half clock period in half cycle path?
Hold check means, we've to verify that is the launched data is capturing at same edge( launched edge), and if the launched data is capturing at same edge then previously launched data will be corrupted, so we check for hold at launching edge and if it is violated then we have to try to fix that violation to prevent from capturing at same edge...so for half cycle paths also, hold check will be done at launch edge...hope it is clear for you..
Hold is time for which the input data has to be stable after the clock transition. since reg1 is launching the data at positive edge and reg2 is capturing at negative edge, reg2 can go into hold violation. so , shouldn't we consider the negative edge(capture edge) for hold check?
In this case we are capturing the data in the same cycle, but the data at the both the flops is not latched at the same time.
Hi Sharif,
Hold time should be less than the combi delay between the flops...Its not the other way round!!
@pradeep..
Hold check is done one edge prior to the capture edge.
Now if ur clock A has 10ns time period so its edges are 0 10 20 30 40
clock B also at 10ns but fall edge its sensitive edges are 5 15 25 35
So for data being launched at 10ns will have
setup check at 15ns
hold check at 5ns
For muti-cycle paths, the hold analysis can be done at one edge prior to capture edge or will moved to the edge corresponding to the launch edge...depending on the design flow.
cheers,
Since no one answered this last question, I will even if a few months late. YES, in a half cycle path your hold check will be affected by your period.
Here is how I like to think of it.
In the case of rising to falling on the same clock, data leaves flop1 at time 0 and must reach flop2 by the next falling edge which is half the clock period. This is the setup check.
Now, you need to make sure that the data doesn't change before it is flopped. This is the hold check.
You can think of this as checking hold at one edge prior as suggest by phoenixpavan, but hold also checks the next edge of the launching clock against the same capture edge. If the clocks are the same, both of these methods are the same and most STA tools will move the edges to the earliest alignment anyway.
Using his example, data launched at 10ns will be captured by the neg edge flop at 15ns. The next launch edge is at 20ns, so you need to check that the data launched at 20ns arrives after the original capture edge of 15ns. An STA tool will use the earliest alignment, which would be 10ns and 5ns just as he determined.
However, when you start using mixed frequencies it is apparent the two methods are not equivalent, and you must use the worst case.
For instance if your clock a is 2x your neg edge clock b.
So clock a has pos edges at 0 5 10 15 20 25 ...
and clock b has neg edges at 5 15 25 35 ...
The setup check by default uses one cycle of the capture clock, so capture will be at 15ns, and the worst case launch edge would be at 10ns giving you a 5ns period. This will be moved to the earliest alignment which is launch at 0ns capture at 5ns.
Now the hold check will be the next launch edge against the same capture edge, or 5ns and 5ns. This will not be reduced to 0 and 0 because 0 is not a valid capture time for the negative edge clock.
If you used phoenixpavan's methodology, you would still launch at 0ns, but now check hold one cycle earlier on the capture clock which would be -5ns. Moved to the first positive time alignment you would get launch at 10ns capture at 5ns, which is incorrect and allow massive hold violations to be missed.
Hi,
I am still not clear with all these explanations.
I have a few basic questions.
1) Assume both launch and capture clocks are in the same clock domain
Case1: Launch flop is rise edge triggered and capture flop is fall edge triggered
Assume clock period =5 ns
For setup: Launch is at 0 ns and capture is at 2.5 ns
For hold: The hold check is always done one cycle ahead of capture edge setup.In this case it would be 2.5-5=-2.5.which would not be possible.So the hold check is done with the next edge of setup which is at 5ns.So hold check happens between 2.5 ns and 5.0 ns.So in the timing report what would be the clock edge at the capture edge.
Case2: Launch flop is fall triggered and capture flop is rise triggered
Assume clock period =5 ns
For setup: launch at 2.5 ns , capture is done at 5 ns
For hold: launch at 2.5 ns , capture happens at 0ns
If can get some clarity on this, I guess I can figure out the other 2 cases in which launch and capture clocks are of different frequencies.
Can someone give the hold equation for half cycle path ? I have been asked this twice in interviews.
And I believe for setup, below equation is correct. If not then please correct me.
Tclk/2 >= Tc-q + Tcomb + Tsetup
I worked out on the hold equation for half cycle path. Is this correct ?
Tclk/2 + Tc-q + Tcomb >= Thold
A hold requirement is the amount of time the data must arrive before the clock on a given flop.
Your setup equation is correct except you are missing the vital capture delay.
setup margin = Clock period/2 - launch path - setup requirement + capture path
for hold, the launch and capture are just reversed.
hold margin = Clock period/2 + launch path - hold requirement - capture path
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?