
- •Contents
- •Introduction
- •About These Application Notes
- •What Is a Cell?
- •Cell Interconnect Delays
- •What Is Delay Back Annotation?
- •What Is Delay Calculation?
- •Prerequisites and Related Reading
- •Creating a Back Annotator
- •The Programming Language Interface (PLI) Mechanism
- •PLI Access Routines
- •Access Routine Families
- •Required UTILITY Routines
- •Access to Timing Information
- •Effect of Source Protection
- •Where to Look for More Information
- •Back Annotating Delays
- •Examples Used in This Chapter
- •Retrieving a Handle to the Object Associated with the Delay
- •Retrieving a Handle to a Net
- •Retrieving a Handle to a Module Path Delay
- •Retrieving a Handle to a Timing Check
- •Annotating the Delay
- •Determining How and Where to Place Delays
- •Annotating to Cells with Path Delays
- •Annotating to Cells with Lumped or Distributed Delays
- •Libraries with Mixed Cell Timing Descriptions
- •Annotating to Timing Checks
- •Calculating Delays
- •Examples Used in This Chapter
- •Scanning Cell Instances Within the Design
- •Determining the Scope of the Delay Calculation
- •Scan Methodology
- •Scanning Objects Within the Cell Instance
- •Relationship to Modeling Methodology
- •Scanning Path Delays
- •Scanning Cell Output Ports
- •Libraries with Mixed Cell Timing Descriptions
- •Types of Data Needed
- •Coding Data into Cell Descriptions (Attributes)
- •Retrieving Cell I/O Load Factors
- •Load Due to Interconnect Wire
- •Calculating and Annotating the Delays
- •Calculating the Delays
- •Annotating the Delays
- •Example Listings
- •Delay Back Annotators
- •Cell Output Nets to Lumped or Distributed Delay Cells
- •Interconnect Nets to Lumped or Distributed Delay Cells
- •Cell Output Nets to Path Delay Cells
- •Interconnect Nets to Path Delay Cells
- •Delay Calculators
- •Creating and Extracting Data From a Hash Table
- •Random Cell Scan and Cell Output Nets
- •Random Cell Scan and Cell Interconnect Nets
- •Delay Calculation Driven by Cell Output Nets
- •Delay Calculation Driven by a Cell Interconnect Nets
- •Index

Back Annotation and Delay Calculation
3
Back Annotating Delays
When you create a back annotation facility based on access routines, the delay back annotation file is usually produced by an external utility. Because the external utility does the actual calculation work, the algorithm that you use within the delay back annotation facility is usually straightforward. The following pseudocode illustrates the typical delay back annotation algorithm.
While there are more entries in the delay back annotation file
{
Read the current entry
Retrieve a handle to the object associated with the delay
Place the delay on the appropriate constructs in the data structure
}
Given this algorithm, it is clear that the main tasks associated with delay back annotation are as follows:
■retrieving a handle to the object associated with the delay
■determining where to place the delay
■annotating the delay
Examples Used in This Chapter
The delay back annotation file typically contains pairs of design object identifiers and the delays associated with these objects. The types of objects identified in the file depend on several factors, including the following:
■the cell library modeling methodology used
■the constraints of the external utility that creates the file
■the Verilog HDL construct with which you associate the delay
The objects most commonly identified in delay back annotation files are defined as follows:
■path delays—Verilog HDL module path delays
October 2000 |
20 |
Product Version 3.2 |

Back Annotation and Delay Calculation
Back Annotating Delays
■timing checks—Verilog HDL timing checks
■cell output nets—nets within cells that feed cell output ports
■interconnect nets—nets (external to all cells) that connect one or more cell outputs with one or more cell inputs
Figure 3-1 on page 22 shows two cells described in the Verilog HDL with lumped (primitive output) delay timing. Figure 3-2 on page 23 shows the same cells described with path delay timing. Note that the object dff in these descriptions is a user-defined primitive (UDP).
Figure 3-3 on page 24 shows a simple circuit description that uses these two cells, as well as a top -level module that contains an instance of the circuit module. Note that the circuit and toplevel modules are the same no matter which cell pair is used. Finally, Figure 3-4 on page 25 through Figure 3-6 on page 26 show several example delay back annotation files corresponding to these descriptions.
These files are explained and used in the examples in the remainder of this chapter. These files are not meant to define a standard Veritool delay back annotation format — there is no standard format. They are provided to help demonstrate the use of access routines in performing delay back annotation.
October 2000 |
21 |
Product Version 3.2 |

Back Annotation and Delay Calculation
Back Annotating Delays
Figure 3-1 Cells described in the Verilog HDL with lumped (primitive output) delays
// D flip-flop lumped delay timing model ‘celldefine
module dflop(q,qb,clk,d); input clk, d;
output q, qb;
dff g1(qi,clk,d); buf #102 g2(q,qi);
not #156 g3(qb,qi);
Lumped (primitive endmodule output) delay
‘endcelldefine
// 2x1 multiplexer lumped delay timing model ‘celldefine
module mux21(y,i1,i2,sel); input i1, i2, sel;
output y;
bufif0 #56 g1(y,i1,sel); bufif1 #72 g2(y,i2,sel);
endmodule ‘endcelldefine
October 2000 |
22 |
Product Version 3.2 |

Back Annotation and Delay Calculation
Back Annotating Delays
Figure 3-2 Cells described in the Verilog HDL with path delays and timing checks
// D flip-flop lumped delay timing model ‘celldefine
module dflop(q,qb,clk,d); input clk, d;
output q, qb;
dff g1(q,clk,d); not g2(qb,q);
specify
// path delays*** (clk *> q) = 102; (clk *> qb) = 156;
Path delays
// timing checks $setup(d,edge[01,x1] clk,9); $hold(posedge clk,d,6);
endspecify endmodule ‘endcelldefine
/ 2x1 multiplexer lumped delay timing model ‘celldefine
module mux21(y,i1,i2,sel); input i1, i2, sel;
output y;
Timing checks
bufif0 g1(yi,i1,sel); bufif1 g2(yi,i2,sel); buf g3(y,yi);
specify
// path delays
(sel *> y) = 72;
Path Delay
(i1,i2 *> y) = 56; endspecify
endmodule ‘endcelldefine
October 2000 |
23 |
Product Version 3.2 |

Back Annotation and Delay Calculation
Back Annotating Delays
Figure 3-3 Circuit and top-level modules that contain instances of the cells described in Figure 3-1 on page 22 and Figure 3-2 on page 23
// Circuit module
module rmux221(q,qb,da,db,select,clk); input select, clk;
input [1:0] da, db; output [1:0] q, qb;
mux21 m1(dm1,da[0],db[0],select); mux21 m2(dm2,da[1],db[1],select); dflop m3(q[0],qb[0],clk,dm1); dflop m4(q[1],qb[1],clk,dm2);
endmodule
// Top-level module module top;
reg clk, select; reg [1:0] da, db; wire [1:0] q, qb;
rmux221 m1(q,qb,da,db,select,clk); endmodule
October 2000 |
24 |
Product Version 3.2 |

Back Annotation and Delay Calculation
Back Annotating Delays
Figure 3-4 Delay back annotation file with paths and timing checks and their associated delays
top.m1.m1 2 sel y 10 12 i1 y 10 12 0
top.m1.m2 2 sel y 10 12 i1 y 10 12 0
top.m1.m3 2 clk q 25 27 clk qb 30 35 2
366 d 0 clk 9 20
367 clk 13 d 0 17
top.m1.m4 2 clk q 25 27 clk qb 30 35 2
366 d 0 clk 9 20
367 clk 13 d 0 17
Paths and delays
Timing checks and limits
Figure 3-5 Delay back annotation file with cell output nets and their associated delays
top.m1.m1.y 10 12 top.m1.m2.y 10 12 top.m1.m3.q 25 27 top.m1.m3.qb 30 35 top.m1.m4.q 25 27 top.m1.m4.qb 30 35
October 2000 |
25 |
Product Version 3.2 |