Blocking and non blocking assignment in VHDL

Discussion in 'VHDL' started by Hendra Gunawan, Apr 8, 2004.

  1. Hi folks,
    In Verilog, we have blocking and non blocking assignments. Is there any
    equivalent assignment in VHDL? From my understanding, inside the "process",
    statements are executed consecutively. Is there anyway that I can make it
    concurrent, just like the one in Verilog when we use "<=" assignment to
    ensure concurrent execution of all the statements in the always block?
    Thanks!

    Hendra
    Hendra Gunawan, Apr 8, 2004
    #1
    1. Advertising

  2. On Wed, 7 Apr 2004 21:08:44 -0700, "Hendra Gunawan"
    <> wrote:

    >Hi folks,
    >In Verilog, we have blocking and non blocking assignments. Is there any
    >equivalent assignment in VHDL?


    In VHDL, we have blocking and non blocking assignments that are
    roughly equivalent to the Verilog ones.

    There is a major difference though: All assignments to signals (with
    '<=' ) are non blocking (i.e. they happen some (delta) time in the
    future), and all assignments to variables (with ':=' )are blocking
    (i.e. they happen immediately).

    Signals are like regs or wires, depending on context.
    Variables are like regs.

    Variables (mostly) can only be declared within processes, and have a
    scope that is restricted to that process.

    >From my understanding, inside the "process",
    >statements are executed consecutively. Is there anyway that I can make it
    >concurrent, just like the one in Verilog when we use "<=" assignment to
    >ensure concurrent execution of all the statements in the always block?


    Yes, if you use signals, this will happen automatically.

    Also, since variables can only be used in the process in which they
    are defined, a major possible cause of races has been eliminated.

    Regards,
    Allan.
    Allan Herriman, Apr 8, 2004
    #2
    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. Edward L. Hepler

    "non-blocking" read in VHDL?

    Edward L. Hepler, Jan 12, 2004, in forum: VHDL
    Replies:
    0
    Views:
    555
    Edward L. Hepler
    Jan 12, 2004
  2. Andre Kelmanson

    blocking i/o vs. non blocking i/o (performance)

    Andre Kelmanson, Oct 10, 2003, in forum: C Programming
    Replies:
    3
    Views:
    926
    Valentin Tihomirov
    Oct 12, 2003
  3. nukleus
    Replies:
    14
    Views:
    832
    Chris Uppal
    Jan 22, 2007
  4. Christian
    Replies:
    5
    Views:
    731
    Esmond Pitt
    Dec 2, 2007
  5. Serge Savoie
    Replies:
    4
    Views:
    267
    Serge Savoie
    Oct 1, 2008
Loading...

Share This Page