하드웨어 설계/Design Compiler User Guide

Chapter 7 Defining Design Constraints - Part 2

가카리 2012. 8. 31. 15:26
반응형

Design Compiler User guide 챕터 7 두번째 파트 입니다.

 

분량이 많아서 포스트 2개로 나눴습니다.

 

Propagating Constraints in Hierarchical Designs

hierarchical designs subdesigns을 가지고 있는데 이 경우에 constraint up 또는 down으로 전달할 수 있다.

 

1) Characterizing

특정한 셀 인스턴스의 contraints를 캡쳐하고 디자인에 셀이 연결된 정보를 할당한다.

 

2) Modeling

chararterized된 디자인을 library cell로 만든다.

 

3) Propagating constraints up the hierarchy

clocks, timing exceptions, 그리고 disabled timing arcs를 낮은(높은) 레벨의 subdesign에 전달한다.

 

Characterizing Subdesigns

만약 subdesign을 각각 컴파일 한다면 boundary 조건들, 예를들어 input drive strength, input signal delays(arrival times), 그리고 output loads는 부모 design으로 유도되서 subdesign set된다. 이것을 다음과 같은 방법으로 할 수 있다.

 

Manually

 

set_drive, set_driving_cell, set_input_delay, set_output_delay, set_load 명령어를 쓴다.

 

Automatically

 

characterize 명령어를 쓰거나 design budgeting tool을 쓴다.

 

Using the characterize Command

 

RTL 코드를 bottom up 방식으로 합성할 때 characterize가 필요하다.

 

1) lower module을 주어진 constraint를 사용해서 합성한다.

2) lower module netlist를 읽어서 constraint top module에 적용시키고 저장한다.

3) 다시 재합성하는대 이때 lower module의 넷리스트와 constraint가 적용된 top module을 합성한다.

 

-no_timing 옵션을 주지 않는다면 characterize 명령어는 다음의 명령어들에 의해서 timing characteristic을 주게 된다.

characterize 명령어는 주요 목적은 subdesign timing 정보를 캡쳐하는 것이다.

 

아니면 subdesign parent의 정보로 유도해서 쓰는 것도 있다.(이 경우 parent가 이미 constraint가 정의되어 있어야하며 이것으로부터 subdesign constraint를 유도하는 것이다.)

-constraint 옵션을 주게 되면 characterize명령어는 area, power connection class, design rule constraint에 관한 것을 주게 된다.

 

-connection 옵션을 주면 connection 속성을 주게된다.

-power 옵션을 주면 subdesigns switching activity information, toggle rates, static probability 를 주게된다.

Removing Previous Annotations

 

대부분의 경우에 design characterizing을 하는 것은 이전의 characterzation 한 것과 연관된 정보들을 제거하게 된다. 그러나 back-annotation(set_load, set_resistance,read_timing, set_annotated_delay, set_annotated_check) characterize 스탭은 annotation은 제거하지만 기존의 back-annotation overwrite 할 수는 없다. 이 경우 다시 characterize 명령어를 쓰기 전에 subdesign annotation을 지우겠다고 명시를 해줘야한다.(using reset_design)

 

Optimizing Bottom Up Versus Optimizing Top Down

 

최적화 할 때 너는 characterize 명령어를 hierarchy maintain하기 위해 set_dont_touch명령어와 함께 쓸 수 있다.

bottom-up 최적화때는 maually하게는 uniquify명령어로 자동적으로는 compile 명령어로 characterize를 하지만 top-down때는 자동적으로 characterization이 수행된다.

 

Deriving the Boundary Conditions

characterize 명령어는 자동적으로 boundary 조건을 부모 design의 내용을 기초로해서 subdesign의 조건을 유도한다.

다음은 boundary조건을 유도하는 방법이다.

 

Timing conditions

input port의 예상되는 signal delay로 계산

 

Constraints

부모 design으로부터 maximum delay 값 등을 유도함..

 

Connection relations

포트와 포트 사이의 논리적 관계나 포트와 power또는 ground 사이의 관계, 예를 들어 항상 logic 0, 논리적으로 다른 포트와 반대 값, 또는 unconnected

 

characterize 명령어는 한 subdesign의 인스턴스를 위해 boundary 조건을 요약한다. 결과는 reference에 적용된다.

Limitations of the characterize Command

 

characterize 명령어를 쓸 때 다음의 제한사항을 고려해야한다.

 

1) subdesign parent design에서 timing budgets은 유도하지 않는다.

 

timing budgets이란 칩레벨이건 보드레벨이건 동기적으로 정상 작동하기위해 voltage level의 얼마나 많은 차이까지 커버 할 수 있는지에 관한 것.(how much margin)

 

2) hierarchical boundary clock_skew max_time_borrow속성은 무시한다.

 

옵션이 없으면 characterize 명령어는 subdesign의 포트 signal 정보(clocks, port drive, input and output delays, maximum and minimum path delays, port load) 를 부모 design에서 유도된 값으로 바꾼다.

 

Saving Attributes and Constraints

 

characterize 명령어는 subdesign timing environment 캡쳐한다. write_script명령어를 쓰면 현재디자인의 속성과 constraints를 저장할 수 있다. 그래서 > 연산자로 파일에 저장을 할 수 있다.

 

characterize Command Calculations

 

이번 섹션은 characterize 명령어가 포트에 구체적으로 어떻게 load timing value를 유도하는지 설명한다.

 

Load Calculations

 

 

 

 

1) hierarchical block B pin P outside load 계산법은

 

block A input에서 보면

 

driving net load 핀이 없으므로 그냥 TOP wire load 만 고려 그래서

0 + 1 * 5 = 5

 

block A output에서 바라볼 경우.

 

load pin on the net + load of segment c + load of segment d

= 1 (for load pin P) + 1 * 5 + + 1 * 2 = 8

 

block B output 경우

 

load pins on net + load of segment e

= 0 + 1 * 5 = 5

 

block B input pin X의 경우(Segment d)

 

load pins on net + load of segment b + load of segment c

= 0 + 1 * 2 + 1 * 5 = 7

 

block B input pin Y의 경우

 

pin loads on driving net + load of segment f

= 0 + 1 * 5 = 5

 

 

 

 

 

 

Input Delay Calculations

 

characterizing은 아웃풋 load의 정확한 정보를 제공하기 때문에 인풋 신호의 딜레이는 오직 이전단계의 gate driving 포트의 instrinsic delay만 고려한다. gate’s load delay connect delay는 고려하지않는다

 

 

 

 

 

input pin X에서의 딜레이는

drive strength at IN1 * (wire load + pin load) + intrinsic delay of A’s cell

= 3 * (5 + 2 + 1) + 1 = 25

윗그림에는 안나왔지만 전 그림으로 가보면 Load values on all input pins = 1 unit load로 되있음

 

 

Characterizing Subdesign Port Signal Interfaces

 

characterize 명령어를 쓸 때 옵션이 없으면 subdesign의 포트 signal 정보들(clocks, port drive, input and output delays, maximum and minimum path delays, and port load)을 부모 design에서 유도된 정보로 바꿀 수 있다.

 

또한 subdesign operating conditions timing ranges를 부모 design으로부터 물려받는다.

 

다음의 포트 signal 정보를 명령어를 사용해서 임의로 넣을 수 있다.

create_clock

set_clock_latency

set_clock_uncertainty

set_drive

set_driving_cell

set_input_delay

set_load

set_max_delay

set_min_delay

set_output_delay

set_propagated_clock

 

characterize 명령어를 사용할 때 다음은 wire loading model을 선택하는 방법이다.

 

1) top-level mode top이면 subdesign top-level wire loading model을 쓴다.

 

2) top-level mode enclosed 거나 segmented wire loading model은 다음에 기초하여 결정된다

   만약 wire loading model이 없고 wire load area의해서 결정되지 않으면 top-level design의 모델로 사용된다.

  만약 wire loading model이 없는데 wire laod area의해서 결정되면 컴파일 시간에 cell area에 의해서 다시 결정된다.

 

 

Combinational Design Example

 

script1 은 속성을 자동적으로 세팅한다.

script2 는 속성을 임의로 세팅한다.

 

 

 

 

 

 

current_design top

set_input_delay 0 A

set_max_delay 10 -to B

 

Script 1

current_design top

characterize U2

 

Script 2

current_design block1

set_driving_cell -lib_cell INV {C} //드라이빙 셀 정보

set_input_delay 3.3 C //n2 넷의 딜레이

set_load 1.3 D //load

set_max_delay 9.2 -to D //최대 딜레이 값

current_design top

 

Sequential Design Example

 

다음 그림은 sequential design top 안에 subdesign이 있는 경우이다.

 

Script 1 sets the information manually.

The input delay (from ff1/CP to u5/in1) is 1.8

The output delay (through u4 plus the setup time of ff2) is 1.2

The outside load on the out1 net is 0.85

Script 2 uses the characterize command to set the information automatically.

 

 

 

 

 

Script 1

current_design

top create_clock -period 10 -waveform {0 5} clock

current_design block

create_clock -name clock -period 10 -waveform {0 5} clock1

create_clock -name clock_bar -period 10 \ -waveform {5 10} clock2

set_input_delay -clock clock 1.8 in1

set_output_delay -clock clock 1.2 out1

set_driving_cell -lib_cell INV -input_transition_rise 1 in1

set_driving_cell -lib_cell CKINV clock1

set_driving_cell -lib_cell CKBUF clock2

set_load 0.85 out1

current_design top

 

Script 2

current_design top

create_clock -period 10 -waveform {0 5} clock

characterize u5

 

 

 

 

 

Characterizing Subdesign Constraints

 

characterize –constraints 명령어는 부모 design으로부터 값을 유도한다.

그래서 max_area, max_fanout, fanout_load, max_capacitance, max_transition subdesign에 적용시킨다.

 

Characterizing Subdesign Logical Port Connections

 

characterize –connections 명령어는 connection 속성을 부모 design으로 부터 유도해서 subdesign에 적용한다.

 

set_equal, set_oppsite, set_logic_one, set_logic_zero, set_unconnected 속성.

 

Example

 

 

 

 

 

Script 1은 속성을 manually하게 지정하는 것

 

Script 2 characterize –no_timing –conntections로 지정하는것. –no_timing timing 속성은 characterize 하지 않음.

 

Script 1

current_design block

set_opposite { E F }

set_logic_zero { G }

set_unconnected { J }

 

Script 2

current_design top

characterize U2 -no_timing -connections

 

Characterizing Multiple Instances

 

만약에 한 subdesign 인스턴스가 여러개 있다면 각각 차별적으로 characterize를 할 경우가 있다.

 

이때는 uniquify 명령어를 쓰면된다. 이 명령어를 쓰면 subdesign을 복사한다음에 각각 이름을 바꿔주게 된다. 그런다음 characterize를 하면 각각 따로 characterzie를 할 수 있다.

 

 

 

 

 

 

 

 

Characterizing Designs With Timing Exceptions

 

만약에 path design hierarachy를 가로질러서 가면서 다른 타이밍 예외를 가진다면, characterize 명령어는 timing constraints 가상의 clock가 함께 이러한 정보를 캡쳐한다.

 

timing 예외는 set_multicycle_path, set_false_path, set_max_delay 그리고 set_min_delay이다. 가상 clock 스키마는 또한 다중 clock으로 다뤄진다.

 

 

 

 

 

-verbose옵션은 subdesign characterize할때 관련된 명령어를 다 보여줌

 

위를 보면 ALARM이 인풋으로 들어가서 U3에는 2개의 cycle path가 있다.

 

이런 경우 characterize U0 –verbose 한 결과이다.

 

 

 

 

-이 부분 잘 모르겠음.

 

Methodology for Propagating Constraints Upward

 

propagate_constraints 명령어를 쓰면 낮은 레벨의 디자인에서 현재 디자인으로 constraints를 전달 할 수 있다. 만약 명령어를 안 쓰면 높은 레벨에서 current_instance constraints를 전달 할 수 있다. 그러나 낮은 레벨에서 높은 레벨로 전달할 수 없다.

 

만약 A가 높은 레벨이고 B가 낮은 레벨이면 B constraints A로 전달할때

 

 

만약 모든 전달된 constraints를 파일로 리포트를 하고싶다면 –verbose –dont_apply 옵션을 준다.

 

dc_shell> propagate_constraints -design name \ -verbose -dont_apply -output report.cons

 

Handling of Conflicts Between Designs

 

만약 다음과 낮은 레벨 디자인과 높은 레벨 디자인이 다음과 같은 충돌이 날 수도 있다.

 

Clock name confilct

 

    낮은 레벨 clock이 다른 블럭이나 current design clcok과 이름이 같으면 clock은 전달되지 않는다. 경고가 발생한다.

 

Clock source conflict

 

    낮은 레벨 블럭의 clock 소스가 이미 높은 레벨 블럭과 동일할 때 낮은 레벨 clock은 전달되지 않은다. 경고가 발생한다.

 

Exceptions from or to an unpropagated clock

 

    virtual clock 또는 clock이 충돌 때문에 전달되지 않을 때 발생 한다.

 

Exceptions

 

    낮은 레벨 예외가 만약 높은 레벨 예외와 같은 path를 쓰면 높은 레벨의 예외를 재정의한다.

 

 

 

반응형