In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-04 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/01 Report--
This article is mainly about "what's the difference between fork-join in Verilog and SystemVerilog". Interested friends might as well take a look. The method introduced in this paper is simple, fast and practical. Let's let the editor take you to learn "what's the difference between fork-join in Verilog and SystemVerilog?"
The main disadvantage of the fork-join structure in Verilog is that the execution of code outside the parallel structure is paused until all processes in the fork-join are completed.
For example, in the following code, the last $display statement is executed only after 10 time units
Although process 1 is completed in 5 time units
Modulefork_join_tests; integer out_val; initial begin fork begin / / First process # 5$ display ("exit first process at t =% 0d", $time); endbegin / / Second process # 10$ display ("exit second process at t =% 0d", $time); end join$display ("exit fork join at t =% 0d", $time); endendmodule / / fork_join_tests
The above code shows the output:
Exit first process at t = 5exit second process at t = 10exit fork join at t = 10
SystemVerilog adds two new keywords for parallel processes: join_any and join_none
When the join in the above code is replaced by join_any, the output is displayed:
Exit first process at t = 5exit second process at t = 10exit fork join at t = 5
Fork-join_any exits after the completion of the first process, that is, five units of time.
When join_none replaces join, the following output is displayed:
Exit first process at t = 5exit second process at t = 10exit fork join at t = 0
Fork-join_none does not wait for any of these processes to complete, that is, to exit at time unit 0.
At this point, I believe you have a deeper understanding of "what's the difference between Verilog and fork-join in SystemVerilog". You might as well do it in practice. Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.