Go Back   Velocity Reviews > Newsgroups > VHDL
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply

VHDL - Synopsys & VHDL: **FFGEN**

 
Thread Tools Search this Thread
Old 12-02-2003, 10:11 PM   #1
Default Synopsys & VHDL: **FFGEN**


Hi NG,

i'm trying to get Synopsys to "compile" a behavioural description of a FSM
(some sort of 8-bit shift register) to a structural description (synthese).
Running the design optimization i only get **FFGEN** instead of "real" flip
flops... can anybody give me a hint why this doesn't work?

Thanks, Sebastian

VHDL-Description:
-------------------
PACKAGE my_types IS
TYPE CtlTyp IS (fHLT,fSHL,fSAL,fROL,fRCL);
END my_types;

LIBRARY IEEE;
USE IEEE.std_logic_1164.ALL;
USE WORK.my_types.ALL;

ENTITY SReg8 IS
PORT(clk,load,reset,cin : IN Bit;
control : IN CtlTyp;
datain : IN Bit_Vector(7 DOWNTO 0);
dataout : OUT Bit_Vector(7 DOWNTO 0);
cout : OUT Bit);
END SReg8;

ARCHITECTURE beh1 OF SReg8 IS
SIGNAL AktReg, NextReg:Bit_Vector(8 DOWNTO 0);

BEGIN
PROCESS(clk,reset,load,datain,cin)
BEGIN
IF reset = '1' THEN
AktReg<="000000000";
ELSIF load = '1' THEN
AktReg <= cin & datain(7 DOWNTO 0);
ELSIF (clk'EVENT AND clk ='1') THEN
AktReg <= NextReg;
END IF;
END PROCESS;

PROCESS(AktReg,control)
BEGIN
CASE control IS
WHEN fHLT => NextReg <= AktReg;
WHEN fSAL => NextReg <= AktReg(7 DOWNTO 0) & AktReg(0);
WHEN fSHL => NextReg <= AktReg(7 DOWNTO 0) & '0';
WHEN fROL => NextReg <= AktReg( & AktReg(6 DOWNTO 0) & AktReg(7);
WHEN fRCL => NextReg <= AktReg(7 DOWNTO 0) & AktReg(;
WHEN OTHERS => NextReg <= AktReg;
END CASE;
END PROCESS;

PROCESS(AktReg)
BEGIN
dataout <= AktReg(7 DOWNTO 0);
cout <= AktReg(;
END PROCESS;
END ARCHITECTURE;





Sebastian Becker
  Reply With Quote
Old 12-02-2003, 11:16 PM   #2
Sebastian Becker
 
Posts: n/a
Default Re: Synopsys & VHDL: **FFGEN**
Hi,

doing some more examination i found out that when i drop out these two lines
(parallel load function), it works (i get synthetisized FD2 flip flops).
i just don't get why?!

> ELSIF load = '1' THEN
> AktReg <= cin & datain(7 DOWNTO 0);



Sebastian




Sebastian Becker
  Reply With Quote
Old 12-03-2003, 08:02 AM   #3
Ansgar Bambynek
 
Posts: n/a
Default Re: Synopsys & VHDL: **FFGEN**
Hi Sebastian,

the problem is the asynchronous load to your ffs.
This would result in a flipflop with asynchronous reset, asynchronous load
and a triggering clock. I',m not sure which library has been mapped for
synthesis but I doubt that such a ff is available.
Try to make your load synchronous, i.e.

BEGIN
PROCESS(clk,reset)
BEGIN
IF reset = '1' THEN
AktReg<="000000000";
ELSIF (clk'EVENT AND clk ='1') THEN
IF load = '1' THEN
AktReg <= cin & datain(7 DOWNTO 0);
ELSE
AktReg <= NextReg;
END IF;
END IF;
END PROCESS;

HTH

Ansgar
--
Attention please, reply address is invalid, please remove "_xxx_" ro reply


"Sebastian Becker" <> schrieb im Newsbeitrag
news:bqj2q7$p13$...
> Hi NG,
>
> i'm trying to get Synopsys to "compile" a behavioural description of a FSM
> (some sort of 8-bit shift register) to a structural description

(synthese).
> Running the design optimization i only get **FFGEN** instead of "real"

flip
> flops... can anybody give me a hint why this doesn't work?
>
> Thanks, Sebastian
>
> VHDL-Description:
> -------------------
> PACKAGE my_types IS
> TYPE CtlTyp IS (fHLT,fSHL,fSAL,fROL,fRCL);
> END my_types;
>
> LIBRARY IEEE;
> USE IEEE.std_logic_1164.ALL;
> USE WORK.my_types.ALL;
>
> ENTITY SReg8 IS
> PORT(clk,load,reset,cin : IN Bit;
> control : IN CtlTyp;
> datain : IN Bit_Vector(7 DOWNTO 0);
> dataout : OUT Bit_Vector(7 DOWNTO 0);
> cout : OUT Bit);
> END SReg8;
>
> ARCHITECTURE beh1 OF SReg8 IS
> SIGNAL AktReg, NextReg:Bit_Vector(8 DOWNTO 0);
>
> BEGIN
> PROCESS(clk,reset,load,datain,cin)
> BEGIN
> IF reset = '1' THEN
> AktReg<="000000000";
> ELSIF load = '1' THEN
> AktReg <= cin & datain(7 DOWNTO 0);
> ELSIF (clk'EVENT AND clk ='1') THEN
> AktReg <= NextReg;
> END IF;
> END PROCESS;
>
> PROCESS(AktReg,control)
> BEGIN
> CASE control IS
> WHEN fHLT => NextReg <= AktReg;
> WHEN fSAL => NextReg <= AktReg(7 DOWNTO 0) & AktReg(0);
> WHEN fSHL => NextReg <= AktReg(7 DOWNTO 0) & '0';
> WHEN fROL => NextReg <= AktReg( & AktReg(6 DOWNTO 0) & AktReg(7);
> WHEN fRCL => NextReg <= AktReg(7 DOWNTO 0) & AktReg(;
> WHEN OTHERS => NextReg <= AktReg;
> END CASE;
> END PROCESS;
>
> PROCESS(AktReg)
> BEGIN
> dataout <= AktReg(7 DOWNTO 0);
> cout <= AktReg(;
> END PROCESS;
> END ARCHITECTURE;
>
>
>





Ansgar Bambynek
  Reply With Quote
Old 12-03-2003, 12:39 PM   #4
Sebastian Becker
 
Posts: n/a
Default Re: Synopsys & VHDL: **FFGEN**
Hi,

I thought the FD3 has asynchronous RESET and SET Pins? Anyways, I
synchronized the LOAD. Just curious...

Thanks, Sebastian




Sebastian Becker
  Reply With Quote
Old 12-03-2003, 02:17 PM   #5
Eyck Jentzsch
 
Posts: n/a
Default Re: Synopsys & VHDL: **FFGEN**
Sebastian Becker wrote:
> Hi,
>
> I thought the FD3 has asynchronous RESET and SET Pins? Anyways, I
> synchronized the LOAD. Just curious...
>
> Thanks, Sebastian
>
>

But no load pins...
In the load part of your statement you want to set your reg to a
variable value, set and reset only initialize to 1 or 0.

-Eyck



Eyck Jentzsch
  Reply With Quote
Old 12-04-2003, 01:11 PM   #6
Sebastian Becker
 
Posts: n/a
Default Re: Synopsys & VHDL: **FFGEN**
> > I thought the FD3 has asynchronous RESET and SET Pins? Anyways, I
> > synchronized the LOAD. Just curious...


> But no load pins...
> In the load part of your statement you want to set your reg to a
> variable value, set and reset only initialize to 1 or 0.


i thought synopsys is able to calculate some sort of logic functions around
the set and reset pins,something like:
(highactive Set and Reset)

RESET <= (NOT Datain) AND LoadEnable
SET <=Datain AND LoadEnable

Greets,
Sebastian




Sebastian Becker
  Reply With Quote
Old 12-04-2003, 06:59 PM   #7
Marcus Harnisch
 
Posts: n/a
Default Re: Synopsys & VHDL: **FFGEN**
"Sebastian Becker" <> writes:
> i thought synopsys is able to calculate some sort of logic functions around
> the set and reset pins,something like:
> (highactive Set and Reset)
>
> RESET <= (NOT Datain) AND LoadEnable
> SET <=Datain AND LoadEnable


But you don't want to have logic in your reset tree...

Check if there is a switch in Synopsys to force it doing what you
want.

-- Marcus

--
Marcus Harnisch | Mint Technology, a division of LSI Logic
| 200 West Street, Waltham, MA 02431
Tel: +1-781-768-0772 | http://www.lsilogic.com


Marcus Harnisch
  Reply With Quote
Old 12-05-2003, 01:13 PM   #8
Ansgar Bambynek
 
Posts: n/a
Default Re: Synopsys & VHDL: **FFGEN**
Hi Sebastian,

in your original code


> ELSIF load = '1' THEN
> AktReg <= cin & datain(7 DOWNTO 0);


Aktreg should asynchronously get cin & datain assigned.
These values are not fixed so the synthesis tools has no knowledge of what
values should aktreg get if load is active.
Cin and all the bits of datain might be high or low when load is active so a
set or reset does not work..

HTH
Ansgar


BTW you can contact me per email and we can continue the discussion in
german
--
Attention please, reply address is invalid, please remove "_xxx_" ro reply


"Sebastian Becker" <> schrieb im Newsbeitrag
news:bqnbta$qhc$...
> > > I thought the FD3 has asynchronous RESET and SET Pins? Anyways, I
> > > synchronized the LOAD. Just curious...

>
> > But no load pins...
> > In the load part of your statement you want to set your reg to a
> > variable value, set and reset only initialize to 1 or 0.

>
> i thought synopsys is able to calculate some sort of logic functions

around
> the set and reset pins,something like:
> (highactive Set and Reset)
>
> RESET <= (NOT Datain) AND LoadEnable
> SET <=Datain AND LoadEnable
>
> Greets,
> Sebastian
>
>





Ansgar Bambynek
  Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to execute an external software from VHDL? And how to interface VHDL with JAVA? becool_nikks Software 0 03-06-2009 07:08 PM
Dazzle Box... swt458 Hardware 2 01-15-2008 06:06 AM
Help on auto conversion from Matlab to vhdl on filter design hardheart Hardware 0 12-07-2007 09:19 AM
ARRAY(n DOWNTO 0) OF STD_LOGIC_VECTOR(m DOWNTO 0) - VHDL freitass Hardware 0 11-01-2007 03:44 PM
DC_SHELL, synopsys perseo Hardware 0 10-10-2007 10:58 AM




SEO by vBSEO 3.3.2 ©2009, Crawlability, Inc.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46