Sign In

Don't have a Xilinx account yet?

  • Choose to receive important news and product information
  • Gain access to special content
  • Personalize your web experience on Xilinx.com

Create Account

Username

Password

Forgot your password?
XClose Panel
Xilinx Home
Reply
Visitor
rishik
Posts: 6
Registered: ‎08-26-2010
0
Accepted Solution

compilation of ieee_proposed library fails (ISE 13.2)

Hi,

   Has anyone tried using the Xilinx provided ieee_proposed library for fixed point?

I added the source in C:\Xilinx\13.2\ISE_DS\ISE\vhdl\src\ieee_proposed   to a library and tried

compiling it but got a bunch of syntax errors.  Not sure what I'm doing wrong.   I'm assuming the files

were provided so we could compile and use the library and reference it  for synthesis as follows:


library ieee_proposed;
use ieee_proposed.fixed_float_types.all; -- ieee_proposed for VHDL-93 version
use ieee_proposed.fixed_pkg.all; -- ieee_proposed for compatibility version 

 

I can use the ieee_proposed library in Aldec and simulate, etc. but when I try to compile the

source files provided within the Xilinx install into an ieee_proposed library, I get errors such as:

 

ERROR:HDLParsers:1303 - "fixed_pkg_c.vhd" Line 2038. Attribute instance_name cannot be used here.
ERROR:HDLParsers:1303 - "fixed_pkg_c.vhd" Line 2057. Attribute instance_name cannot be used here.
ERROR:HDLParsers:1303 - "fixed_pkg_c.vhd" Line 2072. Attribute instance_name cannot be used here.
ERROR:HDLParsers:821 - "fixed_pkg_c.vhd" Line 2279. Wrong index type for to_stdlogicvector.
ERROR:HDLParsers:821 - "fixed_pkg_c.vhd" Line 2286. Wrong index type for to_stdlogicvector.
ERROR:HDLParsers:1303 - "fixed_pkg_c.vhd" Line 2300. Attribute instance_name cannot be used here.
ERROR:HDLParsers:1303 - "fixed_pkg_c.vhd" Line 2325. Attribute instance_name cannot be used here.
ERROR:HDLParsers:1303 - "fixed_pkg_c.vhd" Line 2551. Attribute instance_name cannot be used here.
etc.

 

Thanks for any help

Visitor
rishik
Posts: 6
Registered: ‎08-26-2010
0

Re: compilation of ieee_proposed library fails (ISE 13.2)

another note: i tried both using hdl-93 and hdl-200x options with same results.

 

 

Xilinx Employee
debrajr
Posts: 122
Registered: ‎04-17-2011
0

Re: compilation of ieee_proposed library fails (ISE 13.2)

Have you included numeric_std and std_logic_1164 packages in your code along with the IEEE_Proposed packages? Can you provide the code where you are getting this error?
Visitor
kepsz
Posts: 15
Registered: ‎01-02-2012
0

Re: compilation of ieee_proposed library fails (ISE 13.2)

The same errors also occurred in mewith ISE 13.4 (win7 64bit)

 

My code is:

library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
use ieee.numeric_std.all;
library ieee_proposed;
use ieee_proposed.fixed_pkg.all;


entity fixed_point is
	port (
		CLK_in:		in std_logic;
		INPUT:	in	std_logic_vector( 11 downto 0 );
		OUTPUT:		out std_logic_vector ( 11 downto 0 ));
end fixed_point;

architecture Behavioral of fixed_point is
	signal a, b : ufixed (11 downto -10);
begin
	Process(CLK_in,INPUT)
		variable temp: unsigned(11 downto 0);
	begin
		if (rising_edge(CLK_in)) then
			temp := unsigned(INPUT);
			--a <= temp; some code will goes here later if fixed works...
		end if;
	end process;
end Behavioral;

 

The ieee_proposed library:

 

1.png

 

Fixed_pkg_c.vhdl version is 1.3 while fixed_float_types.c.vhdl stays in version 1.1 2010.09.22
In ISE_DS\ISE\vhdl\src\ieee_proposed, there is the version 1.2 of fixed_pkg_c, but also gaves similar errors, no matter if i using 93 or 200x compiler.

 

Xilinx Employee
debrajr
Posts: 122
Registered: ‎04-17-2011
0

Re: compilation of ieee_proposed library fails (ISE 13.2)

In case you are using any device other then Virtex-6 or Spartan-6 use a switch "-use_new_parser yes" in XST other Command line options and run Synthesis. This code should work without errors when Spartan-6 or Virtex-6 is targetted.
Visitor
kepsz
Posts: 15
Registered: ‎01-02-2012
0

Re: compilation of ieee_proposed library fails (ISE 13.2)

I'm on a Spartan3E-100 starter kit (Baysis2).

 

I used your option, but still getting the same errors like:

 

Started : "Create Schematic Symbol".
Running vhdtdtfi...
Command Line: vhdtdtfi -lib ieee_proposed fixed_float_types_c.vhdl -lib ieee_proposed fixed_pkg_c.vhdl -lib work fixed_multiplier.vhd -prj DAC_teszt -o fixed_point.spl -module fixed_point -template D:/Store/ISE_DS/ISE//data/splfile.tft -deleteonerror
Compiling vhdl file "D:/Store/DAC_teszt/fixed_float_types_c.vhdl" in Library
ieee_proposed.
Package <fixed_float_types> compiled.
Compiling vhdl file "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" in Library
ieee_proposed.
Package <fixed_pkg> compiled.
WARNING:HDLParsers:3350 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 1470. Null range: 0 downto 1 WARNING:HDLParsers:3350 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 1471. Null range: 0 downto 1 ...... ERROR:HDLParsers:1303 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 2038. Attribute instance_name cannot be used here. ERROR:HDLParsers:1303 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 2057. Attribute instance_name cannot be used here. ERROR:HDLParsers:1303 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 2072. Attribute instance_name cannot be used here. ....... ERROR:HDLParsers:1303 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 3811. Attribute instance_name cannot be used here. ERROR:HDLParsers:1303 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 3832. Attribute instance_name cannot be used here. ...... ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8344. Formal arg of to_UFix with no default value must be associated with an actual value. ERROR:HDLParsers:821 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8358. Wrong index type for to_stdulogicvector. ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8357. Formal arg of to_SFix with no default value must be associated with an actual value. ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8357. Formal arg of to_SFix with no default value must be associated with an actual value. vhdtdtfi:Declaration (Module fixed_point) not found. tdtfi(vhdl) completed with errors. Process "Create Schematic Symbol" failed

 

 

Visitor
kepsz
Posts: 15
Registered: ‎01-02-2012
0

Re: compilation of ieee_proposed library fails (ISE 13.2)

[ Edited ]

I have tryd to set target devices to spartan / virtex6 / others and with / withouth the xst new_parser option in both ise 13.4 and 12.1. All attemts failed, i got the same errors everywhere.

 

 

So how to use the fixed point package in ISE?

 

*I uploaded a small teszt project with all the libraries and  files incluided.

Visitor
kepsz
Posts: 15
Registered: ‎01-02-2012
0

Re: compilation of ieee_proposed library fails (ISE 13.2)

According to David Bishop in Xilinx forum: http://forums.xilinx.com/t5/Simulation-and-Verification/VHDL-fixed-point-package-support-in-ISE-simu..., the fixed_pkg_c package shoud work in ISE and while Xilinx ISE not support VHDL2008, this package is the only solution for using fixed numbers.

 

I followed his advises to his packages VS ISE:

 

Things Xilinx m11.1i didn't like about these packages:
1) 'instance_name showed as a syntax error, replace with package name
2) "to_stdlogicvector(to_sulv(arg))" shows as a type conversion error, replace
with casting "std_logic_vector(arg)"
3) Did not like any of the fixed point division routines,
had to comment them out.
4) Had to comment out the "?=" routines, XST could not deal with that syntax.

Now i reduced the amount of syntax errors greatly, but i still getting error because of this lines in the end of the package file:

 

-- pragma synthesis_on
-- rtl_synthesis on
  -- IN VHDL-2006 std_logic_vector is a subtype of std_ulogic_vector, so these
  -- extra functions are needed for compatability.
  function to_ufixed (
    arg                  : STD_LOGIC_VECTOR;  -- shifted vector
    constant left_index  : INTEGER;
    constant right_index : INTEGER)
    return UNRESOLVED_ufixed is
  begin
    return to_ufixed (
      arg => to_stdulogicvector (arg),
      left_index => left_index,
      right_index => right_index);
  end function to_ufixed;

  function to_ufixed (
    arg      : STD_LOGIC_VECTOR;       -- shifted vector
    size_res : UNRESOLVED_ufixed)       -- for size only
    return UNRESOLVED_ufixed is
  begin
    return to_ufixed (
      arg => to_stdulogicvector (arg),
      size_res => size_res);
  end function to_ufixed;

  function to_sfixed (
    arg                  : STD_LOGIC_VECTOR;  -- shifted vector
    constant left_index  : INTEGER;
    constant right_index : INTEGER)
    return UNRESOLVED_sfixed is
  begin
    return to_sfixed (
      arg => to_stdulogicvector (arg),
      left_index => left_index,
      right_index => right_index);
  end function to_sfixed;

  function to_sfixed (
    arg      : STD_LOGIC_VECTOR;       -- shifted vector
    size_res : UNRESOLVED_sfixed)       -- for size only
    return UNRESOLVED_sfixed is
  begin
    return to_sfixed (
      arg => to_stdulogicvector (arg),
      size_res => size_res);
  end function to_sfixed;

  -- unsigned fixed point
  function to_UFix (
    arg      : STD_LOGIC_VECTOR;
    width    : NATURAL;                 -- width of vector
    fraction : NATURAL)                 -- width of fraction
    return UNRESOLVED_ufixed is
  begin
    return to_UFix (
      arg => to_stdulogicvector (arg),
      width => width,
      fraction => fraction);
  end function to_UFix;

  -- signed fixed point
  function to_SFix (
    arg      : STD_LOGIC_VECTOR;
    width    : NATURAL;                 -- width of vector
    fraction : NATURAL)                 -- width of fraction
    return UNRESOLVED_sfixed is
  begin
    return to_SFix (
      arg => to_stdulogicvector (arg),
      width => width,
      fraction => fraction);
  end function to_SFix;

 

 

I'm out of solutions, so if somebody is able to use fixed numbers in ISE, please write it down how to...

Expert Contributor
rcingham
Posts: 2,010
Registered: ‎09-09-2010
0

Re: compilation of ieee_proposed library fails (ISE 13.2)

What error are you getting?
Please post the full error message via copy+paste.

------------------------------------------
"If it don't work in simulation, it won't work on the board."
Visitor
kepsz
Posts: 15
Registered: ‎01-02-2012
0

Re: compilation of ieee_proposed library fails (ISE 13.2)

The remaining errors:

 

ERROR:HDLParsers:509 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 4304. function or procedure to_ufixed already declared with same profile and other parameters
ERROR:HDLParsers:821 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8209. Wrong index type for to_stdulogicvector.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8210. Formal port left_index does not exist in to_ufixed.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8210. Formal port left_index does not exist in to_ufixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8208. Formal arg of to_ufixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8210. Formal port left_index does not exist in to_ufixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8208. Formal arg of to_ufixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8210. Formal port left_index does not exist in to_ufixed.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8210. Formal port left_index does not exist in to_ufixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8208. Formal arg of to_ufixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8210. Formal port left_index does not exist in to_ufixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8208. Formal arg of to_ufixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8210. Formal port left_index does not exist in to_ufixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8208. Formal arg of to_ufixed with no default value must be associated with an actual value.
ERROR:HDLParsers:821 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8220. Wrong index type for to_stdulogicvector.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8221. Formal port size_res does not exist in to_ufixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8219. Formal arg of to_ufixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8221. Formal port size_res does not exist in to_ufixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8219. Formal arg of to_ufixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8221. Formal port size_res does not exist in to_ufixed.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8221. Formal port size_res does not exist in to_ufixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8219. Formal arg of to_ufixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8221. Formal port size_res does not exist in to_ufixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8219. Formal arg of to_ufixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8221. Formal port size_res does not exist in to_ufixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8219. Formal arg of to_ufixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8221. Formal port size_res does not exist in to_ufixed.
ERROR:HDLParsers:821 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8231. Wrong index type for to_stdulogicvector.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8232. Formal port left_index does not exist in to_sfixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8230. Formal arg of to_sfixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8232. Formal port left_index does not exist in to_sfixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8230. Formal arg of to_sfixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8232. Formal port left_index does not exist in to_sfixed.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8232. Formal port left_index does not exist in to_sfixed.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8232. Formal port left_index does not exist in to_sfixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8230. Formal arg of to_sfixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8232. Formal port left_index does not exist in to_sfixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8230. Formal arg of to_sfixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8232. Formal port left_index does not exist in to_sfixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8230. Formal arg of to_sfixed with no default value must be associated with an actual value.
ERROR:HDLParsers:821 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8242. Wrong index type for to_stdulogicvector.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8241. Formal arg of to_sfixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8243. Formal port size_res does not exist in to_sfixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8241. Formal arg of to_sfixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8243. Formal port size_res does not exist in to_sfixed.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8243. Formal port size_res does not exist in to_sfixed.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8243. Formal port size_res does not exist in to_sfixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8241. Formal arg of to_sfixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8243. Formal port size_res does not exist in to_sfixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8241. Formal arg of to_sfixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8243. Formal port size_res does not exist in to_sfixed.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8241. Formal arg of to_sfixed with no default value must be associated with an actual value.
ERROR:HDLParsers:850 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8243. Formal port size_res does not exist in to_sfixed.
ERROR:HDLParsers:821 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8254. Wrong index type for to_stdulogicvector.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8253. Formal arg of to_UFix with no default value must be associated with an actual value.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8253. Formal arg of to_UFix with no default value must be associated with an actual value.
ERROR:HDLParsers:821 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8267. Wrong index type for to_stdulogicvector.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8266. Formal arg of to_SFix with no default value must be associated with an actual value.
ERROR:HDLParsers:851 - "D:/Store/DAC_teszt/fixed_pkg_c.vhdl" Line 8266. Formal arg of to_SFix with no default value must be associated with an actual value.