Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống
1
/ 325 trang
THÔNG TIN TÀI LIỆU
Thông tin cơ bản
Định dạng
Số trang
325
Dung lượng
15,97 MB
Nội dung
Electronics and Communication Engineering Introduction to VHDL ELCTRONICS AND COMMUNICATION ENGINEERING INTRODUCTION TO VHDL What is VHDL? VHDL is the VHSIC Hardware Description Language VHSIC is an abbreviation for Very High Speed Integrated Circuit It can describe the behavior and structure of electronic systems, but is particularly suited as a language to describe the structure and behavior of digital electronic hardware designs, such as ASICs and FPGAs as well as conventional digital circuits VHDL is a notation, and is precisely and completely defined by the Language Reference Manual (LRM) This sets VHDL apart from other hardware description languages, which are to some extent defined in an ad hoc way by the behavior of tools that use them VHDL is an international standard, regulated by the IEEE The definition of the language is non-proprietary VHDL is not an information model, a database schema, a simulator, a toolset or a methodology! However, a methodology and a toolset are essential for the effective use of VHDL Simulation and synthesis are the two main kinds of tools which operate on the VHDL language The Language Reference Manual does not define a simulator, but unambiguously defines what each simulator must with each part of the language VHDL does not constrain the user to one style of description VHDL allows designs to be described using any methodology - top down, bottom up or middle out! VHDL can be used to describe hardware at the gate level or in a more abstract way Successful high level design requires a language, a tool set and a suitable methodology VHDL is the language, you choose the tools, and the methodology well, I guess that's where Doulos come in to the equation! ECADLAB(VHDL) ELCTRONICS AND COMMUNICATION ENGINEERING A Brief History of VHDL The development of VHDL was initiated in 1981 by the United States Department of Defense to address the hardware life cycle crisis The cost of reprocuring electronic hardware as technologies became obsolete was reaching crisis point, because the function of the parts was not adequately documented, and the various components making up a system were individually verified using a wide range of different and incompatible simulation languages and tools The requirement was for a language with a wide range of descriptive capability that would work the same on any simulator and was independent of technology or design methodology Standardization The standardization process for VHDL was unique in that the participation and feedback from industry was sought at an early stage A baseline language (version 7.2) was published years before the standard so that tool development could begin in earnest in advance of the standard All rights to the language definition were given away by the DoD to the IEEE in order to encourage industry acceptance and investment ASIC Mandate DoD Mil Std 454 mandates the supply of a comprehensive VHDL description with every ASIC delivered to the DoD The best way to provide the required level of description is to use VHDL throughout the design process ECADLAB(VHDL) ELCTRONICS AND COMMUNICATION ENGINEERING VHDL '93 As an IEEE standard, VHDL must undergo a review process every years (or sooner) to ensure its ongoing relevance to the industry The first such revision was completed in September 1993, and tools conforming to VHDL '93 are now available Summary: History of VHDL 1981 - Initiated by US DoD to address hardware life-cycle crisis 1983-85 - Development of baseline language by Intermetrics, IBM and TI 1986 - All rights transferred to IEEE 1987 - Publication of IEEE Standard 1987 - Mil Std 454 requires comprehensive VHDL descriptions to be delivered with ASICs 1994 - Revised standard (named VHDL 1076-1993) ECADLAB(VHDL) ELCTRONICS AND COMMUNICATION ENGINEERING Levels of Abstraction VHDL can be used to describe electronic hardware at many different levels of abstraction When considering the application of VHDL to FPGA/ASIC design, it is helpful to identify and understand the three levels of abstraction shown opposite algorithm, register transfer level (RTL), and gate level Algorithms are unsynthesizable, RTL is the input to synthesis, gate level is the output from synthesis The difference between these levels of abstraction can be understood in terms of timing Levels of abstraction in the context of their time domain Algorithm A pure algorithm consists of a set of instructions that are executed in sequence to perform some task A pure algorithm has neither a clock nor detailed delays Some aspects of timing can be inferred from the partial ordering of operations within the algorithm Some synthesis tools (behavioral synthesis) are available that can take algorithmic VHDL code as input However, even in the case of such tools, the VHDL input may have to be constrained in some artificial way, perhaps through the presence of an ‘algorithm' clock - operations in the VHDL code can then be synchronized to this clock ECADLAB(VHDL) ELCTRONICS AND COMMUNICATION ENGINEERING RTL An RTL description has an explicit clock All operations are scheduled to occur in specific clock cycles, but there are no detailed delays below the cycle level Commercially available synthesis tools allow some freedom in this respect A single global clock is not required but may be preferred In addition, retiming is a feature that allows operations to be re-scheduled across clock cycles, though not to the degree permitted in behavioral synthesis tools Gates A gate level description consists of a network of gates and registers instanced from a technology library, which contains technology-specific delay information for each gate Writing VHDL for Synthesis In the diagram above, the RTL level of abstraction is highlighted This is the ideal level of abstraction at which to design hardware given the state of the art of today's synthesis tools The gate level is too low a level for describing hardware - remember we're trying to move away from the implementation concerns of hardware design, we want to abstract to the specification level - what the hardware does, not how it does it Conversely, the algorithmic level is too high a level, most commercially available synthesis tools cannot produce hardware from a description at this level In the future, as synthesis technology progresses, we will one day view the RTL level of abstraction as the “dirty” way of writing VHDL for hardware and writing algorithmic (often called behavioral) VHDL will be the norm ECADLAB(VHDL) ELCTRONICS AND COMMUNICATION ENGINEERING Scope of VHDL VHDL is suited to the specification, design and description of digital electronic hardware System level VHDL is not ideally suited for abstract system-level simulation, prior to the hardwaresoftware split Simulation at this level is usually stochastic, and is concerned with modeling performance, throughput, queuing and statistical distributions VHDL has been used in this area with some success, but is best suited to functional and not stochastic simulation Digital VHDL is suitable for use today in the digital hardware design process, from specification through high-level functional simulation, manual design and logic synthesis down to gate-level simulation VHDL tools usually provide an integrated design environment in this area VHDL is not suited for specialized implementation-level design verification tools such as analog simulation, switch level simulation and worst case timing simulation VHDL can be used to simulate gate level fan-out loading effects providing coding styles are adhered to and delay calculation tools are available The standardization effort named VITAL (VHDL Initiative toward ASIC Libraries) is active in this area, and is now bearing fruit in that simulation vendors have built-in VITAL support More importantly, many ASIC vendors have VITAL-compliant libraries, though not all are allowing VITAL-based signoff - not yet anyway Analogue In 1999, the IEEE approved Standard 1076.1, which is informally known as VHDL-AMS It is a true super-set of VHDL, and includes analog and mixed-signal extensions ECADLAB(VHDL) ELCTRONICS AND COMMUNICATION ENGINEERING Design process The diagram below shows a very simplified view of the electronic system design process incorporating VHDL The central portion of the diagram shows the parts of the design process which are most impacted by VHDL Design Flow using VHDL The diagram below summarizes the high level design flow for an ASIC (ie gate array, standard cell) or FPGA In a practical design situation, each step described in the following sections may be split into several smaller steps, and parts of the design flow will be iterated as errors are uncovered System-level Verification As a first step, VHDL may be used to model and simulate aspects of the complete system containing one or more devices This may be a fully functional description of the system allowing the FPGA/ASIC specification to be validated prior to commencing detailed design Alternatively, this may be a partial description that abstracts certain properties of the system, such as a performance model to detect system performance bottle-necks ECADLAB(VHDL) ELCTRONICS AND COMMUNICATION ENGINEERING RTL design and test bench creation Once the overall system architecture and partitioning is stable, the detailed design of each FPGA/ASIC can commence This starts by capturing the design in VHDL at the register transfer level, and capturing a set of test cases in VHDL These two tasks are complementary, and are sometimes performed by different design teams in isolation to ensure that the specification is correctly interpreted The RTL VHDL should be synthesizable if automatic logic synthesis is to be used Test case generation is a major task that requires a disciplined approach and much engineering ingenuity: the quality of the final FPGA/ASIC depends on the coverage of these test cases RTL verification The RTL VHDL is then simulated to validate the functionality against the specification RTL simulation is usually one or two orders of magnitude faster than gate level simulation, and experience has shown that this speed-up is best exploited by doing more simulation, not spending less time on simulation In practice it is common to spend 7080% of the design cycle writing and simulating VHDL at and above the register transfer level, and 20-30% of the time synthesizing and verifying the gates Look-ahead Synthesis Although some exploratory synthesis will be done early on in the design process, to provide accurate speed and area data to aid in the evaluation of architectural decisions and to check the engineer's understanding of how the VHDL will be synthesized, the main synthesis production run is deferred until functional simulation is complete It is pointless to invest a lot of time and effort in synthesis until the functionality of the design is validated ECADLAB(VHDL) ELCTRONICS AND COMMUNICATION ENGINEERING Benefits of using VHDL Executable specification It is often reported that a large number of ASIC designs meet their specifications first time, but fail to work when plugged into a system VHDL allows this issue to be addressed in two ways: A VHDL specification can be executed in order to achieve a high level of confidence in its correctness before commencing design, and may simulate one to two orders of magnitude faster than a gate level description A VHDL specification for a part can form the basis for a simulation model to verify the operation of the part in the wider system context (eg printed circuit board simulation) This depends on how accurately the specification handles aspects such as timing and initialization Behavioral simulation can reduce design time by allowing design problems to be detected early on, avoiding the need to rework designs at gate level Behavioral simulation also permits design optimization by exploring alternative architectures, resulting in better designs ECADLAB(VHDL) ... is to use VHDL throughout the design process ECADLAB (VHDL) ELCTRONICS AND COMMUNICATION ENGINEERING VHDL ''93 As an IEEE standard, VHDL must undergo a review process every years (or sooner) to. .. writing VHDL for hardware and writing algorithmic (often called behavioral) VHDL will be the norm ECADLAB (VHDL) ELCTRONICS AND COMMUNICATION ENGINEERING Scope of VHDL VHDL is suited to the specification,... design and press next ECADLAB (VHDL) 13 ELCTRONICS AND COMMUNICATION ENGINEERING Click on the button indicated by an arrow Xilinx XST Vhdl ECADLAB (VHDL) located under Synthesis tool: and select