Commit Graph

8682 Commits

Author SHA1 Message Date
martinwhitaker a4c9919e3a
Merge pull request #349 from hzeller/fix-bison-include
Bison includes its generated header in *.cc. Generate with correct name.
2020-07-30 15:53:21 +01:00
martinwhitaker 929ffed6ab
Merge pull request #347 from vowstar/fix-nm
aclocal.m4: fix issue in cross-compiling
2020-07-30 09:38:22 +01:00
Cary R a2ba8a16b1 Add support for inserting into a queue 2020-07-29 23:00:19 -07:00
Cary R bed4758b0f A value of all X or Z can be an immediate number 2020-07-29 23:00:09 -07:00
Henner Zeller 5b699c1be7 Bison includes its generated header in *.cc. Generate with correct name.
The current bison (3.7) generates a *.cc file that includes the header
it generated. For parse.cc this would be parse.hh. Right now, we rename
this header to have a common name used in other files, but this results
in a compile error for the parse.cc file:

parse.cc:462:10: fatal error: parse.hh: No such file or directory
  462 | #include "parse.hh"
      |          ^~~~~~~~~~

Fix this by telling bison to output the header file to the correct
filename in the first place so that we don't have to rename it.
(using the --defines instead of -d option).

This looks like a bison specific option not available in Posix yacc;
but looks like we're requiring bison anyway.

Signed-off-by: Henner Zeller <h.zeller@acm.org>
2020-07-29 15:29:08 -07:00
Huang Rui d827f674cc
aclocal.m4: fix the comment contradicts the previous line
Changed to "the nm(1) utility or an equivalent is available,
and its name is defined by the $NM variable.

Signed-off-by: Huang Rui <vowstar@gmail.com>
2020-07-28 21:15:49 +08:00
Martin Whitaker e69549034d Fix potential buffer overflows (GitHub issue #346). 2020-07-28 13:17:57 +01: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 cf8222fcfe A queue does not have dimensions so just assume the base is 0 for an L-val 2020-07-26 14:02:37 -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 520d5b392a Add support for pop_back/front without () 2020-07-25 22:16:54 -07:00
Cary R 6ecd43d947 Add/update queue compile time error messages 2020-07-25 16:33:30 -07:00
Cary R d1b75d9407 Update some queue warning messages and optimize element erase 2020-07-25 15:32:28 -07:00
Cary R 1a4345cce9 Add the ability to delete an element of a queue 2020-07-25 00:49:42 -07:00
Huang Rui f3396d502d
aclocal.m4: fix issue in cross-compiling
The aclocal.m4 called nm directly.
It can cause issue in cross-compiling and because is not possible
use a different NM implementation (like llvm-nm).
The compile error log:
https://bugs.gentoo.org/attachment.cgi?id=648556

Closes: https://bugs.gentoo.org/731906
Signed-off-by: Huang Rui <vowstar@gmail.com>
2020-07-25 12:50:49 +08: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 5f8aa24093 Remove duplicate FILE_NAME() call 2020-07-23 18:49:54 -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 5ebd08c7f8 The queue needs to be implemented using a deque 2020-07-21 20:02:11 -07:00
Cary R 2999f351d2 Update queue error/warning messages 2020-07-20 20:34:17 -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 83c86735bb Update vlog95 to not crash with queue maximum index 2020-07-17 02:19:36 -07:00
Cary R 6ff07c1074 Enable support for providing a queue maximum index 2020-07-17 01:32:53 -07:00
martinwhitaker 2c9cce2303
Merge pull request #342 from purdeaandrei/f_add_assert_before_dereferencing_pointer
Add assert to protect against potentially dereferencing null pointer.
2020-07-16 10:48:11 +01:00
Martin Whitaker 4cc929c71a CI: ignore line-endings when checking results on Windows. 2020-07-11 09:26:23 +01:00
Purdea Andrei 8889886efd Add assert to protect against potentially dereferencing null pointer.
Assert is apropriate, since it's not expected that the returned value is NULL in this case.
2020-07-11 03:54:29 +03:00
martinwhitaker 3d305b33df
Merge pull request #339 from dredozubov/update-osx-readme
Update MacOS instructions
2020-07-11 00:10:42 +01:00
Martin Whitaker b36bca1f1b Add support for return statements in void functions. 2020-07-10 23:34:11 +01:00
martinwhitaker 07256646a5
Merge pull request #334 from purdeaandrei/f_fix_portless_declarationless_functions
Fix port-list-less declaration-less functions for SystemVerilog
2020-07-10 22:47:53 +01:00
Martin Whitaker 4e7dfac6c4 CI: automatically update expected results for msys2. 2020-07-10 22:05:07 +01:00
Cary R dd80607ceb Add CA version of the <-> operator 2020-07-09 01:45:43 -07:00
Cary R c003bcc59a Add support for <-> in constant and procedural contexts 2020-07-07 23:29:19 -07:00
Cary R 018a649f59 A time variable defaults to unsigned, but can be declared as signed 2020-07-07 20:33:03 -07:00
Cary R b8ae9a85fa Update size check in $fread() 2020-07-03 23:15:39 -07:00
Denis Redozubov e5ca8c4fa4 Update MacOS instructions
* Update README to reflect that bison fails to generate correct code
  on newer MacOS as well and bison 3.6+ works fine as well
* macos.txt removed because it contains outdated instructions
2020-06-30 22:09:54 +03:00
Cary R 6d8dea8d05 Update fstapi.c to latest from GTKWave 2020-06-28 20:12:14 -07:00
Martin Whitaker 085f466377 Fix GitHub issue #337 - incorrect uninitialised function return value. 2020-06-25 00:31:43 +01:00
Purdea Andrei a4d91c9023 Fix port-list-less declaration-less functions for SystemVerilog
For functions without a port list in parantheses, declarations are optional in SystemVerilog.
This is true even in IEEE1800-2005, but not in IEEE1364-2005
2020-06-22 23:51:10 +03:00
martinwhitaker ed7734c795
Merge pull request #328 from purdeaandrei/f_allow_libext_and_y_commands_to_be_given_in_any_order
Allow +libext+ and -y commands to be given in any order (and small fix in manpage)
2020-06-03 14:57:09 +01:00
Purdea Andrei c217d7d759 fix compilation issues on older gcc5 2020-06-03 15:58:27 +03:00
Purdea Andrei 859341273e Don't use C++11 feature std::tuple, instead use std::pair 2020-06-03 14:47:11 +03:00
martinwhitaker a849ca28ef
Merge pull request #327 from purdeaandrei/f_fix_how_explicitly_unconnected_ports_are_handled_with_dotstar
Fix how explicitly unconnected ports are handled in the presence of .*
2020-06-03 11:42:29 +01:00
martinwhitaker 0b87ecb173
Merge pull request #325 from tpambor/fix-missing-include
Add missing include for malloc
2020-06-02 20:56:37 +01:00
Martin Whitaker 8e4593bf90 CI: really fix Windows build, check VVP results, run VPI tests. 2020-06-02 20:27:58 +01:00
Martin Whitaker 4466a19fb1 Attempt to fix Travis CI on Windows. 2020-06-01 13:18:00 +01:00
Cary R 0fca1bdab0 Add vpiIndex for array words 2020-05-31 14:27:19 -07:00