summaryrefslogtreecommitdiffstatshomepage
path: root/src/lib/netlist/nltypes.h (follow)
Commit message (Collapse)AuthorAgeFilesLines
* netlist: include file work (#10096) couriersud2022-07-161-55/+15
| | | | | | - move code to more appropriate locations - apply clang-format to modified files - fixed some cspell errors - Applied emu.h rule.
* netlist: gtrak10 performance and other improvements and fixes (#10032) couriersud2022-07-051-20/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | - 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 (#9947) couriersud2022-06-201-56/+105
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 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: static solver work and improve code readability (#9841) couriersud2022-05-301-4/+9
| | | | | | | | | | | - 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.
* netlist: palloc now uses c++17 alignment aware operator new. (#9834) couriersud2022-05-271-3/+3
| | | | | | | | | - Added more documentation to palloc.h - Made the use of allocation arenas more transparent throughout code - palloc now uses c++17 alignment aware operator new. This required further changes to the arena_deleter object to track alignment and size of allocated objects to avoid the use of alignment and size of base classes in case a unique_ptr was cast to a unique_ptr of the base class.
* netlist: Address comments from PR #9794, partially fix issue #9801 (#9805) couriersud2022-05-231-1/+1
| | | | | - added cstddef to includes in ppmf.h - more explicit comments in ppmf.h - Fixed more typos and improved readiability
* netlist: More c++, less macros, added support for cspell (#9794) couriersud2022-05-221-2/+1
| | | | | | | | | | | | | | | | | - 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
* netlist: Improved PPMF target support and test coverage. (#9752) couriersud2022-05-151-3/+3
| | | | | | | | | | This addresses most of the issues described in #8590. * Fixed standalone Visual Studio 2019 builds, including support for clang toolchain. * Added static stub to PMF to support MSVC ABI. * Better aligned ppmf syntax with MAME's delegate syntax. * Add tests/test_ppmf*.cpp testing examples given in #8590. Also worked around issues some versions of Apple clang have with 5aaae19230bd39dda6766641672f57276a3f9ea1.
* netlist: more c++, less macros (#9706) couriersud2022-05-071-2/+2
| | | | - Reduce the use of macros by converting defines into c++ constants. - more minor code clean up.
* netlist: Relicensing of the GPL code to BSD-3 with the blessing of the Olivier Galibert2021-03-091-1/+1
| | | | | | | | | | 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.
* netlist: code refactoring couriersud2020-09-241-9/+9
| | | | | | * use default move and copy constructors * various minor edits like adding noexcept * removed a lot of inline keywords - you can't beat the compiler
* netlist: optimize headers. couriersud2020-09-171-16/+0
| | | | * where possible rely on forward declarations to optimiuze compile time.
* netlist: code maintenance and performance optimizations. Couriersud2020-09-051-31/+2
| | | | | | | | | | | * 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
* netlist: Fix various issues around include directories. couriersud2020-08-251-1/+1
| | | | | | | | | * removed include directory src/lib/netlist from various genie files to avoid potential issues. * Code using netlist should use #include "netlist/*". * Updated includes. * Fixed standalone makefile depend target to properly deal with relative paths.
* netlist: templatize 74107 and code maintenance. couriersud2020-08-231-4/+4
| | | | * removed some dead friend declarations * optimized template times_ns2
* netlist: further nl_base.h splitting into headers in core subdir. couriersud2020-07-281-2/+29
|
* netlist: separate nl_base.h into separate header files. couriersud2020-07-251-1/+19
| | | | | | * This clean-up exercise will hopefully make it easier to navigate the core code. Another long term goal is to further straighten the object model.
* netlist: code maintenance and bug fixes. couriersud2020-07-011-2/+5
| | | | | | | | | | | * 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
* netlist: include file refactoring. couriersud2020-06-281-9/+84
| | | | | | | | The purpose of this ongoing exercise is to remove unnecessary dependencies in header files. netlist implementations should only have access to what they need. The same applies to device implementations. Core stuff will be moved to the core subdirectory going forward.
* netlist: Performance improvement and refactoring. [Couriersud] couriersud2020-06-131-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | 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.
* netlist: Make fostrm actually write to file. (nw) couriersud2020-06-131-1/+1
| | | | Also fix typos and a tidy warning.
* netlist: allow selection of base arena for pmempool_arena. (nw) couriersud2020-06-081-1/+3
|
* netlist: arena code maintenance. (nw) couriersud2020-06-081-6/+1
|
* netlist: code maintenance. (nw) couriersud2020-06-081-23/+14
| | | | | | - more c++14, use enable_if_t instead of enable_if - cleaned up the use of memory allocation arenas - reduce MACRO usage, use std::conditional where possible
* netlist: remove more macro usage, fix win float exceptions. (nw) couriersud2020-06-061-6/+2
|
* netlist: code maintenance. (nw) couriersud2020-05-251-1/+1
|
* netlist: move configuration entries into netlist namespace. (nw) couriersud2020-05-251-5/+3
|
* netlist: improve performance. [Couriersud] couriersud2020-05-241-1/+0
| | | | | | | pongf now peaks at 589% compared to 570% before. Amongst a number of improvements in nl_base.h, the 7493 was touched. Also has some code cleanup and hopefully faster compilation due to extern template declarations.
* netlist: various clang-tidy-11 fixes. (nw) couriersud2020-05-241-1/+1
|
* netlist: Fix performance issues and VC2019. [Couriersud] couriersud2020-05-221-14/+0
| | | | | | For reasons unknown to me compile optimizations do not behave for template code. If the implementation is in separate compile units, the code compiles and performs.
* netlist: consolidate 9316-type counters. [Couriersud] couriersud2020-05-221-1/+18
| | | | | | | This needs more attention since for certain compilers there is a considerable performance degregation. It looks like this is only triggered if too many variants are declared in one cpp file and the compiler stops inlining.
* netlist: Add tristate support for rom devices. [Couriersud] couriersud2020-05-201-2/+2
| | | | | | | | | Rom and prom devices now properly support tristate outputs. Native OC output still on the todo list. In addition this commit fixes a number of bugs around dealing with macro level parameters and improves documentation by adding a parameter table. Also srcclean.
* netlist: improve syntax of generic device descriptors. (nw) couriersud2020-05-201-40/+43
|
* netlist: Add working 74125 and 74126 implementations. [Couriersud] couriersud2020-05-171-0/+50
| | | | | | | | | | | These tristate buffers natively support tristate outputs. For use cases with fixed enable inputs the devices support a parameter FORCE_TRISTATE_LOGIC which if being set to 1 makes the device behave like a logic output. Added additional syntax and consistency checks for tristate outputs. Updated the example and added dip implementations including documentation.
* netlist: Restructered the save state system. (nw) couriersud2020-05-041-8/+0
| | | | | | | | | | | | | | | This change makes state saving contract based. Objects which need to save state need to have the following template member: template <typename ST> void save_state(ST &st) { /* Example */ st.save_item(m_p, "m_p"); st.save_item(m_buf, "m_buf"); } This member function is called when the object is passed to the state manager save function.
* netlist: Fix some tidy warnings. (nw) couriersud2020-05-031-4/+7
| | | moving over to clang-tidy-11 and enabling more warnings.
* netlist: more magic number removal. (nw) couriersud2020-05-011-0/+18
|
* netlist: Removed more magic numbers from the code. (nw) couriersud2020-05-011-2/+3
|
* netlist: Fix clang-tidy warnings. (nw) couriersud2020-04-281-2/+16
|
* netlist: rename some macros. (nw) couriersud2020-04-261-1/+1
| | | Rename COPYASSIGN* and friends to PCOPYASSIGN*.
* netlist: clang-tidy, srcclean and pedantic warnings fixed. (nw) couriersud2020-04-181-1/+1
|
* netlist: Fix a macro expansion bug. (nw) couriersud2020-04-181-0/+5
|
* netlist: improve performance up to 65% on audio netlists. [Couriersud] couriersud2020-04-131-0/+4
| | | | | | | | | | | | | | | | | | | This commit introduces precompiled static solver code. Due to additional optimizations the compiler can use because the detail calculation steps for the solution are known e.g. the kidniki netlist sees a 100% speed increase. In all environments (windows/*nix/osx) the source for the static solver code can be created using bash src/lib/netlist/nl_create_mame_solvers.sh This will create src/lib/netlist/generated/static_solvers.cpp which is compiled into the mame binary. The script is just a temporary workaround. The intention is that nltool whill be able to create this file with one call. There are other improvements in this commit speeding up the processing of timestep and dynamic calculations.
* netlist: Fix some clang-tidy-10 warnings. (nw) couriersud2020-04-051-2/+2
|
* netlist: clang lint readability fixes. (nw) couriersud2020-01-251-4/+4
|
* netlist: Fix building with 128bit integers. (nw) couriersud2020-01-161-1/+1
|
* netlist: Code maintenance. (nw) couriersud2020-01-121-1/+4
| | | | | | | | | Introduce an additional absolute time type netlist_time_ext to identify whether absolute or relative time is used in the netlist code. Extend ptime code to allow operations between ptime derived types with different internal types. In addition rewrote main queue serve loops. Adds a very small performance increase.
* netlist: code maintenance. (nw) couriersud2019-11-131-6/+0
| | | | | | - move memory pool to netlist_state_t removing one static allocation. - add memory allocation stats to verbose output - nl_assert no longer throws, first step to remove NL_EXCEPT macro.
* netlist: code maintenance and bug fixes. (nw) couriersud2019-11-081-5/+5
| | | | | | | - 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.
* netlist: maintenance. (nw) couriersud2019-11-081-45/+38
| | | | | - switch to VS 2019 community and fix standalone build. - more migration to C++ comment style. - add some more doxygen markup.