Presentation is loading. Please wait.

Presentation is loading. Please wait.

VHDL과 디지털회로 설계 전남대학교 전자공학과 김 영 철.

Similar presentations


Presentation on theme: "VHDL과 디지털회로 설계 전남대학교 전자공학과 김 영 철."— Presentation transcript:

1 VHDL과 디지털회로 설계 전남대학교 전자공학과 김 영 철

2 목 차 Agenda ASIC Design VHDL 및 논리 합성 탄생 배경 VHDL 과 ASIC 설계 환경과의 관계
VHDL 모델링, 합성 및 FPGA 구현 예 VHDL 발전 추세 및 미래 전망

3 Agenda Mobile Society Change Design Methodology
PC -> Mobile Communication Component -> System Design Methodology ASIC Design Flow SoC Design Flow

4 Shift 1: From PC to Communications Centric
Services Broadband Network 100Mb/sWLAN RF 20Gop/s Java Configurable Multi-Standard Info Plug... <1 Watt WWW LAN MPEG 4-7 100 Gop/s 5 Gtr/s 10 Watt ?? -> Domain Specific Computing

5 Shift 2: Chip from Component -> System
Services embedded C Network IP asp RF System on opamp Filters AD/DA dspP IC ASIP memory µP µC gate RT-ops ASIC FSM FPGA Silicon Board VHDL OO cC++ Software Hardware Design Software t 1960 70 80 90 2000 2010

6 Mobile Society의 환경 변화 PC 시대의 시작 Internet 시대의 시작 Mobile Phone 시대의 시작
1980년을 전후로 하여 8-bit/64K Memory PC 시대의 시작 Internet 시대의 시작 PC 통신, (WS, PC), WWW 시대의 시작 Mobile Phone 시대의 시작 1995년 전후로 한 Analog Mobile Phone, Digital Phone 시대의 시작 3세대 IMT-2000 시대의 시작을 앞두고 있음 Post PC 시대의 시작 다양한 형태의 PDA를 중심으로 한 Post PC Network Information Appliance 시대를 위한 준비

7 Post-PC Silicon System in 2010
40nm , 1G+ Transistors www gps RF / Analog Embedded Software 100 MByte Distributed Memory 32 Bit ASPP’s Speech Pen Vision Bio Motion Security Sensors >1GHz Re-configurable Interconnect <1 Watt Display Sound Data Bio Actuators 10 M gate Re-configurable Computing 10 M Gate Hardwired Logic <1 Volt 50 GIPS-500GOPS FLEXIBILITY - REUSE - IP ENERGY/OP : 100 More than IP assembly!!

8 Key Enabling Technologies

9 Productivity Gap in Hardware Design
Source: sematech97 A growing gap between design complexity and design productivity

10 Increasing Designer Productivity
7 Areas A : Register-transfer level to layout B : Low power C : Libraries D : Analog/mixed-signal design E : Intellectual property reuse F : Hardware/software coverification G : System-level specification

11 ASIC Design –The Silicon Evolution

12 ASIC Design - Technology Diffusion

13 ASIC Design - Profit Loss
Source: McKinsey

14 ASIC Design-VLSI Crisis
feature size - decreases by a factor of 2 in every 4 years. chip size - increases 5 mm 1977, mm in 2000, mm in 2010 total transistor count rises by a factor of 2 in every 18 months. fabrication cost - doubles for each generation programmer productivity 30 lines/day ($20/line) ~ 0.5 lines/day designer productivity 30 transistors/day 30 HDL lines/day, 300 gates/day, 1200 transistors/day

15 ASIC Design-VLSI Crisis
HDL based design simulation logic synthesis behavioral synthesis Formal verification Equivalence verification of HDL based designs of different abstract levels. Intellectual Property vendor library synthesizable core

16 ASIC Design-Design Reuse
More than 100M gates in 40 nm 10 – 1M gates per synthesis module synthesis modules per chip behavioral synthesis 100M gates by the years 2010 Design Reuse constant project team sizes shrinking project completion times Large portions of the chip will result from reusing existing blocks.

17 ASIC Design-System Design
Building blocks image/video processing speech codec communications ASIC Design becomes a system integration system level analysis of available building blocks Balancing of available IP building blocks product differentiation at the system level

18 ASIC Design -Intellectual Property
IP Development / Integration House Diverse market needs e.g.> graphics chips with digital modem capability ASIC Design becomes a system integration performance analysis of availiable building blocks balancing of available building blocks Reusing IP Building Blocks only viable approach to designing over 1M gates reasonable time. Reusing IP building blocks developed outside is the way to merge knowledge from different applications onto a single chip

19 ASIC Design -Intellectual Property
On Silicon IP(hard IP) ASICs chip sets programmable DSPs Off Sillicon IP(soft IP) synthesizable core a reference implementation in sillicon adds a credibility Firm IP(soft IP) RTL level libraries

20 ASIC Design -Levels of Abstraction
Architectual /Algorithmic described in terms of the algorithms the system performs. High lebel design tradeoffs, e.g. hardware /software codesign. RTL flow of data and control signals whthin / between functional blocks. schedules assignments at clock edges. Gate interconnection of switching elements (gates). Switch describes logic behavior of transistor circuits. Evaluates conflicts caused by signal strengths of multiple nets.

21 Market Pressures Size of Custommer Telecom Market: < US$ 2T
Products: Signal-Dominated HW Systems Under SW Control Protable, Low-Power, Manufacturable, Time to Market Average Lifetime of a Consumer Product: 6-18 mos. Success Depends Critically on the Ability to Design these Systems FAST!

22 When Does One Use Behavioral Synthesis
Use behavioral synthesis when Algorithmic descripion exists Complex data flow and/or memory access Operations can be moved Designs specification still changing Need to explore architecture, pipelining, etc.

23 Behavioral Synthesis Looks at high-level constraints
CYC# OP 1 2 3 4 HARDWARE ALLOCATION SCHEDULING Looks at high-level constraints Latency, Throughput, Clockperiod goals Extracts control /data flow behavior (Scheduling) Assigns operations to resources and states Assigns variables to storage elements (Allocation) optimization of storage decides if temporary storage necessary FSM generated automatically defines state /state transitions cycle /cycle implementation of behavior

24 Behavioral Synthesis: Definition
input FOR I in 0 TO 2 LOOP WAIT until clk’event and clk = ‘1’; IF (rgb[i] < 248) THEN p = rgb[i] mod 8; q = filter(x,y)*8; END IF; …... m o m R input output clk Enable Instructions Operations Variables Arrays signals constraints Scheduling Allocation Loop pipelining Chaining Multi cycle operations Memory management Reset style Clocking sytyle Functional units Registers Memories Multiplexers DW components Collection of techniques for sequential optimization

25 설계 자동화(design automation)
▶ 컴퓨터 기술의 발달 - 처리 속도, 저장 용량, GUI의 성능 향상 ▶ 집적회로 설계 기술의 발달 - 설계 기술의 축적, 설계 도구의 발달 ▶ 설계자의 작업 및 결정을 대신하고 검증을 도와줌으로서 가능

26 HDL 설계와 컴퓨터 프로그래밍의 비교

27 합성(synthesis)이란 ? ▶ 합성은 HDL을 이용한 설계에서 가장 중요한 과정 ▶ 합성 = 변환 + 최적화
▶ 합성 = 변환 최적화 (translation) (optimization) ▶ 변환 : 동작적 또는 RTL 기술 (HDL 설계) 구조적 기술 (게이트 레벨 표현) ▶ 최적화 : 면적의 최소화, 동작의 고속화

28 2. VHDL 및 논리 합성 탄생 배경 ASIC 기술 논리 합성(설계 프로세스) VHDL 왜 VHDL 합성이 필요한가?

29 (Application Specific IC)
ASIC 기술(1) IC 제조 기술 발전 ASIC (Application Specific IC) 등장 설계 도구 성능 향상 -주문형( semi-custom ) 반도체 -소량 ( application specific ) -개발 기간 단축 ( shorter design turnaround time (DAT) )

30 ASIC 기술(2) full-custom IC semi-custom IC ASIC ASIP (co-design)
- gate density 증가 - 속도(성능) 향상 - 비용 절감 제조 공정에 필요한 mask pattern 을 줄임 full-custom IC semi-custom IC ASIC ASIP (co-design) - Gate Array - Standard Cell - PLA, PAL - FPGA(Field Programmable GA) - PLD(Programmable Logic Device)

31 논리 합성(logic synthesis)
schematic based design process language based design process circuit design with HDL(Hardware Description Language) circuit design with schematic editor logic synthesis simulation simulation

32 VHDL(Very High Speed IC HDL)
HDL workshop 새로운 HDL 개발 필요성 대두 - 미국방성, Department of Defense Requirements for HDL 문서 발간 VHDL version 7.2 탄생(미 국방성 기준) 차 VHDL 개발 시작( 일반화가 주목적) 1987. IEEE Standard VHDL 탄생 1993. VHDL VHDL 추가요건 반영

33 왜 VHDL 합성이 필요한가? circuit design with HDL logic synthesis simulation
언어로 기술할 경우 회로 복잡도에 상관없음. 회로가 점차 복잡해짐 circuit design with HDL 잦은 설계 변경 용이. 성능 평가 logic synthesis 초기 설계 단계에서 오류 검출 netlist 자동 추출. DAT 단축 simulation

34 VHDL합성의 장점  설계 사이클 단축 - 설계 오류 발생 가능성 감소  설계의 질(quality) 향상
- 전혀 다른 설계 방식들을 손쉽게 검색  vendor 및 제조 기술에 무관  설계 비용 절감 - 설계 재사용 ( design re-usability )  설계 관리 용이 - 프로그래밍 언어의 structured design 개념 도입  미연방 표준(IFIP 172) 과 일치

35 VHDL합성의 단점  문화적 변화 - 언어에 입각한 설계 프로세스  설계 오류 발견 및 수정
- 디지털 회로 설계가 주 목적  설계 오류 발견 및 수정 - 논리 합성 결과, 자동 생성된 회로 도면을 이해하기 어렵다. - 전달 지연 시간 ( propagation delay ) 분석이 어렵다.

36 VHDL합성의 실체  VHDL 로 기술(記述)만 하면, 합성 도구가 스스로 논리 회로를 완벽하게 설계해 준다(?)
예. A = B x C  VHDL 은 프로그래밍 언어가 아니다.  H/W 설계 경험이 결정적 영향을 미친다.  합성 도구 성능에 크게 좌우된다.

37 2. VHDL 과 ASIC 설계환경과의 관계 합성 가능한 함수 및 기본 합성 원칙
설계 계층 구조(design hierarchy) ASIC 설계 프로세스 VHDL 합성 방식에서 유의할 점

38 합성 가능한 함수  조합형 논리 함수  순차 논리 함수
- primitive logic gates, decoder, multiplexer - adder, subtractor , comparator, multiplier 등  순차 논리 함수  카운터 및 카운터를 사용한 함수 - up/down counter, timing generator, event counter 등  레지스터와 래치 함수 - register, latch, shift register, accumulator 등  제어 논리 회로 - sequencer, controller, finite state machine 등

39 기본 합성 원칙  VHDL 로 기술하였다고 해서 무조건 합성되지는 않는다.
 자신이 원하는 바를 직접 VHDL 로 coding 한다.  합성 프로세스는 시간 지연(timing delay) 요건을 무조건 만족시키지는 못한다.

40 abstract design 설계 계층 구조 detailed design

41 ASIC 설계 프로세스

42 ASIC 설계 프로세스(1)  시스템 개발 계획 및 기능 분할  블록 다이어그램 및 개발 specification 결정
- 알고리즘 장  단점 분석 - 전체 설계를 H/W 및 S/W 부분 설계로 나눔 - 하위 레벨 module 의 기능 정의  블록 다이어그램 및 개발 specification 결정 - 구체적인 H/W 함수로 분할 - VHDL 코드 기술 ( 記述 ) 을 위한 기반 ( 基盤 ) - gate count 추정 등 시스템 평가 항목 고려

43 예: 상위 레벨 block diagram

44 예: 신호 발생기 “A”의 block diagram

45 ASIC 설계 프로세스(2)  테스트 및 시뮬레이션 계획  논리 회로 설계
- controllability 및 observability 개선  수율(yield) 향상 - 테스트 입력 생성 방법 (예: 24-bit counter, )  논리 회로 설계 - 공용 (共用) 함수 확인  매크로 ( macro ) 로 설계 - 각 함수 및 블록 별로 VHDL 코드 및 시뮬레이션 테스트 패턴 생성

46 논리 회로 설계 흐름 비교

47 ASIC 설계 프로세스(3)  시뮬레이션 ( simulation )  논리 합성
- 원시 VHDL 코드 compile 및 link  debugging - 부분/전체 시뮬레이션 여부 결정 ( 예 : half-adder 와 AND gate )  논리 합성 - ASIC 제조 업체 결정( 해당 component 라이브러리 사용 ) - 성능 최적화 및 논리 최적화  ASIC 검증(檢證, verification) - physical layout 결과 gate 전달 지연 시간 영향 분석 - I/O pin assignment, ERC ( Electrical Rule Checking )

48 VHDL 합성에서 유의할 점  VHDL 로 coding 하기 전에 해당 블록 다이어그램의
logical structure 가 어떤 모양인지 알고 있어야만 한다.  VHDL 설계와 최종 gate-level ASIC 설계가 일치함을 확인하기 위해 동일한 테스트 패턴(test pattern)을 입력으로 사용한다.

49 3. VHDL 모델링, 합성 및 FPGA 구현 예 합성을 위한 VHDL 모델링 VHDL 모델링의 시뮬레이션 및 논리 합성 예
성능 최적화 및 면적 최소화 사례

50 합성을 위한 VHDL 모델링  추상적 동작 레벨 모델링  레지스터 전송(Register Transfer) 레벨 모델링
(Behavioral Descriptions)  레지스터 전송(Register Transfer) 레벨 모델링 (데이터 흐름 (Dataflow Descriptions) 모델링)  구조적 레벨 모델링 (Structural Descriptions)

51 (Behavioral Descriptions)
추상적 동작 레벨 모델링 (Behavioral Descriptions) architecture behavioral of eqcomp4 is begin comp : process (a, b ) if a = b then equals <= ‘1’ ; else equals <= ‘0’ ; end if ; end process comp; end behavioral ;

52 레지스터 전송(RT) 레벨 모델링 (Data-flow Descriptions)
architecture dataflow of eqcomp4 is begin equals <= ‘1’ when (a = b) else ‘0’; -- equals is active high end dataflow ;

53 (Structural Descriptions)
구조적 레벨 모델링 (Structural Descriptions) architecture structural of eqcomp4 is signal x : std_logic_vector (0 to 3); begin u0 : xnor2 port map (a(0), b(0), x(0)); u1 : xnor2 port map (a(1), b(1), x(1)); u2 : xnor2 port map (a(2), b(2), x(2)); u3 : xnor2 port map (a(3), b(3), x(3)); u4 : and4 port map (x(0), x(1), x(2), x(3), equals); end structural ;

54 전가산기 VHDL 모델링 예  1-bit half-adder(HA) VHDL 모델링
- Data-flow Descriptions - Behavioral Descriptions  1-bit full-adder(FA) VHDL 모델링 - Structural Descriptions(2 HA + OR gate)

55 half adder (1): entity 선언부
entity half_adder is port ( a, b : in bit ; sum, carry : out bit ); end half_adder ; a sum half adder carry b

56 예제 1 : half adder(2)(architecture body)
(Register Transfer Level Modeling) architecture RTL_description of half_adder is begin process begin sum <= a xor b ; carry <= a and b ; wait on a, b ; end process ; end RTL_description ;

57 예제 2 : half adder(3) (architecture body) (Behavioral Modeling)
architecture behav_description of half_adder is begin process begin if (a = b) then sum <= '0' ; else sum <= '1' ; end if ; if (a = '0') or (b = '0') then carry <= '0' ; else carry <= '1' ; wait on a, b ; end process ; end behav_description ;

58 (논리식, 최장 전달 지연 경로, 디바이스 활용률)
예제 1 및 예제 2의 VHDL 합성 결과 (논리식, 최장 전달 지연 경로, 디바이스 활용률) Design Equations carry = a * b sum = a * /b + /a * b Worst Case Path tPD = 8.5 ns for the path (a  sum, a  carry ) Utilization (using Package CY7C JC) Total PIN signals 4/38 Macro-cells Used 2/32 Unique Product Terms 3/160

59 시뮬레이션 결과(half adder) 전달지연시간 (propagation delay)

60 full adder(1) : entity 선언부
entity full_adder is port ( x, y, c_in : in bit ; s_out, c_out : out bit ) ; end full_adder ; x s_out y full adder c_out c_in

61 full adder(2): architecture body
architecture structure of full_adder is signal temp_sum, temp_carry_1, temp_carry_2 : bit ; component half_adder port ( a, b : in bit ; sum, carry : out bit ) ; end component ; component or2 port ( i1, i2 : in bit ; o : out bit ) ; begin port map ( … ); ... end structure ;

62 full adder(3): block diagram

63 full adder(4): structural descriptions
u0 : half_adder port map ( a => x, b => y, sum => temp_sum, carry => temp_carry_1); u1 : half_adder port map ( a => temp_sum, b => c_in, sum => s_out, carry => temp_carry_2 ); u2 : or2 port map ( i1 => temp_carry_1, i2 => temp_carry_2, o => c_out ); x a sum temp_sum U0 y carry Temp_carry_1 b

64 full adder(5): 논리 합성 결과

65 full adder(6) : Behavioral Modeling
architecture behav_description of full_adder is begin process variable I : integer ; if (x = ‘1’) then I <= I + 1 ; end if; if (y = ‘1’) then I <= I + 1 ; end if; if (c_in = ‘1’) then I <= I + 1 ; end if; if (I = ‘1’) or (I = ‘3’) then s_out <= ‘1’ ; else s_out <= ‘0’; end if; if (I > ‘1’) then c_out <= ‘1’ ; else c_out <= ‘0’; end if; wait on x, y, c_in ; end process ; end behav_description ;

66 full adder(7): 논리 합성 결과

67 VHDL 모델링의 FPGA 구현  Standard Cell  Gate Arrays
- 창고형 할인 매장과 같은 구조  Gate Arrays - metal layer 를 제외한 다른 제조 공정은 완료  PLD(Programmable Logic Devices) - 2-stage arrays : AND plane + OR plane - PROM(Programmable ROM), PLA, PAL  FPGA(Field Programmable Gate Arrays) - PLD 를 확장 시킨 형태

68 FPGA logic cell

69 시뮬레이션 프로그램 ( VHDL 시뮬레이터 )
모델링 디바이스 선택 합 성 요 건 합성 프로그램 netlist 또는 부울 방정식 배치 및 배선 프로그램 결과 파일 (타이밍 분석 내용 등) 레이아웃 직후 시뮬레이션 모델 (VHDL 또는 다른 포맷) 테스트 벤치 디바이스 프로그래밍 파일 (JEDEC 포맷) 시뮬레이션 프로그램 ( VHDL 시뮬레이터 ) 그래픽 파형 데이터 파일

70 Device 선택

71 VHDL 합성 과정(compilation)

72 CPLD 구현 예(1)

73 CPLD 구현 예(2) - 앞 그림을 축소

74 경로별 timing 분석 결과

75 자원 활용 분석 결과

76 임계 경로(critical path)지연 시간 
성능 최적화 및 면적 최소화 비용 = 면적 gate density  area minimization 성능 = 속도 임계 경로(critical path)지연 시간  performance optimization 최소 개발 비용으로 최고 성능의 ASIC 칩 구현

77 예: 속도 개선 Sum <= BusA+BusB+BusC+BusD

78 예: 자원 공유(resource sharing)(1)
Y <= A + B When Sel = ‘1’ Else Y <= C + D Which one to choose?

79 예: 자원 공유(resource sharing)(2)
Y <= A + B When Sel = ‘1’ Else Y <= C + D 가. 두 개의 멀티플렉서와 한 개의 덧셈기 MPX1 <= A When Sel = ‘1’ Else C; MPX2 <= B When Sel = ‘1’ Else D; Y <= MPX1 + MPX2; 나. 두 개의 덧셈기와 한 개의 멀티플렉서 Sum1 <= A + B; Sum2 <= C + D; Y <= Sum1 When Sel = ‘1’ Else Sum2;

80 예: 논리 게이트 최소화(1)

81 예: 논리 게이트 최소화(2) C <= A or (B and not (Select)); 
Z <= A when Select = ‘0’ else C; Z <= A;

82 예: 속도 최적화(1) 임계 속도 (critical speed) 경로 최소화
예: 속도 최적화(1) 임계 속도 (critical speed) 경로 최소화 SigA <= ‘1’ When Count = ‘ ’ Else ‘0’;

83 예: 속도 최적화(2) And/Or 항으로 분리

84 예: 속도 최적화(3) A 에서 Z 까지의 전달 지연 최소화

85 속도 최적화 및 면적 최소화 시 유의할 점 RESULT <= A + B ;  다양한 설계 방식 시도
- design requirement에 따라 적절히 tradeoff  component library에서 미리 설계된 덧셈기를 선택 - 내부 구조 변경 불가 - technology dependent  carry lookahead 회로 첨가 (혹은 VHDL로 coding) - 면적은 최소 2.5  50% 증대

86 VHDL 발전 추세(1) 통합(integration) 도구 성능과 정확도 보다 정확한 물리적 설계 정보가 필요.
예: gate delay ASIC 제조 기술 변경 결과의 신속한 반영. 도구 성능과 정확도 합성 가능한 entity 수 제한 철폐. VHDL 원시 코드의 보다 정확한 합성 기술.

87 VHDL 발전 추세(2) 최상위 레벨 도구들 형식 검증( formal verification ) 데이터 경로 합성
DSP( Digital Signal Processing ) Application bus-style/pipelined processor register/register file synthesis


Download ppt "VHDL과 디지털회로 설계 전남대학교 전자공학과 김 영 철."

Similar presentations


Ads by Google