Style Question for Components

Discussion in 'VHDL' started by Shannon, Sep 5, 2007.

  1. Shannon

    Shannon Guest

    Finally I have a STYLE question rather than a how-to!

    So I'm putting together the top level of my hierarchical design. I
    have many individual entities in my 'work' directory that I want to
    hook together.

    What is the "standard" that you synthisis guys use?

    Declare - Instantiate - Configure a-la VHDL '87
    or
    direct instantiation a-la VHDL '93?

    or something else?

    Shannon
    Shannon, Sep 5, 2007
    #1
    1. Advertising

  2. Shannon wrote:

    > What is the "standard" that you synthisis guys use?


    This guy uses

    ---------> direct instantiation a-la VHDL '93?

    Here's an example from a testbench, but it's
    the same format in synthesis structures.

    -- Mike Treseler

    dut : entity work.uart
    port map (
    clock => clk_s, -- [in] -- by tb_clk
    reset => rst_s, -- [in] -- by tb_clk
    address => address_s, -- [in] -- by main
    writeData => writeData_s, -- [in] -- by main
    write_stb => write_stb_s, -- [in] -- by main
    readData => readData_s, -- [out]-- by uut
    read_stb => read_stb_s, -- [in] -- by main
    serialIn => serialIn_s, -- [in] -- by main,loopback dest
    serialOut => serialOut_s -- [out]-- by uut, loopback source
    );


    -- Mike Treseler
    Mike Treseler, Sep 5, 2007
    #2
    1. Advertising

  3. Shannon <> writes:

    > Finally I have a STYLE question rather than a how-to!
    >
    > So I'm putting together the top level of my hierarchical design. I
    > have many individual entities in my 'work' directory that I want to
    > hook together.
    >
    > What is the "standard" that you synthisis guys use?
    >

    Hi Shannon,

    My answer would be direct instantiation (unless you have a really good
    reason not to).

    We had a thread about this a while ago: (sorry, long line!)
    http://groups.google.co.uk/group/co...t instantiation&rnum=1&hl=en#f661479f1ba38b61

    Cheers,
    Martin

    --

    TRW Conekt - Consultancy in Engineering, Knowledge and Technology
    http://www.conekt.net/electronics.html
    Martin Thompson, Sep 6, 2007
    #3
  4. Shannon

    Andy Guest

    I'm with Mike, except I also declare the architecture name, as
    follows:

    dut : entity work.uart(rtl)

    where "rtl" is the name of an architecture for the entity uart.
    Otherwise, the least recently analyzed architecture gets used, just
    like with components and default bindings.

    Note that direct instantiation requires strict order of compilation,
    which with most tools is a very small price to pay for having no
    configurations and no components to mess with (nor the uncertainties
    of default bindings)*.

    * the language is not uncertain WRT default bindings, but I usually
    am!

    Andy
    Andy, Sep 6, 2007
    #4
  5. Shannon

    Shannon Guest

    Thanks for the replies all. Looks like direct instantiation is the
    winner.

    Andy, you mentioned strict order of compilation is required. Can you
    elaborate?

    Shannon
    Shannon, Sep 6, 2007
    #5
  6. Shannon

    Andy Guest

    On Sep 6, 10:03 am, Shannon <> wrote:
    > Thanks for the replies all. Looks like direct instantiation is the
    > winner.
    >
    > Andy, you mentioned strict order of compilation is required. Can you
    > elaborate?
    >
    > Shannon


    No, elaboration is different from compilation (analysis) ;^)

    Oh, you want more information on order of compilation...

    When you compile an architecture with component instantiations, only
    the component definition needs to be previously compiled (either in a
    package, or in the declarative region of the instantiating
    architecture itself). Subsequently, only if the component later
    changes does the instantiating architecture have to be recompiled.

    When you compile an architecture with a direct entity and architecture
    instantiation, both the architecture and its entity must already be
    compiled (naturally, the entity before its architecture).
    Subsequently, any change to the entity or architecture will force a
    recompile on the instantiating architecture.

    If the architecture is not indicated explicitly in an entity
    instantiation, then only entity changes (which would likely have
    caused the component to change also, had there been one) require the
    instantiating architecture to be recompiled. But the entity must have
    been compiled first before the instantiating architecture.

    For most tools, this is not a big problem, since they tend to take
    care of knowing when to compile what, once the design is compiled
    correctly the first time. Some tools allow you to just throw a list of
    files at them (in any order), and they will parse them and figure out
    the correct order (you have to tell them the top level usually). They
    can even correctly compile modules that occur out of order in the same
    file.

    Clear as mud?

    Andy
    Andy, Sep 6, 2007
    #6
  7. Shannon

    ms_sarwar

    Joined:
    Sep 6, 2007
    Messages:
    4
    Hi all..

    I have to change the layout of a website built in ASP.NET. I have the HTML/CSS code for the design. All I need to do is to use this HTML/CSS design in the website i.e in aspx pages but without changing to code i.e cs files. Can anyone give me an idea how to do that...

    thnx
    ms_sarwar, Sep 7, 2007
    #7
  8. Shannon

    scottcarl

    Joined:
    May 4, 2007
    Messages:
    49
    Location:
    USA
    The 'direct instantiation' takes a little less copying and pasting because the component doesn't need to be placed into the top of the code. However, you might find that when you need to refer back to that component, you'll have to go find that component code and reopen it. It's nice when the component is declared in the code already and you can simply scroll up the page to see which ports are in's, out's, or what their bit-widths are. You also don't have to comment every port since the component is already declared in the code. Just my 2 cents.

    Scott
    scottcarl, Sep 7, 2007
    #8
  9. Shannon

    Shannon Guest

    Um, what?

    My spell checker says those were all english words but I don't think
    I've ever seen them in that particular order before.

    Shannon
    Shannon, Sep 7, 2007
    #9
  10. Shannon wrote:
    > Um, what?


    Compile
    my_entity
    before compiling
    my_instance: work.my_entity(synth)

    "before" might mean in the file before
    or in a line above.

    -- Mike Treseler
    Mike Treseler, Sep 7, 2007
    #10
  11. Shannon

    Shannon Guest

    On Sep 7, 10:07 am, Mike Treseler <> wrote:
    > Shannon wrote:
    > > Um, what?

    >
    > Compile
    > my_entity
    > before compiling
    > my_instance: work.my_entity(synth)
    >
    > "before" might mean in the file before
    > or in a line above.
    >
    > -- Mike Treseler


    Got it. Thanks Mike.

    Andy: I hope you took my response in the right light. I thank you for
    your response. I was being a bit "cheeky" with my response. I really
    did have to read it through about ten times before I got it.

    Shannon
    Shannon, Sep 7, 2007
    #11
  12. Shannon

    Andy Guest

    On Sep 7, 1:55 pm, Shannon <> wrote:
    > On Sep 7, 10:07 am, Mike Treseler <> wrote:
    >
    > > Shannon wrote:
    > > > Um, what?

    >
    > > Compile
    > > my_entity
    > > before compiling
    > > my_instance: work.my_entity(synth)

    >
    > > "before" might mean in the file before
    > > or in a line above.

    >
    > > -- Mike Treseler

    >
    > Got it. Thanks Mike.
    >
    > Andy: I hope you took my response in the right light. I thank you for
    > your response. I was being a bit "cheeky" with my response. I really
    > did have to read it through about ten times before I got it.
    >
    > Shannon


    You didn't want me to just GIVE you the answer, did you? ;^)

    Andy
    Andy, Sep 10, 2007
    #12
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Rob Nicholson
    Replies:
    3
    Views:
    725
    Rob Nicholson
    May 28, 2005
  2. Replies:
    0
    Views:
    2,457
  3. Mickey Segal
    Replies:
    0
    Views:
    874
    Mickey Segal
    Feb 2, 2004
  4. Replies:
    1
    Views:
    789
    Bertilo Wennergren
    Nov 24, 2003
  5. Ken Varn
    Replies:
    0
    Views:
    450
    Ken Varn
    Apr 26, 2004
Loading...

Share This Page