Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
xst.pdf
Скачиваний:
143
Добавлен:
11.06.2015
Размер:
5.64 Mб
Скачать

Chapter 3: XST FPGA Optimization

R

LUT2 #(4'h1) inst (.I0(I0), .I1(I1), .O(O));

endmodule

Passing an INIT Value Via the Defparam Mechanism Verilog Coding Example

//

// Passing an INIT value via the defparam mechanism.

//

module v_primitive_3 (I0,I1,O); input I0,I1;

output O;

LUT2 inst (.I0(I0), .I1(I1), .O(O)); defparam inst.INIT = 4'h1;

endmodule

Using the UNIMACRO Library

In order to simplify instantiation of complex primitives as RAMs, XST supports an additional library called UNIMACRO. For more information, see the Xilinx Libraries Guides at http://www.xilinx.com/support/software_manuals.htm.

In VHDL, declare library unimacro with its package vcomponents in your source code:

library unimacro;

use unimacro.vcomponents.all;

The source code of this package can be found in the vhdl\src\ unisims\unisims_vcomp.vhd file of the XST installation.

In Verilog, the UNIMACRO library is precompiled. XST automatically links it with your design.

Cores Processing

This section discusses Cores Processing, and includes:

“About Cores Processing”

“Cores Processing VHDL Coding Example”

“Read Cores Enabled or Disabled”

About Cores Processing

If a design contains cores represented by an Electronic Data Interchange Format (EDIF) or an NGC file, XST can automatically read them for timing estimation and area utilization control. Use Project Navigator > Process Properties > Synthesis Options > Read Cores to enable or disable this feature. Using the read_cores option of the run command from the command line, you can also specify optimize. This enables cores processing, and allows XST to integrate the core netlist into the overall design. XST reads cores by default.

288

www.xilinx.com

XST User Guide

 

 

10.1

R

Cores Processing

Cores Processing VHDL Coding Example

In the following VHDL coding example, the block my_add is an adder, which is represented as a black box in the design whose netlist was generated by CORE Generator™.

library ieee;

use ieee.std_logic_1164.all; use ieee.std_logic_signed.all;

entity read_cores is port(

A, B : in std_logic_vector (7 downto 0); a1, b1 : in std_logic;

SUM : out std_logic_vector (7 downto 0); res : out std_logic);

end read_cores;

architecture beh of read_cores is component my_add

port (

A, B : in std_logic_vector (7 downto 0); S : out std_logic_vector (7 downto 0));

end component;

begin

res <= a1 and b1;

inst: my_add port map (A => A, B => B, S => SUM); end beh;

Read Cores Enabled or Disabled

If Read Cores is disabled, XST estimates Maximum Combinational Path Delay as 6.639ns (critical path goes through a simple AND function) and an area of one slice.

If Read Cores is enabled, XST issues the following messages during Low Level Synthesis:

...

===================================================================

*

* Low Level Synthesis

*

===================================================================

Launcher: Executing edif2ngd -noa "my_add.edn" "my_add.ngo" INFO:NgdBuild - Release 6.1i - edif2ngd G.21

INFO:NgdBuild - Copyright (c) 1995-2003 Xilinx, Inc. All rights reserved.

Writing the design to "my_add.ngo"...

Loading core <my_add> for timing and area information for instance <inst>.

===================================================================

...

XST User Guide

www.xilinx.com

289

10.1

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]