delorie.com/archives/browse.cgi | search |
X-Authentication-Warning: | delorie.com: mail set sender to geda-user-bounces using -f |
X-Recipient: | geda-user AT delorie DOT com |
X-Virus-Scanned: | amavisd-new at oregonstate.edu |
Date: | Sun, 19 Feb 2012 20:38:44 -0800 |
From: | Traylor Roger <traylor AT eecs DOT oregonstate DOT edu> |
To: | geda-user AT delorie DOT com |
Subject: | Re: [geda-user] verilog question - blocking/non-blocking |
Message-ID: | <20120220043844.GA26101@slana.eecs.oregonstate.edu> |
References: | <4F41CB0A DOT 2020902 AT optonline DOT net> |
Mime-Version: | 1.0 |
In-Reply-To: | <4F41CB0A.2020902@optonline.net> |
User-Agent: | Mutt/1.4.2.2i |
Reply-To: | geda-user AT delorie DOT com |
Errors-To: | nobody AT delorie DOT com |
X-Mailing-List: | geda-user AT delorie DOT com |
X-Unsubscribes-To: | listserv AT delorie DOT com |
Gene, A good place to find info on this is: http://www.sunburst-design.com Especially see the paper: Nonblocking Assignments in Verilog Synthesis, Coding Styles That Kill! Roger On Sun, Feb 19, 2012 at 11:24:42PM -0500, gene glick wrote: > consider this code: > > always @(posedge clk) > begin > count = count + 1; // blocking method > if (count == 0) > do_something > end > > > then this way . . . > > > always @(posedge clk) > begin > count <= count + 1; // non-blocking method > if (count == 0) > do_something > end > ------------------------------------------- > > The 1st way, do_something occurs when the count is actually at 0. The > second way, do_something occurs when the count is 1. Subtle difference. > I don't have a synthesis tool ready to run, otherwise I'd try it. > Question : does one method synthesize significantly different logic than > the other? > > > >
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |