| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- added support parameter FORCE_TRISTATE_LOGIC on mk28000
- add system device SYS_PULSE to generate pulse based on input changes
parameters are delay, pulse width, input polarity and output polarity
- add USE_SPEED_HACKS define to gtrak10 to enable the use of the above
Brings gtrak10 from 18% to 120%.
- Improved interlaced video support in fixfreq.cpp
Added two interlace modes: progressive and interlaced which can
be selected in machine configuration.
- more clang format work
- rename link to connection
- introduced typed aliases. This information may be used later to
rewrite netlists.
- added a three terminal base device
This will allow the analog code to be more easily comparable to
literature about MNA (Modal node analysis).
BJT code is now a lot better readable.
- fix doxygen consistency
- added an example for a cmos inverter based on NMOS/PMOS fets.
- TRUTHTABLE_START was renamed to TRUTH_TABLE
- truth tables are now enclosed in braces
- netlists are now enclosed in braces
- TRUTHTABLE_END() and NETLIST_END() removed from files
- Fixed static solver script
- Add file path to includes in nltool
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* netlist: fix bug, prepare for future changes and improve readability
- fix a bug where a net processing error may trigger a nullptr access
- applied some clang-tidy recommendations
- add no_return to plib::terminate
- properly encapsulate dynamic_cast usage
- more review of noexcept
- added a clang-format file. Over time, all source files will be
processed with clang-format
- Used clang format on a number of files
- Rewrote 74174
- all device constructors now use a struct to pass data on
to base classes. Neither netlist state nor the name are intended
to be used in a constructor. After the base class was
constructed, they can be accessed by state() and name().
- The device construction macros can now be removed. Changes to
the core will not need to be reflected in constructors.
- Change truth table macros so that going forward NETLIST_END and
TRUTH_TABLE_END can be replaced by a closing curly brace. netlists can
than use curly braces enclosed blocks.
- more clang-format
- removed some macros completely
- all derived classes from base_device_t now don't use macros
any longer.
- as a result, delegator_t was removed. This class was only used
to support macros :-(
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* netlist: fix bugs and more cpp instead of macros
- C-style comments converted to c++
- Fix crash in state saving code when an abort queue processing event
is pending.
- Fix a bug where a net could be twice in the queue.
- Convert more macros to c++
- fixed SUBTARGET=nl build
- fixed potential bugs which would allow a terminal to belong to more
than one net. This is not possible even for a short time.
- moved some member function definitions out-of-class.
- moved code out-of-class
- added constexpr where appropriate
- fixed mamenl build
- Cleanup and indentation
|
|
|
|
|
|
|
|
|
|
|
| |
- nltool: Added support for building individual static solver files.
- Added pre-built documentation files for nltool and nlwav.
- plib: Extended typed_version to have patchlevel as well.
- plib: Compile more of ppmf.h with nvcc.
- create_devinc.py: Add include guards to the generated files.
- makefile: Recreate generated files when python code has changed.
- Reduced nld_base.h usage in the core.
- <oved extern template class declarations to where they belong.
- Generally improved code readability and fixed a lot of issues cspell reported.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- More c++, less macros
* Significantly reduced the use of unused_var and replaced it with
[[maybe_unused]]
* use enum class in ppmf.h
- Changes to testing code in ptest.h
* Catch exceptions in more places
* The verbosity of the output can now be controlled
* Display of test stats totals
- added support for cspell
- fixed various typos
- fixed SUBTARGET=nl build
- fixed more file permissions
- srcclean and add fix_permissions target to netlist makefile
|
|
|
|
|
|
|
|
|
|
| |
copyright owners. Much thanks for that Couriersud, the main creator
and contributor, but also to Jonathan Gevaryahu and Sergey Svishchev.
There are small remnants in machine/NL_*, specifially breakout, pong
doubles and rebound that are also copyrighted by the DICE team,
whoever that means. They're not critical since they only concern
these drivers and not an important core subsystem.
|
|
|
|
| |
* where possible rely on forward declarations to optimiuze compile time.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Removed device and macro header files.
* All of those can be generated automatically so going forward there is
no need for these any longer.
* Introduced the modules concept. Modules are netlists for which
automatic lib entries are generated.
* Going forward you just store them in macro/modules and they will be
automatically registered as device elements.
* You need to do a "make generated" is src/lib/netlist/build
* Some_device.cpp still needs to be added to netlist.lua
* Added documentation on how to add devices to netlist.
* Please refer to adding_devices.md for more information.
|
|
|
|
|
|
|
|
|
|
|
| |
* rename some misleading type names
* remove callback_t and replace by better scalable approach
* hide implementations details
* move sources classes from putil.h to psources.h
* reduce code complexity
* improve parsing performance, parsing netlists now is twice as fast.
* fix issues around multi-byte string support
* moved psplit into pstrutil.h
|
|
|
|
|
| |
* also made nld_devinc.h srcclean friendly.
* nld_devinc.h and lib_entries.hxx are currently not used. You can try
the automated build by changing NL_AUTO_DEVICES in setup.h to 1.
|
|
|
|
|
| |
* Added TRUTHTABLE_ENTRY to netlist language.
* Please see nlm_ttl74xx for reference implementation.
|
| |
|
|
|
| |
* also raises error if during parsing a local source is not found.
|
|
|
| |
* preparational work for easier device addition.
|
|
|
|
| |
* Use a consistent naming scheme. This is a preparational step towards
improved parsing performance.
|
|
|
|
|
|
|
|
|
| |
* Separated tokenizing and reading of tokens.
* This enables caching of parsing results on the token level.
* Implemented caching of token stream.
* Overall this significantly improves parsing performance (~10x)
* Next step towards a bare-bone nltool which does not depend on macro
devices.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
* palloc.h/pmatrix2d.h: Fix static_assert warnings at the origin.
* Rework hints to broaden their use and fix NC hint.
* 74377: use NC hint
* plists.h: Fix debugging in MSVC
* Include cleanup: Move everything not needed by netlists from
nl_setup.h into core/setup.h
* Fix some clang tidy warnings
* srcclean
|
|
|
|
|
|
|
|
|
|
| |
* Logic and analogue outputs can now be flagged as "NC" (not connected).
* Example: "HINT(IC13.4, NC)".
* This will suppress info messages to be logged.
* The HINT must apply to an existing terminal. HINTs for non-existing
terminals are treated as fatal errors.
* Terminals and logic inputs not connected are still treated as
warnings. These need though and a proper fix.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Kidniki now achieves up to 910% when run with static solvers and with
nltool. That is significant better than the 860% we have seen
previously.
This increase is driven by using a global memory pool in the solver
code.
In addition the following refactoring and code maintenance work is
included. Please excuse the large commit, some of this took interfered
with other work and the detail development steps were ugly.
- gsl support: This commit adds pgsl.h which implements a very limited
number of the functionality of the gsl header described in the c++ core
guidelines.
- clang-tidy fixes
- A significant refactoring of palloc.h. Aligned hints were removed,
they added complexity without a significant performance gain. Vector
operations should better be done on special spans/views.
The code has been tested on linux with g++-7, g++-9, clang-11.
On Windows mingw-10 and VS2019, OSX clang-11.
|
|
|
|
|
| |
This change will make it a lot easier to add enhanced functionality to
the factory infrastructure.
Using integral constants also improves linking stability.
|
|
|
|
|
|
| |
During object creation netlist tracks the source files which provide
object creation. This is later used e.g. by nltool to create
documentation from source.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- working macro level parameters
- simplified code significantly
- fixed a number of hidden issue
- dead code removal
It is now possible to define netlist level parameters using:
static NETLIST_START(chip)
DEFPARAM(parameter, 123)
RES(R1, $(@.parameter))
....
NETLIST_END()
NETLIST_START(main)
chip(X1)
PARAM(X1.parameter, 1000)
...
NETLIST_END()
This will pass on 1000 to R1 as a parameter.
"@." will resolve to the current namespace. In this case it is X1, thus
"X1.parameter. This is during parsing. During evalution, i.e. device
creation, $(X1.parameter) is evaluated to 1000.
This also means, that global parameters are possible and accessible ...
DEFPARAM(P, 234)
...
RES(R1, $(P))
or going forward
RES(R1, 1000)
CAP(C1, 1.0 / $(R1.R))
This opens up the path to more possibilities ...
static NETLIST_START(DM9456_DIP)
DEFPARAM(MODEL, "74XX")
DM9456_GATE(X1)
DM9456_GATE(X2)
PARAM(X1.MODEL, $(@.MODEL))
PARAM(X2.MODEL, $(@.MODEL))
...
NETLIST_END()
NETLIST_START(main)
DM9456_DIP(X1)
PARAM(X1.MODEL, "LS74XX")
...
NETLIST_END()
The code also has been prepared to allow something along the lines of
LIBENTRY_MODEL(DM74LS00_DIP, DM7400_DIP, "LS74XX")
to define a LS version on top of an DM7400_DIP bare TTL implementation.
This however will need more efforts to existing devices to honour some
timing adjustment in the model definition. It will already honour
different output specifications between LS series and bare TTL if
connected to analog components.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Parameters are now passed to the netlist core as strings. During netlist
creation they are evaluated as functions. This opens the path to
parameters on subdevice level.
Examples:
PARAM(device.XY, (1+2*0.005))
RES(R1, 2.05*RES_K(1)+1)
In addition the commit contains dead code removal.
|
|
|
|
|
|
|
|
|
| |
- Fixed some clang lint warnings
- Removed dead code
- Experimental parser code to allow calculations in parameter value.
This already works for compiled netlists. These changes are
currently disabled. Updated pong netlist (and CRC/SHA) to work
with this new code.
|
| |
|
|
|
|
|
|
| |
- remove pthrow trampline as proposed by Vas.
- identify throwing code by adding noexcept(false)
- move "connected term" information to setup code.
- srcclean
|
|
|
|
|
|
| |
- refactor error messages.
- Fix some drivers to cope with outputted added my the mame driver
for video and sound.
- Fix validation.
|
|
|
|
|
|
|
| |
- Fix automatic header generation
- clang lint fixes.
- srcclean
- remove dead code
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit is a first step towards using formulas in parameters, i.e.
MAINCLOCK(clock, 20 * 30)
The intention is to improve readability and scalability.
Since device registration already provides all necessary information
about parameters, the code to create an include file for all
devices has been improved. Long term, this will remove the need for
device specific header files.
In addition going forward devices will accept either no connections or
all specified connections, i.e.
TTL_7400_NAND(name, chip1.2, chip2.3)
or
TTL_7400_NAND(name)
NET_C(...)
NET_C(...)
This will allow to remove all duplicate definitions which are currently
necessary, i.e. TTL_7400_NAND/TTL_7400_GATE
|
|
|
|
|
|
|
| |
- comment style migration continues.
- Fixed a two bugs in the truthtable ignore inputs code
- refactored the truthtable code a bit for better readability.
- updated netlist specific gitignore.
|
|
|
|
|
| |
- switch to VS 2019 community and fix standalone build.
- more migration to C++ comment style.
- add some more doxygen markup.
|
|
|
|
| |
Still not optimal, but better than what we had previously. No exception
logging comes closer.
|
|
|
|
|
|
|
|
| |
- more const
- explicitly raise exceptions instead of leaving this to log.fatal()
- correct a number of cppcheck findings.
- dead code removal
- clang lint corrections, e.g. include order
|
|
|
|
|
|
|
| |
Renamed cast member of the constants struct to magic to clearly identify
magic numbers.
Introduced nlconst struct inheriting from plib::constants<nl_fptype> to
make code better understandable.
|
|
|
|
|
|
|
|
|
| |
The newly added RELTOL and VNTOL parameters implement Newton convergence
checks comparable following other SPICE implementations.
The ACCURACY solver parameter now is only used for convergence checks in
iterative solvers.
In addition, type safety was significantly improved and a lot of "magic"
numbers are identifiable now.
|
|
|
|
|
|
|
| |
- solver: align matrix population along the various solvers
- solver: delete dead code
- renamed nl_double to nl_fptype and use nl_fptype where previously
double has been used.
- renamed param_double_t to param_fp_t
|
|
|
|
|
|
|
|
| |
- Removed code no longer used
- Add noexcept where appropriate
- split pparser.[c|h] into ppreprocessor and ptokenizer
- smaller optimizations, e.g. use of std::size_t
- fix lint warnings
|
|
|
|
|
|
|
|
|
|
| |
The builtin preprocessor now behaves closer to cpp:
- supports macro parameters, i.e. define x(a) a
- supports stringification, i.e. define x(a) #a
- supports concatenation, i.e. define x(a) a ## _ext
In addition, error reporting now provides a source context including the
include history.
|
|
|
|
|
|
| |
- moved netlists out of driver code into audio/ or machine/ as
nl_xxx.cpp files.
- identified and documented extended validation
- updated arcade, mess and nl targets
|
|
|
|
| |
- clang lint and pedantic fixes
- mat_cr.h: separate solving linear systems from underlying matrix
|
| |
|
|
|
|
| |
- fixed lint corrections
- added NOLINT where needed
|
|
|
|
| |
All pstonum calls now need to specify if they want local locale
or the "classic" "C" locale.
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes an over simplification. Logic devices implicitly assumed that
GND/VDD actually is connected to GND(i.e. 0V). There is no immediate
benefit from this change. It is a preparation for the future
scalability. Now all power terminals (typically 7/14, 8/16) have to be
explicitly connected to the supply rails.
Also added a validation mode to the netlist core. This is not
intended for running, but solely to better indentify pins which
are not properly connected.
|
|
|
| |
This approach uses functors for logging messages.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This effectively reverts b380514764cf857469bae61c11143a19f79a74c5 and
c24473ddff715ecec2e258a6eb38960cf8c8e98e, restoring the state at
598cd5227223c3b04ca31f0dbc1981256d9ea3ff.
Before pushing, please check that what you're about to push is sane.
Check your local commit log and ensure there isn't anything out-of-place
before pushing to mainline. When things like this happen, it wastes
everyone's time. I really don't need this in a week when real work⢠is
busting my balls and I'm behind where I want to be with preparing for
MAME release.
|
|
|
|
|
| |
This reverts commit c24473ddff715ecec2e258a6eb38960cf8c8e98e, reversing
changes made to 009cba4fb8102102168ef32870892438327f3705.
|
| |
|