Larry Doolittle
2739f83702
Spelling fixes in C and C++ comments
2015-06-04 15:00:29 -07:00
Martin Whitaker
ccf7c042c9
Fix null pointer dereference in debug output.
...
Don't display an elaborated for loop initial assignment if elaboration
has failed. Also remove duplicated message.
2015-04-13 16:31:28 +01:00
Martin Whitaker
b89c059153
Fix compiler crash on source code errors in always @* block loops.
...
The compiler was correctly detecting and reporting errors in loop
expressions and statements, but then crashing when it tried to build
the sensitivity list. Fix this by not adding a loop statement to the
netlist unless all its components have been successfully elaborated.
2015-04-13 14:39:10 +01:00
Maciej Suminski
35401f0e2c
ivl: Functions may return dynamic arrays.
2015-01-12 11:08:31 +01:00
Martin Whitaker
b400532169
Added support for interface declaration and instantiation.
...
modport and extern tf declarations are not yet supported.
2014-12-19 23:10:14 +00:00
Martin Whitaker
ce5c4ca8ba
Fix for br967 - allow real value for repeat statement loop length.
2014-12-13 19:50:33 +00:00
Cary R
6948c27c2d
Enumerations are compatible if their type definitions match.
2014-11-04 15:05:49 -08:00
Martin Whitaker
0237297e93
Added pruning of case statement expressions.
...
When unsized literals are used in case item expressions, it is likely
that the calculated expression width will be larger than necessary to
unambiguously select the correct case item (particularly when using
"strict" expression elaboration). This patch adds an optimisation
step that prunes the expressions to the minimum necessary width.
2014-11-02 13:02:57 +00:00
Martin Whitaker
e38b5d9fb7
Eliminate unnecessary rerun of test_width in case statement elaboration.
...
Also fix a typo in a comment.
2014-11-02 13:02:57 +00:00
Stephen Williams
712f394224
Elaborate classes in packages.
2014-10-10 18:53:53 -07:00
Stephen Williams
c5fee8bdb9
Elaborate root tasks/functions.
2014-09-30 16:06:32 -07:00
Cary R
d85096c56a
Add support for implict this in class methods
2014-09-16 17:08:57 -07:00
Stephen Williams
480668fee6
Add support for classes defined in $root scope.
2014-09-15 17:37:30 -07:00
Stephen Williams
fa21527e9f
Classes in $root scope up to elaboration.
2014-09-15 17:37:30 -07:00
Stephen Williams
88e951418b
Handle elaboration of class properties referenced within sub-scopes.
2014-09-06 16:26:08 -07:00
Stephen Williams
15ccd8f4c9
Handle foreach array name as class property.
2014-09-04 20:52:51 -07:00
Stephen Williams
3b0dfaadba
Some support for unpacked arrays in class properties.
2014-09-02 09:23:54 -07:00
Stephen Williams
dec4cd5071
Handle arrays of class objects.
...
This goes all the way down to the vvp level, where we create support
for arrays of objects, generate the new code in the -tvvp code
generator, and elaborate the arrays in the first place.
2014-08-30 10:18:57 -07:00
Stephen Williams
0cd6fbaf41
foreach loops around static arrays
...
Arrays with static dimensions can be handled specially.
This also allows for arbitrary numbers of dimensions.
2014-08-30 10:18:57 -07:00
Stephen Williams
9fa764285a
foreach multiple indices through the pform.
2014-08-30 10:18:57 -07:00
Cary R
c24c26725e
A method call needs to ignore a single NULL argument from the parser
...
The parser always passes a single NULL argument for system tasks. For a
method call which will add a signal to call the method on we need to
ignore this NULL argument.
2014-08-25 18:06:08 -07:00
Stephen Williams
f602ae84ab
Elaborate foreach loops as synthetic for loops.
...
Create an implicit scope to hold the index variable, and
generate a for loop to perform the functionality of the
foreach.
2014-08-21 16:44:46 -07:00
Stephen Williams
e8b8fcba57
Support declaring queue variables all the way to vvp.
...
Nothing actually useful happens here, but the declarations
are functional.
2014-08-21 16:44:45 -07:00
Cary R
0611135758
Some more cppcheck cleanup/updates
2014-06-29 20:39:40 -07:00
Martin Whitaker
d05abf5ca4
Fix for GitHub issue 26 - compiler crash when module port has no internal net.
...
The compiler correctly reports an error when a module port has no
associated internal net/reg, but could crash when the module was
instantiated.
2014-05-23 22:36:28 +01:00
Stephen Williams
be0c61051d
Add synthesis of for-loops
...
This required keeping for-loops as actual things through the
netlist form so that the synthesizer can get at and understand
the parts of the for-loop. This may improve vvp code generation
in the future, but for now continue to present to the vvp code
generation the block-while form.
2014-05-08 15:05:08 -07:00
Stephen Williams
e55e832ea0
Handle unpacked arrays as output ports.
2014-04-06 08:40:09 -07:00
Stephen Williams
fc1f9ac6a5
Handle unpacked arrays as module input ports.
2014-04-06 08:40:09 -07:00
Stephen Williams
6caa41cc93
First pass at support for continuous assign of unpacked net arrays.
2014-04-06 08:40:09 -07:00
Stephen Williams
4e81939eda
Handle asynchronous if-without-else synthesis.
2014-02-15 14:16:22 -08:00
Larry Doolittle
3e95966d70
More spelling fixes
...
Mostly comments
Changs "initilzers" in a string visible with debug_elaborate.
Includes a few British->American changes in the root directory only.
2014-01-30 16:43:17 -08:00
Larry Doolittle
be17bfc0e9
Spelling fixes
...
Mostly comments.
One user-visible string ("Evalutated to ") changed in the debug_eval_tree case.
2014-01-30 15:34:20 -08:00
Stephen Williams
f906384423
Elaborate r-vlaue packed struct members pads as needed.
2014-01-11 19:19:15 -08:00
Stephen Williams
a3b29dd70b
Handle enumeration literals that are in $root.
2014-01-11 19:19:14 -08:00
Stephen Williams
68d83383ff
Elaborate nested l-values.
...
This gets nested l-values to (but just short of) the ivl_target API.
Now the elaborator can process nested l-values, but I haven't figured
out how to present that at the ivl_target.h API.
2013-11-16 16:27:05 -08:00
Stephen Williams
f16fd03dab
Elaborate PChainConstructor calls.
...
It is better to leave the handling of PChainConstructor calls to
the elaboration, instead of stripping them out early. This allows
for handling the arguments of the chain constructor in the correct
scope.
2013-11-10 18:03:19 -08:00
Cary R
d7c2118d10
Fix space issue
2013-10-22 09:47:49 -07:00
Cary R
97d06b107f
Add support for wait fork to the compiler and code generators
2013-10-22 09:41:03 -07:00
Stephen Williams
2030e06988
Parse/elaborate some array-patterns down to the ivl_target API.
2013-10-19 15:34:14 -07:00
Stephen Williams
18c338ad09
Handle array assignment patters through pform.
...
This gets us to elaboration. In the process also fix up ivl_type_t
type comparisons to do deep type comparison.
2013-10-19 15:34:14 -07:00
Cary R
c64b8900ca
Add support for disable fork to the compiler.
2013-10-17 19:34:57 -07:00
Stephen Williams
d025c8aa93
Non-method tasks/functions support default arguments.
2013-09-20 20:44:57 -07:00
Stephen Williams
7534abe325
Allow void functions to be called in functions.
2013-09-20 20:44:57 -07:00
Stephen Williams
7bc94d7810
Support functions that return void.
2013-09-20 20:44:57 -07:00
Stephen Williams
a9a1c50268
Support "this" for calling task methods.
2013-09-20 20:44:57 -07:00
Stephen Williams
d9e1bcf3d0
Handle task arguments with default expressions.
2013-09-20 20:44:57 -07:00
Cary R
d8f945be23
Add support for SV do/while
2013-09-16 20:02:09 -07:00
Stephen Williams
7d6d93e4e2
Handle synthesis l-values that are part selects.
2013-09-08 18:18:31 -07:00
Cary R
d6fe6ea936
Add support for calling a user functions as a task (SV)
2013-07-24 19:38:00 -07:00
Stephen Williams
173577d5f7
Merge branch 'work14'
2013-07-03 20:00:22 -07:00