summaryrefslogtreecommitdiffstatshomepage
path: root/src/lib/netlist/nl_setup.cpp
Commit message (Collapse)AuthorAgeFilesLines
* netlist: Removed more magic numbers from the code. (nw) couriersud2020-05-011-1/+1
|
* netlist: more code maintenance. (nw) couriersud2020-04-281-12/+2
| | | | | | | Make some calls private which were public before. Eliminate functions which would be executed only once. Make terminal reference functions in twoterm.h return const. Clearly identify the use cases which need a non-const ref to terminals.
* netlist: improve const-awareness and tidy changes. (nw) couriersud2020-04-281-17/+17
| | | | Identified a number of code locations which could accept const arguments.
* netlist: More clang-tidy fixes. (nw) couriersud2020-04-281-12/+12
|
* netlist: Fix clang-tidy warnings. (nw) couriersud2020-04-281-27/+26
|
* netlist: improve readability. (nw) couriersud2020-04-251-1/+1
| | | | The purpose here is to make clear what is actually done and to reduce usage of calls to update.
* netlist: Fix a segfault happening only under for certain netlists. couriersud2020-04-221-3/+46
| | | This seems to be a compiler/standard library issues.
* netlist: rename some camel case names. (nw) couriersud2020-04-191-12/+12
|
* netlist: clang-tidy, srcclean and pedantic warnings fixed. (nw) couriersud2020-04-181-2/+2
|
* netlist: Reduce memory allocation calls in non-core code. (nw) couriersud2020-04-101-3/+3
|
* netlist: Fix some clang-tidy-10 warnings. (nw) couriersud2020-04-051-14/+14
|
* netlist: fix log file option in nltool. (nw) couriersud2020-02-171-16/+17
|
* netlist: Code symplification and bugfixes. (nw) couriersud2020-01-311-4/+4
| | | | | - Fixes performance regression and net_splitter struct. - Fixes nltool time measurements - pstream simplification
* netlist: Parameters evaluated when netlist is created. [Couriersud] couriersud2020-01-291-9/+12
| | | | | | | | | | | | 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.
* netlist: Code maintenance. (nw) couriersud2020-01-271-1/+0
| | | | | | | | | - 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.
* netlist: clang lint readability fixes. (nw) couriersud2020-01-251-98/+76
|
* netlist: code maintenance. (nw) couriersud2020-01-201-41/+47
| | | | | | - remove pthrow trampline as proposed by Vas. - identify throwing code by adding noexcept(false) - move "connected term" information to setup code. - srcclean
* netlist: more code maintenance. (nw) couriersud2019-11-161-1/+0
| | | | | | - refactor error messages. - Fix some drivers to cope with outputted added my the mame driver for video and sound. - Fix validation.
* netlist: maintenance and bug fixes, remove DUMMY_INPUT. [Couriersud] couriersud2019-11-151-15/+15
| | | | | | | | | | - Removed DUMMY_INPUT. NC (not connected) pins should now use NC_PIN. If a NC_PIN is actually connected, an error will be logged and validation will fail. - Enabled "extended" validation. This will catch now if power terminals are not connected. - Added const and noexcept where appropriate. - Removed dead code. - Fixed the 7414 Schmitt-Trigger device to use nld_power_pins
* netlist: Proxy and power terminal hack removal. [Couriersud] couriersud2019-11-141-25/+36
| | | | | | | | | | | | | | | | | | - Devices ttlhigh and ttlhow are no longer automatically created. - All logic input devices (e.g. TTL_INPUT, LOGIC_INPUT) now need to have their power terminals (VCC, GND) connected. This opens the route for more appropriate proxy devices but comes at a cost. If the connections are omitted your circuit will not work as expected. Example: LOGIC_INPUT(I_SD0, 1, "AY8910PORT") NET_C(VCC, I_SD0.VCC) NET_C(GND, I_SD0.GND) - Updated all netlists. - Removed proxy information from terminal objects. This was replaced by a lookup hash whose life-span does not exceed netlest setup. These changes enable the removal of a number of hacks from the source going forward.
* netlist: bug fix, code maintenance and performance improvement. (nw) couriersud2019-11-131-1/+2
| | | | | | | | | - fixed a code in the netlist creation which caused multiple proxies to be created for output->terminal connections. A nice side effect of this fix is a performance increase ~9% for kidniki and ~4% for pong. Speaking about pong ... maximum is 490%. Dice is running at 280 FPS/60 FPS = 466%, however without any analog emulation. - Replaced NL_NOEXCEPT with noexcept. assert is now exception-free. - cppcheck and lint fixes.
* netlist: code maintenance. (nw) couriersud2019-11-131-6/+6
| | | | | | - 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: maintenance. (nw) couriersud2019-11-111-3/+8
| | | | | | | - Fix automatic header generation - clang lint fixes. - srcclean - remove dead code
* netlist: first steps on the way to calculated parameters. [Couriersud] couriersud2019-11-101-1/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | 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
* netlist: code maintenance and bug fixes. (nw) couriersud2019-11-081-2/+2
| | | | | | | - 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-22/+18
| | | | | - switch to VS 2019 community and fix standalone build. - more migration to C++ comment style. - add some more doxygen markup.
* netlist: more consistent exception handling. (nw) couriersud2019-11-051-10/+10
| | | | Still not optimal, but better than what we had previously. No exception logging comes closer.
* netlist: code maintenance. (nw) couriersud2019-11-041-17/+76
| | | | | | | | - 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
* netlist: code maintenance. (nw) couriersud2019-11-031-2/+0
| | | | | | - Separate code out into pmath.h and pstonum.h. - Fix VC build error - optimize pfmtlog.h a bit
* netlist: Completed __float128 support. [Couriersud] couriersud2019-11-031-3/+3
| | | | | | Both compiling the core and the shaders with __float128 now work. The support was added to be ready to deal with academic edge cases. Performance drops to 10% of double - thus disabled by default.
* netlist: improve readability. (nw) couriersud2019-11-021-14/+14
| | | | | | | 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.
* netlist: add RELTOL/VNTOL solver parameters. Type safety. [Couriersud] couriersud2019-11-021-12/+14
| | | | | | | | | 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.
* netlist: code maintenance and bugfixes. (nw) couriersud2019-11-011-1/+1
| | | | - fixed a bug in the parray constructor - replaced NL_NOEXCEPT with noexcept where appropriate
* netlist: maintenance and simplifcation. (nw) couriersud2019-10-311-8/+8
| | | | | | | - 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
* netlist: code maintenance. (nw) couriersud2019-10-291-3/+3
| | | | | | | | - 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
* Netlist: code maintenance and improvements. [Couriersud] couriersud2019-10-181-37/+29
| | | | | | | | - Added support for line markers to the preprocessor and parser. - Added support for include processing to the preprocessor. - Moved sources base type to plib to be used for preprocessor includes. This enables to include e.g. from rom memory regions. - Renamed some defines
* Netlist: pongf update and code maintenance. [Couriersud] couriersud2019-10-161-1/+4
| | | | | After the recent string of updates pongf performance increased again. Also includes code maintenance and some fixes for the aligned memory operations.
* netlist: Use unique_ptr where possible. (nw) couriersud2019-10-151-16/+15
| | | Also improve code readability.
* netlist: maintenance and lint fixes. (nw) couriersud2019-10-061-5/+5
|
* netlist: more lint corrections. (nw) couriersud2019-09-281-1/+1
| | | | - fixed lint corrections - added NOLINT where needed
* netlist: Fix a number of minor issues. (nw) couriersud2019-09-271-3/+4
| | | | | - lint warnings - remove const on return types
* netlist: switch to c++ streams. (nw) couriersud2019-09-251-11/+16
| | | | Removed the home-brew implementation pstreams and replaced those with c++ streams.
* netlist code maintenance (nw) couriersud2019-09-211-9/+12
| | | | | - prepare move to c++ streams and later std::string - fix more lint and clang pedantic warnings/errors - fix some bugs
* netlist code maintenance. (nw) couriersud2019-09-171-2/+2
| | | | | | - remove a lot of c library use and instead use c++ - improved pstring compatibility to std::string - prepare removal of pstream
* netlist: code maintenance Couriersud2019-04-281-2/+2
| | | | | | | | - converted NL_MAX_LINK_RESOLVE_LOOPS into a netlist parameter. - Reduced potential bit-rot. - nltool -v --version now displays values of all compile time defines. There are still far too many compile time defines. However, most of them ensure and test future scalability.
* netlist: Fix MT06827. couriersud2019-04-221-2/+2
| | | | All pstonum calls now need to specify if they want local locale or the "classic" "C" locale.
* netlist: fix some error/warnings. (nw) couriersud2019-04-221-3/+8
|
* netlist: lint and pedantic warning fixes. (nw) couriersud2019-04-221-3/+3
|
* netlist: Add more validations and fix issues identified. couriersud2019-04-211-6/+16
|
* netlist: Add power terminals to most logic devices. couriersud2019-04-211-15/+38
| | | | | | | | | | | | 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.