Cary R
a2ba8a16b1
Add support for inserting into a queue
2020-07-29 23:00:19 -07:00
Cary R
fdd902e446
Remove some clang warnings
2020-07-27 21:56:29 -07:00
Cary R
14ade1a9f4
Pass the max size when storing to a queue
2020-07-27 21:24:22 -07:00
Cary R
c969c324ed
Add initial support for using a queue element as an L-value
2020-07-26 14:02:29 -07:00
Cary R
1a4345cce9
Add the ability to delete an element of a queue
2020-07-25 00:49:42 -07:00
Cary R
e94291c88f
Handle negative and undefined queue addresses correctly
2020-07-23 22:49:33 -07:00
Cary R
f0f045f1f9
Add warning messages when popping from an empty queue
2020-07-23 22:04:27 -07:00
Cary R
1b52a4a578
Don't fail when pushing/poping from an empty queue
2020-07-23 19:12:35 -07:00
Cary R
e1870acfac
Return the correct value when a queue or darray references an undefined element
2020-07-22 21:47:37 -07:00
Cary R
1b7cd5c237
Add initial support for real queues
2020-07-19 21:34:56 -07:00
Cary R
bf6c4329b9
Add push front for string queues and improve some warning messages
2020-07-19 19:18:59 -07:00
Cary R
6ff07c1074
Enable support for providing a queue maximum index
2020-07-17 01:32:53 -07:00
Martin Whitaker
085f466377
Fix GitHub issue #337 - incorrect uninitialised function return value.
2020-06-25 00:31:43 +01:00
Cary R
89d3342804
Increase the thread flag count from 256 to 512
2020-05-31 12:39:54 -07:00
Martin Whitaker
351a4e5f5e
Improve vvp handling of excessively large shift distances.
2019-11-16 12:11:49 +00:00
Martin Whitaker
0a4cae2644
Fix vvp %shift instructions to treat right operand as unsigned.
...
1364-2005 section 5.1.12 says "The right operand is always treated
as an unsigned number".
This fixes GitHub issue #283 .
2019-11-15 21:24:47 +00:00
Martin Whitaker
1aa22735ce
Add new %cast/vec2/dar and %cast/vec4/dar instructions to vvp.
2019-09-11 21:56:27 +01:00
Martin Whitaker
74ff44314e
Add new %cast/vec4/str instruction to vvp.
2019-09-11 21:56:09 +01:00
Martin Whitaker
2ff6af254b
Use LLONG_MIN instead of LONG_LONG_MIN.
...
GCC 8 no longer defines LONG_LONG_MIN. We already assume a C99 compliant
compiler in other places.
2019-01-26 16:47:28 +00:00
Martin Whitaker
7ad5b59a6f
Fix for GitHub issue #199 : handle signed division overflow.
...
When performing a signed division or modulus operation using native
arithmetic, trap the special case that the numerator is the minimum
integer value and the denominator is -1, as this gives an undefined
result in C++.
2018-06-12 21:59:58 +01:00
Cary R
db1ea05452
Fix #0 to trigger in the inactive region and add a trigger for always_comb/latch
2017-12-03 20:17:42 -08:00
Cary R
3fc9ad2db0
Add support for the wild compare operators ==? and !=?
2017-11-17 19:32:50 -08:00
Martin Whitaker
e315cafa01
Fix for GitHub issue #165 : assertion failure on thread join.
...
If a thread becomes detached due to a join_any statement, that
thread must not attempt to join its parent, even if the parent
is waiting on a subsequent join statement.
2017-10-07 16:41:26 +01:00
Martin Whitaker
a1a7f5deff
Fix error in last commit.
2017-09-17 19:58:13 +01:00
Martin Whitaker
0bed890bc6
Fix use after free bug in vvp when a task or function is disabled.
...
Use test_joinable() and do_join() to ensure everything gets cleaned
up before the thread is reaped. This should fix br1016, br1017, and
br1018.
2017-09-17 19:48:54 +01:00
Maciej Suminski
f32b64f497
Fixed warnings about shifting a negative value
2016-09-19 12:54:15 -07:00
Martin Whitaker
61c82d2cb0
Handle mixed continuous and non-blocking assignments to same vector.
...
SystemVerilog allows a mixture of procedural and continuous assignments
to be applied to different parts of the same vector. The previous attempt
to make this work for non-blocking assignments was flawed (see preceding
fix for vvp_fun_part_pv::recv_vec4_pv). Instead, handle this case by
converting the non-blocking assignment into a delayed force statement,
which matches the way mixed continuous and blocking assignments are
handled.
2016-05-10 22:16:40 +01:00
Larry Doolittle
4521be4510
More spelling, comments only
2016-04-01 11:02:34 -07:00
Stephen Williams
9a7f31c728
Functions that return strings pass the return value on the stack.
2016-03-01 15:38:28 -08:00
Cary R
841593d013
Remove some compile warnings
2016-02-03 21:40:18 -08:00
Stephen Williams
76ced1cf7c
Fix %ret/* and %retload/* opcodes to search up for function thread.
2016-02-01 14:51:18 -08:00
Stephen Williams
f494b478cc
Merge branch 'master' into return-stack
...
# Conflicts:
# sv_vpi_user.h
2016-02-01 14:47:44 -08:00
Stephen Williams
ce692f90ad
Implement and use the %retload/real opcode.
2016-02-01 09:31:06 -08:00
Stephen Williams
604a62379c
Make .scope aware of return type, and extend %ret/vec4 operands
...
The .scope needs to be aware of return types so that the %call/vec4
function knows how to intialize the return value. We also need to
extend the %ret/vec4 to support writing parts of the return value.
2016-01-31 15:29:52 -08:00
Stephen Williams
e435a879fc
Add ability to read back return value / Add vec4 stacked user functions.
...
Also:
- handle functions as arguments to system tasks.
- Cleanup detect of signal as return value.
2016-01-24 18:36:26 -08:00
Stephen Williams
0c91a6b041
Add .ufunc/real functor to handle functions with return value on stack.
2016-01-17 16:23:28 -08:00
Stephen Williams
bfc9cd8715
Make real functions in processes use parent stack for return value.
2016-01-10 17:09:33 -08:00
Maciej Suminski
df6b24fd3a
ivl & vvp: Enabled 'string' as the return type in VPI functions.
2016-01-05 14:23:25 +01:00
Stephen Williams
63ad15ee2e
Rework user function calls to use specialized opcodes.
...
Create The %callf/* opcodes to invoke user defined functions in a
more specialized way. This allows for some sanity checking on the
way, and also is a step towards keeping return values on stacks.
2015-12-27 20:29:10 -08:00
Stephen Williams
fff69390ac
C++-ify the __vpiScope classes.
2015-12-20 20:26:57 -08:00
Stephen Williams
466b6464bc
Some minor vvp runtime performance tweaks.
2015-10-01 12:43:56 -07:00
Stephen Williams
4338d43cea
Opcodes documentation fixes.
2015-09-30 16:25:35 -07:00
Stephen Williams
fe7156289b
Remove some useless vvp opcodes.
2015-09-30 15:41:22 -07:00
Frederick C. Kurz
c35f2f8334
Changes to vvp/vthread.cc
...
"child->delay_delete = 1;" was added, for when building with "Microsoft Visual Studio Express 2015 RC Web" in DEBUG mode, so that pr2909555.v would pass with -strict, otherwise it would cause memory access error will trying to access the previously deleted "child" variable.
2015-07-22 18:02:45 -07:00
Martin Whitaker
97c6339241
Ensure VPI release on net connected to island returns correct value.
2015-07-01 09:00:43 +01:00
Martin Whitaker
dad223316e
Fix propagation of unforced bits when forcing a part select.
...
vvp_net_t::force_vec4 propagates all bits of the forced value passed
to it, regardless of the mask value. I can't see any way to fix this
directly, so instead make sure anything that calls force_vec4 sets
the unforced bits of the passed value to the correct value.
2015-06-25 00:13:57 +01:00
Larry Doolittle
2739f83702
Spelling fixes in C and C++ comments
2015-06-04 15:00:29 -07:00
Cary R
feb710a186
Add support for any width 2-state darray objects
2015-02-27 11:43:25 -08:00
Cary R
62abb199d7
Add support for 4-state dynamic arrays
2015-02-26 17:56:49 -08:00
Cary R
47688d234b
Assert if an unsupported dynamic array type is given.
2015-01-16 18:54:43 -08:00