summaryrefslogtreecommitdiffstats
path: root/verilog.tex
diff options
context:
space:
mode:
authorYann Herklotz <git@yannherklotz.com>2020-11-15 21:57:03 +0000
committerYann Herklotz <git@yannherklotz.com>2020-11-15 21:57:03 +0000
commit243ac4b3194e9bd6c2c835a032a596745d60f50e (patch)
tree3b3b0014af0ddb5d5bc98a486dbda2adf1f0e4eb /verilog.tex
parentfe75887a8858f82c71ca617c6d3f0c2db5af6cc2 (diff)
downloadoopsla21_fvhls-243ac4b3194e9bd6c2c835a032a596745d60f50e.tar.gz
oopsla21_fvhls-243ac4b3194e9bd6c2c835a032a596745d60f50e.zip
More modifications to Verilog section
Diffstat (limited to 'verilog.tex')
-rw-r--r--verilog.tex2
1 files changed, 1 insertions, 1 deletions
diff --git a/verilog.tex b/verilog.tex
index 9d6372c..5788070 100644
--- a/verilog.tex
+++ b/verilog.tex
@@ -16,7 +16,7 @@ The semantics of Verilog differ from regular programming languages, as it is use
\noindent which shows that assuming the statement $s$ in the always block runs with state $\Sigma$ and produces the new state $\Sigma'$, the always block will result in the same final state. As only clocked always blocks are supported, and one step in the semantics correspond to one clock cycle, it means that this rule is run once per clock cycle which is what it is defined to do.
-Two types of assignments are supported in always blocks: nonblocking and blocking assignment. Nonblocking assignment modifies the signal at the end of the timestep and atomically. Blocking assignment, on the other hand, assigns the variable directly in the always block for later signals to pick up. To model both these assignments, the state $\Sigma$ can be split
+Two types of assignments are supported in always blocks: nonblocking and blocking assignment. Nonblocking assignment modifies the signal at the end of the timestep and atomically. Blocking assignment, on the other hand, assigns the variable directly in the always block for later signals to pick up. To model both these assignments, the state $\Sigma$ has to be split into two parts: $\Gamma$, containing the current values of all variables, and $\Delta$, containing the values that will be assigned to the variables at the end of the clock cycle, we can therefore say that $\Sigma = (\Gamma, \Delta)$.
When targeting a hardware description language such as Verilog, it is important to be consistent between simulating the hardware and the behaviour of the synthesised result on actual hardware. In the target Verilog semantics, only clocked always blocks are supported as these ensure that there are not mismatches between simulation and synthesis, as combinational always blocks that trigger on any change of an internal signal may behave differently in simulation or synthesis based on the order of operations. This limitation in the semantics therefore helps keep the Verilog correct and consistent. In addition to that, only nonblocking assignment is used in signals that are used in multiple always blocks, which stops any race conditions from occurring as all the signal updates happen deterministically. Finally, a specific order of evaluation for the always blocks is chosen, and because of the limitations listed before, choosing an order is guaranteed to have the same behaviour as executing the always blocks in any order.