Commit Graph

2787 Commits

Author SHA1 Message Date
AmatCoder
ae3915fd53
tzx_cas.cpp: Apply 1ms pause only on data blocks
Fix MT #07296
2019-04-21 17:37:24 +02:00
couriersud
b806be41b2 netlist: use A,B,C,... for packaged components. 2019-04-21 13:37:15 +02:00
couriersud
7adbce9b66 netlist: bug fixes and nltool validation.
nltool now supports a validate command which acts similar to MAME's
validation.
2019-04-21 12:05:44 +02:00
couriersud
6b96f7ba60 netlist: Add power terminals to most logic devices.
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.
2019-04-21 12:05:44 +02:00
couriersud
4f71e124d5 netlist: more structure for caches. (nw) 2019-04-21 12:05:43 +02:00
couriersud
e812e77567 netlist: srcclean (nw) 2019-04-18 01:24:36 +02:00
couriersud
6392b345e6 netlist: scalable error messages.
This approach uses functors for logging messages.
2019-04-18 01:18:01 +02:00
couriersud
bfa1dacd17 Fix validation crash. (nw) 2019-04-17 19:58:12 +02:00
couriersud
3afd712637 plib: mempool refactoring. (nw) 2019-04-17 19:58:11 +02:00
couriersud
e7652e14d6 netlist: Improve validation code.
Adjust warning levels and fix a number of topics identified.
2019-04-16 01:49:44 +02:00
couriersud
86f0b315b6 netlist: Add validation support to netlist device.
mame -validate now also checks all netlist devices. It does this
by constructing a temporary netlist.
This commit also fixes some memory leaks and a bad bug which
surfaced in validation.
2019-04-15 21:41:01 +02:00
couriersud
6ed04fe619 plib: fix crash when argument is missing. (nw) 2019-04-13 23:32:47 +02:00
couriersud
808ec55f33 zaccaria: Route speech and DAC through netlist filtering.
Also hook up all potentiometers so they can be adjusted from within the
MAME UI.
2019-04-13 18:30:29 +02:00
couriersud
d1602bd9f1 netlist: bug fixing.
- fix sound route dependency
- add "K" as a valid Kilo multiplier.
- Fix current source parameter update.
2019-04-13 18:30:28 +02:00
couriersud
106990d8c9 netlist: clang lint fixes and pedantic warning fixes. (nw) 2019-04-12 14:00:46 +02:00
couriersud
1c191433ee netlist: improved and fast LM3900 model.
LM3900 model 3 only has half the number of BJTs compared to model 1
but delivers comparable results for Money Money.
Model 3 follows the datasheet.
I left code for Model 0 and 2 in for educational reasons.
2019-04-12 00:44:23 +02:00
couriersud
a2316d063a netlist: Fix handling of current sources when converting SPICE nets. 2019-04-12 00:44:23 +02:00
couriersud
bd365f5eab Adjusted LM3900 model, fixed clipping in zaccaria. 2019-04-12 00:44:22 +02:00
couriersud
a4f59176e4 netlist: Add more SPICE elements to the conversion code. 2019-04-12 00:44:21 +02:00
couriersud
065f52438f netlist: LM3900
- Align LM3900 pin names with other opamps
- Add a better voltage clamping model
- Add high precision model (disabled due to performance)
2019-04-12 00:44:20 +02:00
Joakim Larsson Edstrom
de63141b94 flopimg.h: implemented threshold to accept disk images with a few excess and empty tracks at the end used by HFE and DSK loaders for now 2019-04-11 22:14:30 +02:00
Vas Crabb
f70f31731c (nw) suppress side effects, standardise #include guards 2019-04-12 01:49:57 +10:00
couriersud
c6eebfaa0a netlist: Add LM2902, code refactoring. (nw) 2019-04-07 19:12:51 +02:00
couriersud
58e6383ada netlist: MB3614 again, function controlled VARCLOCK and other
improvements.

- fix MB3614 parameter
- Added VARCLOCK which derives step size from function
- optimized function handling in CS and VS
- fixed a bug in ppreprocessor
- add trunc to pfunction
- added opamp_amplification_curve to derive characteristic
  amplification curve
2019-04-07 19:09:48 +02:00
couriersud
140dc2237e netlist: TYPE=2 opamp model and MB3614 fixes.
- Untie diode code
- Fix some typos
- add TYPE=2 opamp model which omits output voltage limitation
  Useful for determining causes of non-convergence
- Fix MB3614 opamp parameters to match datasheet
2019-04-07 19:08:33 +02:00
couriersud
78bad5c87b netlist: indentation. (nw) 2019-03-31 22:34:08 +02:00
couriersud
db9caf8a9e Netlist: Move generic models into nld_generic_models. (nw) 2019-03-31 22:34:07 +02:00
couriersud
3320ae1f73 netlist: Refactored model code. (nw) 2019-03-31 22:34:06 +02:00
couriersud
980dbcc693 Netlist: Add global parameter to disable semi-conductor capacitance
modelling. [Couriersud]

Added global NETLIST.DEFAULT_MOS_CAPMODEL parameter. Setting this to
zero disables using capitance modelling in mos models.
On a per mos device basis this can be achieved by adding CAPMODEL=0 to
the model definition, e.g. MOSFET(X, "NMOS(CAPMODEL=0)")
Improve MOSFET convergence by using log-stepping.
2019-03-31 22:34:06 +02:00
couriersud
6d17870736 netlist: Timing bug fix. Affects regression tests. [Couriersud]
This fixes a rounding issue in the ptime code. This bug surfaced when I
tested netlist with picosecond resolution in ptime.
This will have a small impact on every driver using netlist. For
breakout, it required to adjust the color overlay.
2019-03-29 19:44:50 +01:00
couriersud
e4ff0d3322 netlist: Improved MOS transistor model. [Couriersud]
This is a significant improvement to the MOS transistor model. It adds
modelling of the Meyer capacitance model.
This is a somewhat academic addition since the effects occur on a
nanosecond time scale and have a huge impact on performance. I plan to
make the capacitance model selectable. Both on a model level as well as
by introducing a global solver parameter.
The model delivers comparable results to LTSpice.
2019-03-29 19:40:39 +01:00
Vas Crabb
97b6717027 (nw) Clean up the mess on master
This effectively reverts b380514764 and
c24473ddff, restoring the state at
598cd52272.

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.
2019-03-26 11:13:37 +11:00
andreasnaive
b380514764 Revert "conflict resolution (nw)"
This reverts commit c24473ddff, reversing
changes made to 009cba4fb8.
2019-03-25 23:13:40 +01:00
couriersud
39a7c420b1 netlist: add MOSFET model. [Couriersud]
- added MOSFET model. Currently capacitances are not modelled.
  This is a 3-pin model (Bulk connected to Source) with provisions to
  extend it to 4-pin at a later stage.
- Add a capacitor generic model which is charge conserving.
  Switch netlist to use this model instead of constant capacity model.
- Start putting constants into a central place.

Please expect minor timing differences due to a different numerical
path.
The cmos inverter example illustrates the analog implementation of a
cmos inverter gate. These were used a lot back in the 70s/80s to
generate sinus waves. The model should also be able to better emulate
4066 analog switches.
The addition of a relatively simple capacitor model is planned at a
later stage.
Expect everything from the MOSFET model at the current stage. Wrong
results as well as convergence issues and crashes.
2019-03-25 21:45:37 +01:00
Vas Crabb
30caaa7bef srcclean (nw) 2019-03-24 09:48:58 +11:00
Nigel Barnes
60e30e44b3 spectrum: Added the Opus Discovery disc system, and OPD floppy format. 2019-03-22 19:24:13 +00:00
ajrhacker
9e52e9cede
Merge pull request #4778 from AmatCoder/AmatCoder-dsk_dsk-1
dsk_dsk.cpp: Avoid segfault if double sided DSK image is loaded on si…
2019-03-19 18:08:40 -04:00
AmatCoder
66a4629631
dsk_dsk.cpp: Avoid segfault if double sided DSK image is loaded on simple sided disk device
MAME crashed if user was trying to load a dsk image with more heads or tracks than disk device supports.
Now the error 'Incompatible image format' is raised.
2019-03-19 21:00:13 +01:00
couriersud
deacff7ffa netlist: refactor model code. (nw) 2019-03-18 23:27:36 +01:00
couriersud
76b92133dd Fix indentation. (nw) 2019-03-18 00:10:47 +01:00
couriersud
9534a0233c netlist: improve readability. (nw) 2019-03-18 00:01:41 +01:00
couriersud
46762510c9 netlist: Added B-E and B-C capacitance to EB model. [Couriersud]
Despite the overhead - two devices more per transistor - this addition
significantly reduces computing time on switching conditions by reducing
the needed Newton-Raphson loops dramatically.
2019-03-17 23:42:08 +01:00
couriersud
43c6cad7dd netlist: Add UJT example for 2N6027. 2019-03-17 15:10:15 +01:00
couriersud
ed9c85904e Fix bug. (nw) 2019-03-17 15:10:14 +01:00
couriersud
0882868e11 netlist: Fix formatting bug. (nw) 2019-03-17 03:17:15 +01:00
couriersud
4b9f90c4a9 netlist: add MC1455P as device. (nw) 2019-03-17 00:48:40 +01:00
couriersud
804439399b netlist: Add output resistance to NE555.
This is a first-order approximation of the output driving stage. A logic
output with appropriate family may be better but would add more
complexity.
2019-03-17 00:05:08 +01:00
couriersud
d27b434ca9 netlist: fix bug in LOGIC_INPUT devices. (nw)
Now family parameter is actually used. Also fixed bugs in code using
this device.
gamemachine now creates sound at realistic pitch.
2019-03-16 22:25:12 +01:00
couriersud
a5d6b7c5b8 gamemachine: add netlist audio. [Couriersud] 2019-03-16 19:07:33 +01:00
couriersud
e80276bb23 New working machine
-----------
Rebound [DICE team, Couriersud]
2019-03-12 02:04:28 +01:00
Nigel Barnes
5511ce41e2 mtx: Added expansion bus with SDX floppy controller.
- 80 column card with SDX in CP/M mode.
- ROM/RAM banking fixed for CP/M, and MTX500 now correctly detected.
- Support for Type 03 and Type 07 .mfloppy images.
- Added alternate MTX2 romset (German).
- Keyboard ROM now selected in Configuration.
- Quickload .RUN files.
2019-03-10 17:23:39 +00:00
couriersud
78c9ef697b netlist: fix breakout paddle regression. (nw)
The interesting parts in datasheets are always those which are not
mentioned.
2019-03-10 14:15:14 +01:00
Couriersud
1a2af1a23e netlist: add reverse parameter to 3-pin-potentiometer. (nw) 2019-03-09 00:34:40 +01:00
Couriersud
b346dea279 netlist: fix reset bug in 555 device. (nw) 2019-03-09 00:33:49 +01:00
Couriersud
07485fd7eb netlist: fix bugs in object initialization order. (nw) 2019-03-06 23:45:20 +01:00
couriersud
83a0e93837 netlist: remove printf. (nw) 2019-03-02 13:11:37 +01:00
couriersud
618f33f586 netlist: refactoring. (nw) 2019-03-01 19:52:19 +01:00
couriersud
17fcc38a25 netlist: memory code refactoring. (nw) 2019-03-01 10:30:24 +01:00
couriersud
2b49e6ed11 netlist: clang tidy. (nw) 2019-03-01 07:48:01 +01:00
couriersud
20551e42a7 Netlist: improve readability. (nw) 2019-03-01 07:48:01 +01:00
couriersud
893e676387 netlist: cosmetic changes - mostly indentation. (nw) 2019-03-01 07:48:00 +01:00
couriersud
d00de16b41 netlist: analog readability refactoring. (nw)
Change the sign of go (or in other terms a12 and a21 matrix stencil
elements). This should make further optimization of matrix population
easier.
In addition hopefully improve the readability of the code by sacrifying
overloads for more verbose member names.
2019-02-25 22:11:04 +01:00
couriersud
6a3efe52d6 netlist: fix bugs in the alignment code. (nw) 2019-02-25 21:17:59 +01:00
couriersud
2e055aa97b netlist: tidy changes and better constexpr support for ptime class. (nw) 2019-02-24 18:45:16 +01:00
couriersud
0e07f9ac34 netlist: more alignment related refactoring. (nw) 2019-02-24 18:45:16 +01:00
couriersud
a7a8186283 Move fillmatrix to to matrix solver base class. (nw) 2019-02-24 18:45:15 +01:00
couriersud
89e0f698b6 Prepare further optimization. (nw) 2019-02-24 18:41:42 +01:00
Vas Crabb
0ed2d2684e srcclean (nw) 2019-02-24 14:25:42 +11:00
couriersud
a65390cad5 netlist: Fix relative include paths and a conflict. (nw)
nl_types.h is part of libc++. Any project with a file with the same name
on the include path just fails to compile. Renamed to nltypes.h
2019-02-23 18:54:29 +01:00
couriersud
672f9b092a Move ptime struct into plib namespace and fix relative includes. (nw) 2019-02-23 18:54:27 +01:00
couriersud
0b3787d5f4 netlist: Fix some more exotic compile options. (nw)
128bit integers on kaby lake are not that much slower than 64bit. This
may be an option for MAME's attotime as well.
2019-02-23 16:24:01 +01:00
couriersud
f44bc8108c Fix indentation. (nw) 2019-02-22 22:06:05 +01:00
couriersud
66154af0f2 netlist: fix visibility issues and more issues reported by tidy. (nw) 2019-02-22 21:46:55 +01:00
couriersud
cf73ccc764 netlist: memory management. [Couriersud]
Memory management in plib is now alignment-aware. All allocations
respect c++11 alignas. Selected classes like parray and aligned_vector
also provide hints (__builtin_assume_aligned) to g++ and clang.
The alignment optimizations have little impact on the current use cases.
They only become effective on bigger data processing.
What has a measurable impact is memory pooling. This speeds up netlist
games like breakout and pong by about 5%.

Tested with linux, macosx and windows cross builds. All features are
disabled since I can not rule out they may temporarily break more exotic
builds.
2019-02-22 08:18:01 +01:00
couriersud
064050323e netlist: fix access specifiers. (nw) 2019-02-20 20:53:56 +01:00
couriersud
a5f3787058 netlist: fix a bug and some performance tweaks. (nw) 2019-02-20 20:16:08 +01:00
Vas Crabb
7983685096 (nw) clean up trivial stuff - the device delegate boilerplate is ugly, I will address it ASAP 2019-02-19 20:19:15 +11:00
couriersud
6207d7d2d3 netlist: tick off some issues clang-tidy highlights. (nw) 2019-02-18 20:22:16 +01:00
couriersud
17d784d83b netlist: remove locked-in context from sources. (nw) 2019-02-17 23:52:05 +01:00
couriersud
1fe9f5e2e5 netlist: refactoring startup process and array usage. (nw) 2019-02-17 18:30:34 +01:00
Vas Crabb
01ccbd89c9 (nw) remove some superfluous const, eliminate a superfluous temp, remove superflous semicolons, etc. and also fix a known broken build script change 2019-02-18 00:48:52 +11:00
couriersud
55000018e7 netlist: Separation of duties. (nw)
Make it clearer what is used during parsing a netlist, "compiling" a
netlist and execution of a netlist.
2019-02-16 14:31:59 +01:00
couriersud
b113d0c26d netlist: memory pool now supports aligned storage. (nw)
Set USE_MEMPOOL to 1 to try this (max 5% performance increase).

For mingw, there is no alignment support. This triggers -Wattribute
errors which due to -Werror crash the build.
2019-02-16 00:05:21 +01:00
couriersud
c5a513ca90 netlist: more memory allocation refactoring. (nw) 2019-02-14 01:16:39 +01:00
couriersud
aad01d572a netlist: indent. (nw) 2019-02-13 23:23:14 +01:00
couriersud
fb685c05b9 netlist: memory allocation clean-up. (nw) 2019-02-13 22:37:07 +01:00
couriersud
a905dffd08 netlist: More cpp core guidelines alignment. (nw) 2019-02-11 22:19:08 +01:00
couriersud
83bd138bec netlist: Fix crashes on certain hardware/library combos. (nw)
At least on macosx memory used by an object seems to be invalidated
before the dtor is executed. This of course is deadly for child objects
with references to the parent-in-deletion which may call back into the
parent.
One of the worst issues I had to fix. Ever. Lesson learnt: No tricks in
dtors. Never.
2019-02-09 23:07:27 +01:00
couriersud
9d8cb783e3 netlist: more core guidelines work. (nw) 2019-02-09 23:07:27 +01:00
AJR
50f185042f Fix clang build (nw) 2019-02-08 19:19:47 -05:00
couriersud
bd8bd7c4f1 netlist: added missing noexcept. (nw) 2019-02-09 00:32:31 +01:00
couriersud
5ea6e079f3 netlist: constants are now constexpr functions. (nw) 2019-02-09 00:21:14 +01:00
couriersud
8daa6e0a0d netlist: added parameter STARTUP_STRATEGY to switch between ...
startup strategies. This determines the order of device triggering.
0: Full - trigger all delegates. Next all devices not touched.
1: Backwards - trigger all devices backwards (only update delegate)
2: Forward - trigger all devices forward (only update delegate)
2019-02-08 23:18:48 +01:00
couriersud
8f94739f65 netlist: make constants struct members constexpr const. (nw)
- enable GCC diagnostics in vector ops for GCC 7 again
- Use forwarding in vector_ops
2019-02-08 23:18:47 +01:00
couriersud
f4c0f8c74b netlist: more cpp core guidelines work. (nw) 2019-02-08 23:18:47 +01:00
AJR
9807755a65 Awkward workaround for "undefined symbols" error caused by stupid non-inline constexpr semantics (nw) 2019-02-07 17:49:55 -05:00
couriersud
3b899b86e6 netlist: Refactoring after adding clang-tidy support to netlist makefile
- convert macros to c++ code.
- order of device creation should not depend on std lib.
- some state saving cleanup.
- added support for clang-tidy to makefile.
- modifications triggered by clang-tidy-9.
2019-02-07 21:54:11 +01:00
couriersud
6381ed11ed netlist: Optionally store input values instead of referencing them. (nw)
Useful for debugging purposes in the end - but not performance.

/*! Store input values in logic_terminal_t.
 *
 * Set to 1 to store values in logic_terminal_t instead of
 * accessing them indirectly by pointer from logic_net_t.
 * This approach is stricter and should identify bugs in
 * the netlist core faster.
 * By default it is disabled since it is not as fast as
 * the default approach.
 *
 */
#define USE_COPY_INSTEAD_OF_REFERENCE (0)
2019-02-05 18:31:14 +01:00
couriersud
6a7c3a8079 netlist: align solver calls. (nw) 2019-02-04 23:17:18 +01:00
couriersud
24e192fc86 netlist: Fix regression. (nw) 2019-02-04 20:38:59 +01:00
couriersud
759b7c3c88 netlist: Further simplification and optimization. (nw) 2019-02-04 19:36:02 +01:00
couriersud
c87a487d6d netlist: Refactoring and some functionality enhancements. (nw)
- Removed dead code.
- nltool now adds a define NLTOOL_VERSION. This can be tested in
  netlists. It is used in kidniki to ensure I stop committing
  debug parameters.
- Optimized the proposal for no-deactivate hints.
- Documented in breakout that hints were manually optimized.
- Minor optimizations in the order of 2% enhancement.
2019-02-04 00:27:23 +01:00
couriersud
f9f341f4d6 netlist: fix some issues. (nw) 2019-02-02 14:56:56 +01:00
couriersud
75146fd159 netlist: All devices now specify parameters in factory constructor. (nw)
This previously was part of net_lib.cpp and repeatedly caused bugs.
2019-02-01 22:46:43 +01:00
couriersud
b952577370 netlist: remove trampoline code. (nw) 2019-02-01 08:45:32 +01:00
couriersud
b4ba8dc552 netlist: code maintenance and fixing kidniki ... (nw)
to run at acceptable speed again.
2019-02-01 02:07:48 +01:00
couriersud
a80f10e1cf netlist: type safety for delegates. (nw) 2019-01-31 01:45:34 +01:00
couriersud
1513c777b4 netlist: Refactoring continues ... plus some innovations (nw)
Still some work ahead to separate interface from execution. This is a
preparation to switch to another sparse matrix format easily which may
be better suited for parallel processing.

On the linear algebra side there are some nice additions:

- Two additional sort modes: One tries to obtain a upper left identity
matrix, the other prefers a diagonal band matrix structure. Both deliver
slightly better performance than just sorting.
- Parallel execution analysis for Gaussian elimination and LU solve.
This determines which operations may be done independently.

All of this is not really useful right now. The matrix sizes are below
100 nets. I estimate that we at least need four times more so that CPU
parallel processing overhead pays off. For GPU, add another order. But
it's nice to have code which may scale.
2019-01-31 01:03:35 +01:00
Vas Crabb
76323eb770 srcclean and cleanup (nw) 2019-01-27 14:22:20 +11:00
AJR
212f26f759 Fix clang build (nw)
- src/lib/netlist/solver/mat_cr.h:143:32: error: call to 'abs' is ambiguous
- src/lib/netlist/solver/nld_ms_direct.h:62:19: error: non-type template argument evaluates to 18446744073709551488, which cannot be narrowed to type 'int' [-Wc++11-narrowing]
2019-01-26 18:32:16 -05:00
couriersud
32b0442c73 netlist: refactor code for better scalability and flexibility. (nw)
These changes aim to remove some of the duplication of code in the
various solvers.
Tested with gcc-7 clang-8 and nvcc-9.2
2019-01-27 00:01:51 +01:00
couriersud
26420facff netlist: add comment processing to preprocessor. [couriersud]
Comments are now processed in the preprocessor. Previously directives in
multiline comments were processed.
2019-01-20 22:18:07 +01:00
couriersud
83d558d096 netlist: nlwav now also converts log files to VCD format. [couriersud]
Please refer to nlwav --help for examples. There is also an example how
to create multi-channel wav files.
2019-01-20 18:29:27 +01:00
couriersud
c8e4dab20c netlist: Fix assertion. (nw) 2019-01-19 18:23:31 +01:00
couriersud
17d32e0bd5 netlist: pstream and ppreprocessor (now a pistream) refactoring. (nw) 2019-01-19 18:17:35 +01:00
Vas Crabb
9198c2bd58 More UI stuff:
* Split up the different parts of ICO loading in the menus (locating files, scaling, drawing, etc.)
* Added icon support to software selection menu
* Added support for more ICO file variants, including PNG-in-ICO (new DIB parser is overkill for ICO but I can factor it out for BMP loading at some point)
* Added favourites filter for software menus - includes software that's favourited on any system, so GBC includes DMG favourties and vice versa
* Eliminated unnecessary member variables and O(n) walks in software selection menu
* Made the menus' cached texture structures a bit more efficient
2019-01-19 17:34:43 +11:00
couriersud
30f063cd32 netlist: Remove const on return types and non-necessary ref-by. (nw) 2019-01-19 00:01:17 +01:00
couriersud
0bd20c8d14 netlist: add nvcc support to netlist makefile. (nw)
Also converted some by-ref calls to pass by value.
2019-01-18 10:23:04 +01:00
couriersud
a527525e52 netlist: More run/setup separation. (nw)
Still some distance ahead in properly separating execution and setup.
2019-01-18 00:58:45 +01:00
couriersud
c89439dd23 netlist: refactored netlist creation. (nw)
This is an effort to separate netlist creation from netlist execution.
The primary target is to avoid that code which will only run during
execution is able to call setup code and thus create ugly hacks.
2019-01-15 23:42:16 +01:00
couriersud
28bc5506be netlist: Code refactoring. (nw)
Replaced downcast with static_cast to avoid errors.
2019-01-14 23:32:51 +01:00
AJR
c816ca06f7 Fix clang error (in machine/netlist.cpp): 'netlist::netlist_t' is not polymorphic (nw) 2019-01-13 21:35:24 -05:00
couriersud
509132dd9c netlist: fix depend target. (nw) 2019-01-13 23:19:06 +01:00
couriersud
5a594cf069 netlist: Improve type safety for parameters. (nw) 2019-01-13 23:18:29 +01:00
couriersud
0a17d35c13 netlist: Fix logging during object construction. (nw) 2019-01-13 19:57:39 +01:00
AJR
1532d2078a hpi_dsk.cpp: Resolve unused variable warnings (nw) 2019-01-13 12:00:14 -05:00
R. Belmont
665eb5001c
Merge pull request #4501 from fulivi/hp9825_dev4
hp9825: added HLE of HP9885 floppy drive
2019-01-13 11:18:39 -05:00
Vas Crabb
3d84943f72 Make search not suck as badly (use algorithm derived from Jaro-Winkler similarity to match search strings, match on more useful stuff) 2019-01-14 00:44:46 +11:00
couriersud
9d7b4d0faa netlist: fix bug recently introduced and some refactoring. (nw) 2019-01-13 14:14:22 +01:00
couriersud
b57ceef133 netlist: Added && and || operators to preprocessor expressions. (nw) 2019-01-13 13:59:54 +01:00
couriersud
0a677239d7 Fix bug in GMRES solver. (nw) 2019-01-13 02:16:08 +01:00
couriersud
b04e13d142 Reenable LOG_STATS - issue fixed by smf 12 months ago is gone. (nw) 2019-01-13 01:38:59 +01:00
couriersud
9c7037d6c6 Replace ATTR_UNUSED by c++ template. (nw) 2019-01-13 01:01:43 +01:00
couriersud
633528eb31 Improve dealing ownership in pstreams. (nw)
I am not really happy with this. But I am missing some creativity
currently.
2019-01-13 00:08:47 +01:00
fulivi
c6dff30d7a hp9825: added HLE of HP9885 floppy drive. Extended HPI format to
handle single-sided disks.
2019-01-12 18:57:39 +01:00
couriersud
81af77b482 Move mainclock code from nl_base into header of nlid_system. (nw)
Also move some simple functions from nl_base.cpp into header.
2019-01-12 01:24:05 +01:00
couriersud
b91e3c3a6a Removed most inlines not necessary ... (nw)
On some I wasn't entirely sure :-(
Thanks Vas:
0f0e8853f3 (r31909683)
2019-01-12 00:35:08 +01:00
couriersud
f12f735f54 Fix clang-8 warnings. (nw) 2019-01-11 21:50:43 +01:00
couriersud
7ababd6091 Move NL_KEEP_STATISTICS from netlist_types to the individual use cases.
(nw)
2019-01-11 08:03:27 +01:00
AJR
328b8995a8 Fix clang error: extraneous template parameter list in template specialization [-Werror] (nw) 2019-01-10 17:26:51 -05:00
couriersud
107f4e4c6b Fix reset members. (nw) 2019-01-10 23:19:52 +01:00
couriersud
8611a7da2e Forgot this one. (nw) 2019-01-10 23:18:08 +01:00
couriersud
f73eca0c7f 5% performance improvement for breakout from a single device. (nw) 2019-01-10 23:18:08 +01:00
Stiletto
a5461d9d6b
2018 -> 2019 changes (nw)
* 2018 -> 2019 changes (nw)
2019-01-10 17:01:26 -05:00
couriersud
25390ce8c7 Fix stuntcyc regression. (nw) 2019-01-10 21:42:43 +01:00
couriersud
e8fed7f532 Refactoring and bug fixes. (nw) 2019-01-10 20:55:59 +01:00
couriersud
7079d0f5fe Move information where it belongs ... into the drivers. (nw) 2019-01-10 02:07:14 +01:00
couriersud
4213a396d8 Improve type safety on string->numeric conversions. (nw)
Also fixed an issue with 7497.

./nltool -t 5 -f src/mame/machine/nl_tp1983.cpp -v

now runs again.
2019-01-10 00:30:51 +01:00
couriersud
47347fe43e C++ and minor performance optimizations. (nw) 2019-01-09 18:16:17 +01:00
couriersud
8cc32269be Fixed tp1983 and 7497 and added 7497 dip version. (nw)
The schematic for the tp1983 contains an error. R19 is connected to GND.
This will never work since when Q goes low, the reset pulse will dead
lock Q to low. R19 needs to be connected to VCC (5V). This will generate
the proper, high-pass filtered pulse.

Further fixes for the 7497 as well.
2019-01-09 02:06:44 +01:00
couriersud
4f38e6cc54 Rewrote 7497 device. (nw)
The 7497 device should now work as described in the TI datasheet. This
datasheet contains an internal schematic with details on gates and D
flip flops used.
2019-01-08 02:38:57 +01:00
couriersud
bc732054f6 Fix netlist logs. (nw) 2019-01-08 02:22:24 +01:00
AJR
2a7fbbf7d7 Fix clang build [-Wc++11-narrowing] (nw)
This also adds an explicit type to the enum, so MSVC should be happy with this way as well.
2019-01-07 19:40:14 -05:00
R. Belmont
3b3172fec9
Merge pull request #4482 from peterferrie/master
fix MSVC (llvm toolset) compile (nw)
2019-01-07 16:13:08 -05:00
R. Belmont
43110c956e
Merge pull request #4487 from shattered/_1c5572b0c3
netlist wip: 7474, 7497, test driver
2019-01-07 16:12:35 -05:00
couriersud
0f0dcd161c Fix reset order for nets. (nw) 2019-01-07 22:11:21 +01:00
couriersud
f3d91f4898 Fix reported crash. (nw) 2019-01-07 22:11:21 +01:00
Sergey Svishchev
737093be1e netlist wip: 7474, 7497, test driver 2019-01-07 22:33:54 +03:00
Vas Crabb
ae6185e5f6 add C++ standard library headers for things that are used (nw) 2019-01-07 19:14:21 +11:00
Peter Ferrie
d199ec2657 fix MSVC (llvm toolset) compile (nw)
- conditionally uninitialised variables in PortAudio;
- floats passed to attotime;
- unsigned->signed enums (this one is technically still wrong)
2019-01-06 18:17:35 -08:00
couriersud
0f0e8853f3 Code maintenance and bug fixes. (nw)
Rewrote and simplified tiny bits. Fixed inappropriate use of
netlist_sig_t for non-boolean values.
2019-01-07 01:37:06 +01:00
couriersud
09553c51a4 Code maintenance. (nw) 2019-01-07 01:33:49 +01:00
couriersud
3c6d9ac9a0 Code maintenance and fix for "pure virtual call" error. (nw) 2019-01-06 20:04:39 +01:00
Robbbert
99479f6cd7 (nw) fixed compile error in netlist. 2019-01-07 00:38:34 +11:00
couriersud
1415421fd7 More c++ alignment. pstring now behaves like std::string. (nw)
This change removes all string extensions like trim, rpad, left, right,
... from pstring and replaces them by function templates.
This aligns a lot better with the intentions of the standard library.
2019-01-06 13:17:20 +01:00
couriersud
9a8d3c56ce Add gitignore to src/lib/netlist. (nw)
Also clean up doxygen genereated files in netlist makefile.
2019-01-02 16:26:13 +01:00
mooglyguy
94fbe66092 Fixed a few missing #includes flagged by VS2019 beta, nw 2018-12-30 13:24:16 +01:00
Vas Crabb
8ef80b186b (nw) So we're back to MSVC blowing up on non-trivial templates. Lovely.
Someone needs to get MS QA to put some non-trivial modern C++
compliation tests in the acceptance tests for their C++ compiler.  Maybe
MAME could even be a candidate.  Well, that might be a plan if MS still
had any QA.  At least this makes some lines shorter (at the cost of
needing more lines).
2018-12-30 17:34:49 +11:00
Dirk Best
b49825bf25 einstein: Software list items promoted to working: Theatre Europe
The existing disk image was replaced by a new one created from the
master disk.

dsk_dsk: Increase maximum cell count

This allows for slightly out of spec disk images to run, like Theatre
Europe on the Einstein.

[Lord Sméagol (Carl Lloyd-Parker)]
2018-12-29 00:58:48 +01:00
Vas Crabb
f1f0591f43 Start cleaning up palette configuration:
* Basically, initialisers go in the constructor arguments, and things for setting format go in set_format.
* Initialisation patterns can be specified with an enum discriminator or with a FUNC and optionally a tag.
* Formats can be specified with an enum discriminator or a size and function pointer.
* You must always supply the number of entries when setting the format.
* When initislising with a paletter initialisation member, you can specify the entries and indirecte entries together.
* The palette_device now has a standard constructor, so use .set_entries if you are specifying entry count with no format/initialisation.
* Also killed an overload on delegates that wasn't being useful.
2018-12-29 05:53:50 +11:00
arbee
7914a6083a Fix (unused) 3.5" head calc (nw) 2018-12-25 08:37:44 -05:00
arbee
5f049f185d Fix (currently unused) 3.5" track calc for WOZ2 (nw) 2018-12-24 15:11:59 -05:00
arbee
98050a1c0d apple2: Support the new version 2 .WOZ images [R. Belmont] 2018-12-23 21:07:50 -05:00
Celelibi
2f70f9698e Fix compilation errors with -Og
Signed-off-by: Celelibi <celelibi@gmail.com>
2018-12-11 14:26:30 +01:00
Vas Crabb
c2dc4316bd (nw) fix stuff:
* Add per-language compiler flag options to help with exotic setups
* Get rid of a potention buffer overrun in NuBus image card
* CHAR_WIDTH and LONG_WIDTH are preprocessor macros in limits.h with glibc if __GLIBC_USE (IEC_60559_BFP_EXT) is enabled - avoid using them as names
* Make formats/upd765_dsk.h slightly safer with defualt initialisers for key format members
* Don't rely on random BSS data being zero in imagedev/floppy.cpp
2018-11-29 14:10:27 +11:00
mooglyguy
13247311f6 Renamed flipendian -> swapendian, as I spent minutes trying to find the functions to tell to another person who spent minutes trying to find the functions, and we refer to such functions as swapping just about everywhere else in the codebase, nw 2018-11-05 19:11:18 +01:00
R. Belmont
a1c5fa9c2f
Merge pull request #4225 from AmatCoder/AmatCoder-dsk-patch-2
dsk_dsk.cpp: Avoid to use uninitialized booleans
2018-11-01 12:07:35 -04:00
AmatCoder
c42f784fe5
dsk_dsk.cpp: Avoid to use uninitialized booleans
Fix MameTesters #07134.
Thanks to Klez for testing.
2018-11-01 14:42:04 +01:00
Patrick Mackinlay
ece4404b69 util::fifo.queue_length() (nw)
Not 100% confident about the variable type, and there may still be some debate over the function name (trying to avoid confusion with the length of the container, or with the number of empty slots), so appreciate review/comments.
2018-10-18 17:50:50 +07:00
fulivi
830c3203f5 hp9825: added DC100 tape drive 2018-10-16 17:39:31 +02:00
AJR
fee7039a48 lib/util/options.cpp: Don't try to set the value of a header (nw) 2018-10-04 21:17:23 -04:00
mooglyguy
f522870d8a -options: Restored erroneously-removed game-specific INI option reversion between runs. Fixes MT#06171. [Ryan Holtz] 2018-10-05 01:20:04 +02:00
Vas Crabb
250c06a4d7 srcclean (nw) 2018-09-23 12:22:35 +10:00
Vas Crabb
b98658573b (nw) Fix inadvertently non-const pointers - emu.h edition
This fixes all the non-const pointers with static lifetime I could find
with a cheap grep (in combination with the last commit).  There are
likely more lurking that I didn't find, and things that aren't pointers
that should be made const.

There are still a few mutable static pointers that break the ability to
host multiple drivers but these require refactoring to fix:
src/devices/sound/sidvoice.cpp:static const uint8_t* waveform30;
src/devices/sound/sidvoice.cpp:static const uint8_t* waveform50;
src/devices/sound/sidvoice.cpp:static const uint8_t* waveform60;
src/devices/sound/sidvoice.cpp:static const uint8_t* waveform70;
src/mame/drivers/pockstat.cpp:	static const char *gme_id = "123-456-STD";
src/mame/machine/namco51.cpp:					static const game_driver *namcoio_51XX_driver = nullptr;
2018-09-20 14:32:59 +10:00
Vas Crabb
2993e850bb (nw) fix lots of inadverently mutable static pointers 2018-09-20 11:42:37 +10:00
Robert
7d58fbe09f
Merge pull request #4009 from AmatCoder/AmatCoder-fix-dsk
dsk_dsk.cpp: sectors must be read even if it contains deleted mark
2018-09-19 23:14:05 +10:00
AmatCoder
e07b1b467f
dsk_dsk.cpp: sectors must be read even if it contains Deleted Mark
FDC will read the data if SK bit is not set.

Fixes MameTesters bug #07081
2018-09-19 13:18:09 +02:00
Nigel Barnes
bcad4e9c09 bbcb: Added floppy disc controller options:-
- AMS 3" Microdrive Disc System
- Microware DDFS FDC (not working)
2018-09-17 19:18:38 +01:00
AmatCoder
745e8c0f0f
tzx_cass.cpp: 1ms pause is always required
Not only when pause from block is greater than zero .
Otherwise the last pulse is not terminated properly in some cases.
2018-09-16 07:20:34 +02:00
arbee
9dea8bbd37 chdcd: also accept .toast as a synonym for ISO images (nw) 2018-09-12 23:48:51 -04:00
mooglyguy
bb32d72c7e Fixed pmd85 regression, nw. Also replaced a fail-safe in src/lib/util/palette.cpp with an assert. Expect regressions, so better to get it out of the way now. nw 2018-08-30 23:40:37 +02:00
ajrhacker
d916d00911
Merge pull request #3795 from felipesanches/gtrak10_2018-jul-27
A large portion of the Atari Gran Trak 10 schematics (1974) implemented on MAME using the netlist subsystem.
2018-08-24 11:13:27 -04:00
balr0g
3f1b9ba8e9 imgtool: fix off by one error with leap years (nw) 2018-08-13 00:39:57 -04:00
AJR
ce99fccdb4 ti99_dsk.cpp: Change crc type to uint16_t here, too (nw) 2018-08-04 12:51:32 -04:00
AJR
7907b5afee ti99_dsk.cpp: More appropriate variable type which will hopefully make MSVC happy (nw) 2018-08-04 12:49:29 -04:00
Robbbert
9027827820 (nw) Fixed the build. 2018-08-04 09:02:37 +10:00
Michael Zapf
801935badb ti99: Fixed long-standing TDF bug; added support for 16-sector formats 2018-08-03 22:01:39 +02:00
Peter Ferrie
50830efb2a Merge branch 'master' of https://github.com/mamedev/mame 2018-07-29 21:54:08 -07:00
Peter Ferrie
83c4aa9f1e ap2_dsk.cpp: avoid one type of .woz corruption (nw) 2018-07-29 21:52:11 -07:00
Felipe Corrêa da Silva Sanches
e88ec6a7a5 A large portion of the Atari Gran Trak 10 schematics (1974)
implemented on MAME using the netlist subsystem.
2018-07-28 11:37:12 -03:00
AJR
c5a244d32c flopimg.h: Add debug asserts to help catch geometry errors (nw) 2018-07-28 00:54:54 -04:00
AJR
952bdf962a imd_dsk.cpp: Add some sanity checking on geometry 2018-07-27 23:43:03 -04:00
Vas Crabb
2968620098 make rectangle work better with constexpr, change many things to use designated getters/setters (nw) 2018-07-28 02:27:53 +10:00
Vas Crabb
9db24aa2e9 Better support for screen orientation/geometry:
* Eliminates the need for the horizontal/vertical/LCD/SVG layout files
* Screens can now have orientation and physical aspect ratio specified
* RASTER/VECTOR defaults to 4:3, LCD/SVG defaults to square pixels at config time
* System orientation is applied on top of screen orientation

Automatically generated single-screen views and orientation flags in XML
output now work correctly for systems with multiple screens in different
geometries/orientations, e.g. housemnq, rocnms, stepstag, or netmerc.

The "core rotation options" only interact with system orientation.
Allowing multi-screen systems to work well with one monitor per emulated
screen is a complex topic.  System orientation also affects the GFX
viewer while screen orientation doesn't.  The orientation displayed in
the system selection menu is from the system orientation.

Let me know if I've broken any systems or use cases.

Also, add save state support for std::array/C array nested to any depth.
2018-07-26 23:11:02 +10:00
Vas Crabb
dce955c68d rendlay: allow user variables and repetition in layouts, also add a few more predefined variables 2018-07-22 03:22:31 +10:00
Nigel Barnes
6ab094b76b camplynx_cas: Added support for multiple files (concatenated) in TAP file. 2018-07-16 21:19:55 +01:00
Nigel Barnes
e7da0b3a4b New machines marked as NOT_WORKING
----------------------------------
CMS 6502 Development System
2018-07-10 11:34:37 +01:00
Frank Palazzolo
ebc3f6947f Bug fix for multi-channel reads in cassette_get_samples(). (#3725)
* Bug fix for multi-channel reads in cassette_get_samples().
Use the unused "sample_bytes" arg the same way as cassette_put_samples()
Can be used with multi-channel files now!

* Rename sample_bytes to more descriptive sample_spacing
Add some comments about sample functions and sample_spacing variable
2018-07-09 05:28:18 +10:00
smf-
b747b711bb fix building with clang 6.0.1 (nw) 2018-07-07 11:28:01 +01:00
Olivier Galibert
a704ed7b1b emumem: Backend modernization [O. Galibert] 2018-06-29 20:04:28 +02:00
hap
2ce57abcf9 tzx_cas: no other copyright holders. initial version here:
5a0a43eb8f (diff-26e48bc5e5a1dc7272914d9f9cd3249d)
2018-06-26 13:08:29 +02:00
Vas Crabb
90d7b40e62 srcclean and other cleanup (nw) 2018-06-24 19:04:53 +10:00
Olivier Galibert
2b54bc0e04 Oops (nw) 2018-05-26 23:09:56 +02:00
Olivier Galibert
83a3b78fb3 Forgot the comment (nw) 2018-05-26 22:39:50 +02:00
Olivier Galibert
de919271fe Floppy robustification, better bitstream handling [John Keoni Morris, Peter Ferrie, Olivier Galibert] 2018-05-26 22:06:40 +02:00
Vas Crabb
c15531dddc srcclean (nw) 2018-05-27 04:48:13 +10:00
AJR
1fe4b36065 Fix error in debug build with SMS card options (nw) 2018-05-21 03:01:39 -04:00
balr0g
ea646ca403 Add Schmitt trigger device to standalone netlist Makefile (nw) 2018-05-11 12:06:50 -04:00
Michael Zapf
7a60dec53c Added logmacros to upd765, increased track buffer for hfe format (nw) 2018-05-10 21:01:47 +02:00
Michael Zapf
48dad9990e Fixed bitrate autodetect (nw) 2018-05-09 23:19:27 +02:00
Sergey Svishchev
23045014ac CPC DSK format: also check status bits in SR2 (nw) (#3546) 2018-05-10 01:21:42 +09:00
Michael Zapf
5a8ec54a1e ti99: Fixed disk creation via OSD 2018-05-04 21:59:16 +02:00
arbee
9adf583c47 Final GCC 8 batch for tonight (nw) 2018-05-01 22:52:25 -04:00
arbee
45977d9baa More GCC 8 (nw) 2018-05-01 22:04:06 -04:00
Olivier Galibert
d43d8bcecf apple2: Add WOZ format [O. Galibert] 2018-04-24 20:41:54 +02:00
arbee
b4ff6c970c apple2: recognize another form of DOS 3.3 in ProDOS order [R. Belmont, Peter Ferrie] 2018-04-23 19:53:57 -04:00
Vas Crabb
ac79c90607 srcclean (nw) 2018-04-22 09:24:13 +10:00
Vas Crabb
2c340f490e move some not-directly-emulation-related helpers to lib/util, further extricate emu.h from tools (nw) 2018-04-01 19:10:26 +10:00
Stefano
c959d88ec5 Minimal improvements on the disk handling (#3395)
* Keeping the 35 tracks drive as an option

* Reducing the crashes a bit more.

This helps matching the form_factor and the parameters found in the TeleDisk images, thus exiting before a serious crash.
It is NOT enough to improve the 8" disk image handling, nor it solves all the stability problems, but it is a tiny step forwards.
2018-03-27 10:20:08 +11:00
Vas Crabb
08dde5eb0a srcclean and regenerate localisations (nw) 2018-03-25 02:03:24 +11:00
Nigel Barnes
7ad824c85b New machines marked as NOT_WORKING
----------------------------------
Poly Proteus (Standalone) [Nigel Barnes, Andrew Trotman]
2018-03-21 20:53:11 +00:00
Sergey Svishchev
8b8931fb49 ms0515: unbreak memory maps; update floppy format definition to match one used by OS (nw) 2018-03-16 03:16:33 +03:00
Nigel Barnes
39b9cb0207 jvc_dsk: Added notes (nw) 2018-03-06 17:41:45 +00:00
Justin Kerk
0e77f9c540 Fixed issue causing drivers using netlists to fail on the Emscripten target. [Justin Kerk] 2018-03-06 03:12:21 +00:00
Vas Crabb
8dad4881f6 srcclean (nw) 2018-02-25 01:34:04 +11:00
Julian Sikorski
8cc758355d Enable use of system-wide asio, glm and rapidjson (#3172)
* Fixed building using system utf8proc

* Fixed building using system portaudio

* Allow using system-wide asio headers (1.11.0 or higher required).

* Allow using system-wide glm headers

* Allow using system-wide rapidjson headers
2018-02-08 16:06:25 -05:00
cracyc
649c169c2f i386/i286: fix default cs flags (nw)
d88_dsk: support bad crc (nw)
recreate columns copy protection (nw)
2018-02-02 23:01:40 -06:00
smf-
80ee327f08 disable netlist statistic logging on shutdown, because it triggers a use after free in void device_debug::errorlog_write_line(const char *line) & fixed the copy & pasted comment. (nw) 2018-01-31 11:11:16 +00:00
smf-
e78d6ac9dc thanks hap (nw) 2018-01-29 15:13:07 +00:00
smf-
6f377beb87 fix is_set() when generic_function is an int array (nw) 2018-01-29 12:07:47 +00:00
smf-
6fb696211b fix assertion when debugging in visual studio (nw) 2018-01-29 12:07:46 +00:00
Dirk Best
648af3b4d9 d88_dsk: Add some safety checks to avoid reading beyond the end of file 2018-01-28 01:54:49 +01:00
AJR
57bd62a1fb Eliminate core_strdup (nw) 2018-01-24 21:06:25 -05:00
Oliver Stöneberg
4e64f95721 Fixes for Coverity "Resource leak" warnings (#3089)
* lib/util/chdcd.cpp: fixed Coverity "Resource Leak" warning (nw)

* src/lib/util/chdcd.cpp: fixed more Coverity "Resource Leak" warnings (nw)

* tools/imgtool/modules/mac.cpp: fixed Coverity "Resource Leak" warnings (nw)

* devices/bus/ti99/gromport/cartridges.cpp: fixed Coverity "Resource Leak" warning (nw)
2018-01-21 15:24:51 +11:00
ajrhacker
68af4962e1
Merge pull request #3038 from firewave/ccvf
fixed MT06831 (bogus casting in ccvf_format::file_formats) (nw)
2018-01-10 15:18:06 -05:00
firewave
f2fedf0c8c fixed MT06831 (bogus casting in ccvf_format::file_formats) (nw) 2018-01-10 20:41:35 +01:00
Vas Crabb
d697e8a992 Convert zippath directory to a C++ interface 2018-01-10 18:25:26 +11:00
arbee
4cc0c47387 chdcd: recognize ISO images with 2336 byte sectors. [R. Belmont, Kale] 2018-01-08 09:18:57 -05:00
Jonathan Holt
c25b98226d Updates "2017" strings to "2018" where relevant. 2018-01-06 00:48:05 +11:00
Vas Crabb
bc9d99d58b use C locale for int/float in XML files 2018-01-05 17:12:01 +11:00
Firehawke
9ece34eb21 Revert "Revert "Merge branch 'master' of https://github.com/mamedev/mame""
This reverts commit 54155441e9.
2017-12-13 21:31:27 -07:00
Firehawke
54155441e9 Revert "Merge branch 'master' of https://github.com/mamedev/mame"
This reverts commit f537428e5a, reversing
changes made to 0d70d79810.
2017-12-13 21:01:10 -07:00
Sergey Svishchev
00c9b62a24 agat7: 840KB floppy HLE; minor fixes -> mark WORKING (#2912)
* agat7: add port_char definitions to allow access from Lua, &c (nw)

* agat7: adapt "apple2: Break up handlers for C000-C07F range" (nw)

* agat7: timer and vblank interrupts (nw)

* agat7: HLE of 840KB floppy controller, read-only (nw)

* agat7: memory expansion wip (nw)

* agat7: update todo list, mark partially WORKING
2017-12-08 18:46:23 -05:00
Dirk Best
5676444d8c jvc_dsk: Fix MT #06779 2017-11-29 10:19:03 +01:00
Olivier Galibert
6caef2579a dvdisasm: Overhaul [O. Galibert]
Disassemblers are now independant classes.  Not only the code is
cleaner, but unidasm has access to all the cpu cores again.  The
interface to the disassembly method has changed from byte buffers to
objects that give a result to read methods.  This also adds support
for lfsr and/or paged PCs.
2017-11-26 17:41:27 +01:00
Justin Kerk
b503e9c8c2 pc_dsk: Support images with 41 tracks (Kryoflux dtc produces these for some nominally 40-track disks) (fixes bivouac from ibm5150_flop.xml) (nw) 2017-11-15 20:25:12 -08:00
Dirk Best
b4e8282023 dsk_dsk: Don't segfault on empty tracks (fixes einstein 4game) 2017-10-25 13:13:54 +02:00
Vas Crabb
4c29419cab srcclean (nw) 2017-10-22 12:34:30 +11:00
AJR
ff6a9334e3 Appease MSVC (nw) 2017-10-19 12:29:33 -04:00
npwoods
86f50b0d65 Created a more flexible imgtool::datetime structure for use within Imgtool (#2263)
* Created a more flexible imgtool::datetime structure for use within Imgtool

This is intended to replace most usage of time_t

* Changing the granularity of imgtool_clock from 1ms to 100ns, as per Vas' suggestion

* Created arbitrary_datetime in timeconv.h to facilitate interpretation of datetime info

I concluded that invoking std::mktime on manually assembled std::tm is bad, because it is indeterminate how the std::tm members may be "dominant".  This required that I go further in imgtool, and update a number of drivers and eliminate the parameter of imgtool::datetime that takes std::tm.
2017-10-17 21:18:57 +02:00
Justin Kerk
a55d88393e Fix crash loading 80-track .mfm dumps of 40-track disks on 40-track drives. [Justin Kerk] 2017-10-11 19:13:59 -07:00
Nigel Barnes
72ec5336d0 acorn_dsk: Removed CPN format, now handled with SSD/DSD. 2017-10-11 12:03:01 +01:00
Nigel Barnes
1e1fb0902a acorn_dsk: Improve identifying SSD/DSD by comparing image size with sector counts.
- Fixed DDCPM format to handle correct image of Double Density CP/M.

bbc_flop_z80.xml: Replaced Double Density CP/M with good dump (nw)
2017-10-11 12:03:01 +01:00
Ted Green
7d17b6a569 voodoo: Use table lookup for RGB565 conversion. (nw) 2017-10-01 15:39:53 -06:00
smf-
bcb4be3a5d fix for clang 5 unused lambda capture errors (nw) 2017-09-24 17:49:35 +01:00
Vas Crabb
75fefade26 unzip: defer decoding DOS timestamps (nw) 2017-09-11 10:16:16 +10:00
Vas Crabb
70279ab5a2 that doesn't require an instance (nw) 2017-09-03 12:51:21 +10:00
hap
23d9d21250 png: make verify_header public (nw) 2017-09-02 22:46:14 +02:00
npwoods
d217e1fbec Returning a reference from various corestr.cpp calls to avoid unnecessary string copies (#2613) 2017-09-02 23:09:00 +10:00
Vas Crabb
ec3caa98bd srcclean (nw) 2017-08-27 11:07:21 +10:00
MetalliC
1d4f72b5fe needed for external work (nw) 2017-08-26 05:11:08 +03:00
Nigel Barnes
70b91571ce acorn_dsk: Added OPUS_DDCPM_FORMAT
- Removed ACORN_CPM_FORMAT, same geometry as ACORN_SSD_FORMAT/ACORN_DSD_FORMAT
- Improved find_size/identify for SSD/DSD formats
- ACORN_DOS_FORMAT 640K now handled as ACORN_ADFS_OLD_FORMAT
- Fixed geometry for ACORN_DOS_FORMAT 800K

bbc_acorn8271: Added Amcom DFS A7874

bbc_opus8272: New Opus 8272 FDC device with DDOS 3.00, not yet working.

wd177x_dsk: Apply sector_count and gaps to track description.
2017-08-25 20:03:44 +01:00
fulivi
ac90b9c2ef hp85: fixed a bug in tape gap detection 2017-08-23 19:33:27 +10:00
fulivi
480f865bcf hp9845: re-factored handling of HTI images into a dedicated format module 2017-08-16 10:38:22 +02:00
Vas Crabb
1c4c96a0cf add a not BIOS machine filter (useful in composite filters), support RGB PNG with transparent pen because why not 2017-08-15 18:19:18 +10:00
Vas Crabb
4e7f7f5265 fix indexed transparency (nw) 2017-08-14 14:30:19 +10:00
Vas Crabb
3a258ecf9b PNG: support greyscale with transparent pen, encode/decode text chunks as UTF-8, don't crash on trying to write back a text chunk read from a PNG file, enforce restrictions on keywords 2017-08-14 14:23:08 +10:00
Vas Crabb
61983736e8 png: make it not leak memory by default, and look a but more like C++ 2017-08-13 18:12:54 +10:00
Vas Crabb
44bc3ffa43 png: support 16-bit samples 2017-08-13 15:53:36 +10:00
Vas Crabb
da18b88ba9 PNG: fix unfiltering 2017-08-12 17:53:23 +10:00
Vas Crabb
c179a4e0e9 ui: save/restore images/info selection in right panel 2017-08-12 16:02:52 +10:00
Vas Crabb
71c7cfe525 More PNG handling overhaul:
* Unify code for copying PNG data into bitmap for MAME and pngcmp
* Fix upsampling of monochrome PNGs (need to splat across byte)
* Add support for greyscale+alpha
* Detect more unsupported conditions rather than just behaving badly
2017-08-12 15:38:14 +10:00
Vas Crabb
a7b15fc928 add minimal support for reading Adam7 interlaced PNG
(nw) This is the path of least resistance, and I plan to fix it up
later, I just wanted to get it to actually work first.  Decompression
and unfiltering is fully supported, at least for all the pixel formats
that previously worked.  Expanding 1/2/4bpp to 8bpp should work
properly, too.  Bitmap mapping for Adam7 is only implemented in
rendutil.cpp which is whate everything in MAME uses.  The function in
png.cpp (used by pngcmp) has not been updated.  At some point I'll unify
at least one of the functions in rendutil.cpp with the one in png.cpp
and we can go from three functions that need to do the mapping down to
two at the most.
2017-08-12 02:43:53 +10:00
Nathan Woods
df8bb7f18c Adding #include <cctype> 2017-08-09 07:40:15 -04:00
Christian Brunschen
336a636aed Refactor server_{ws,http}.hpp into separate interface and implementation. (#2548)
Refactor server_{ws,http}.hpp into separate interface and implementation headers.
When shutting down the HTTP server, also explicitly stop the asio::io_context.
2017-08-06 21:25:55 +10:00
Dirk Best
c10471e7ec jvc_dsk: Improve support for headerless OS-9 images 2017-08-03 16:05:08 +02:00
Dirk Best
224cfaeb6a jvc_dsk: Autodetect double sided floppy images without header, fixes #2405 2017-08-03 13:09:52 +02:00
npwoods
aca90520de Imgtool: Merged normalize_filename() into cannonicalize_path(), C++-ification (#2527) 2017-07-30 15:16:45 +10:00
Vas Crabb
ba3d0a88d6 srcclean (nw) 2017-07-23 13:29:00 +10:00
Vas Crabb
d7984c7d0c Add a method for copying part of an XML tree into another tree and use it to fix Cocoa debugger fatal error 2017-07-21 13:03:44 +10:00
Vas Crabb
05e84dccc0 * Make XML file a class of its own managed with smart poitners
* Save/restore a little more of Cocoa debugger state
2017-07-21 11:47:41 +10:00
rfka01
9bff063d9d Corrected ITT3030 70 track drive type and added 35 drive type and format definition. [helwie44 and rfka01] 2017-07-11 00:15:06 +02:00
Vas Crabb
d18aa3e097 never hurts to srcclean (nw) 2017-07-09 03:21:32 +10:00
Christian Brunschen
0206314395 Add an external panel for the Ensoniq VFX family of keyboards, with a websocket interface and an HTML/Javascript implementation that can be served over HTTP. 2017-07-05 17:27:34 +01:00
Olivier Galibert
cbbbd07484 dimemory: Lift the cap on the number of address spaces per device [O. Galibert] 2017-07-03 08:03:57 +02:00
Olivier Galibert
df1b7770ef options: Set the value when setting the default as before [O. Galibert] 2017-06-25 16:50:02 +02:00
Vas Crabb
fb61e98cc5 more srcclean (nw) 2017-06-25 15:21:44 +10:00
Vas Crabb
41e1555242 Merge branch 'release0187'
Conflicts:
	src/mame/drivers/accomm.cpp
2017-06-25 15:19:30 +10:00
Vas Crabb
f31e735053 srcclean (nw) 2017-06-25 15:18:14 +10:00
npwoods
b193e05cd7 Overhaul to how MAME handles options, take two (#2341) 2017-06-25 12:48:56 +10:00
npwoods
2af3233101 Changed a few 'const char *' ==> 'const std::string &' in the MAME debugger (#2170) 2017-06-24 09:46:58 +10:00
Nigel Barnes
fc292683f9 afs_dsk: corrected density (nw) 2017-06-15 18:43:33 +01:00
tim lindner
78614368bf Fixed JVC disk format to correctly recognize 2 sided disks. (#2357) 2017-06-03 17:59:15 +02:00
tim lindner
2c2458bbac Added read support for the disk format SDF used in the CoCoSDC (#2345) 2017-05-31 16:23:49 +10:00
couriersud
7e8a7aeea9 Add Zaccaria to mamenl build. (nw) 2017-05-28 11:10:54 +02:00
couriersud
e9a5e08b41 Fix state saving for pfunction lfsr. (nw) 2017-05-28 09:03:29 +02:00
Vas Crabb
e892661905 srcclean (nw) 2017-05-28 13:40:48 +10:00
couriersud
0a2d4a256d Fix issues identified by Vas and LordKale4:
- made local netlists in Cheeky Mouse static
- replace stdlib rand by 16 bit galois lfsr

(nw)
2017-05-27 22:17:35 +02:00
couriersud
994263eaf9 Add rand() function to pfunction expression parser. Use this to simulate
E-B noise in Cheeky Mouse and fix the "cheese" choose. [Couriersud]
2017-05-27 14:28:53 +02:00
Vas Crabb
2d4ba2471d netlist: add a crude TTL schmitt trigger model and hook up in 1B11142
sound board, completing the tromba circuit

(nw) I'm not sure whether the model works properly or not, but in the
circuit where it's used, I don't think it can work properly with the
current TTL output model.  A capacitor is charged by the Q output of a
74LS74 flipflop (U3A) until the voltage passes the Schmitt trigger's
threshold, causing it to reset the flipflop.  However, the positive
trigger voltage of the Schmitt trigger is 1.6V, but our TTL output model
has a high output voltage of 1.0V (see nl_base.cpp:89).  I realise the
simplified model of TTL logic with high impedance inputs and outputs
behaving as though thery're loaded is convenient and fast to simulate,
but it's not detailed enough for applications like this where
7400-series chips are used in analog circuitry.  This is what held me up
last time I tried adding a netlist for this sound board.
2017-05-27 18:44:23 +10:00
couriersud
6d9da523e3 Fix DEBUG build. (nw) 2017-05-27 00:11:16 +02:00
couriersud
6fd40f98a6 Various code alignments across solvers. (nw) 2017-05-27 00:11:16 +02:00
couriersud
6dfe04c620 Cleanup of solver code. (nw) 2017-05-27 00:11:15 +02:00
couriersud
a27f10c4a7 Reordered members to be more cache friendly. (nw) 2017-05-27 00:11:15 +02:00
couriersud
bc29593982 Netlist refactoring:
- OPENMP refactored. All OPENMP operations are now templatized in pomp.h
- We don't need thread-safe priority queue. Event code updating analog
outputs now runs outside the parallel code. 
(nw)
2017-05-27 00:11:14 +02:00
couriersud
01f8ace296 Changed Solver.PARALLEL parameter logic:
0: Parallel processing of solvers disabled
1: One processor parallel processing. Can be used to measure OPENMP
overhead
>1: Solve n analog subnets in parallel.

Previously, all available processors were used which caused performance
to degrade on hyperthreading. 
[Couriersud]
2017-05-27 00:11:14 +02:00
Vas Crabb
2b7d87317b Preliminary netlist sound for the Zaccaria 1B11142 board
* Tromba (trumpet) sound is not working - requires Schmitt trigger device
* Connecting cassa (bass drum) swamps other instruments so it's disconnected for now
* Mixing melody sound with speech/SFX is not done in netlist (should be)
* Relative levels of melody/speech/SFX are probably still wrong

(nw) A good test case for this is the Money Money driver (monymony).
There's a bit of buzzing on this one as well.  The problem with the
cassa could be caused by running into non-ideal characteristics of opams
again (the LM3900 seems to ignore the V+ value supplied to it).  When
the netlist library gets Schmitt trigger support, the tromba can be
completed.  Unfortunately, the tromba is a key part of the
characteristic sound of these boards, so you really notice when it's
lacking.
2017-05-27 03:57:50 +10:00
hap
2d5bb2dc20 New working clone added
----------
Speak & Spell (Spanish, prototype) [hap, Sean Riddle, David Viens]
2017-05-26 17:35:04 +02:00
Vas Crabb
308c2bb72d cheekyms: add preliminary netlist sound based on schematics provided by Sam Grech
(nw) It doesn't work quite right yet.  The "Hammer" and "Pest" sounds
are generated by free-running 555/556 timers and gated with LM324
applifiers.  For whatever reason, the netlist system produces a kind of
buzzing from the "Hammer" circuit when it's supposed to be suppressed,
and it doesn't think the pest sound should be suppressed completely so
you can always hear it at a low level in the background.  The "Cheese"
circuit is a bit weird - either they're using the base-emitter junction
of a 2SC945 as a signal diode, or there's an error in the schematic
(collector is shown unconnected).  Connecting this part of the circuit
causes the netlist system to hang, so R2/R3/C8/Q2 are not connected for
now.
2017-05-26 16:43:29 +10:00
Vas Crabb
75dfd32e71 Support -listroms for devices (e.g. mpu401 or m68705p3)
* Also ~67% improvement of device walk in -verifyroms
2017-05-18 19:34:28 +10:00
smf-
442eddbfed fix MSVC build (nw) 2017-05-16 13:56:52 +01:00
fulivi
e2b9e11da0 Hp9845: Support for HPI floppy format (#2310)
hp9845: Support for HPI floppy format [F. Ulivi, A.Kückes]
2017-05-16 09:52:31 +02:00
Miodrag Milanovic
a4c5e29c2f Forgot this one for GCC 7.1 (nw) 2017-05-15 19:27:56 +02:00
smf-
f7f4b2126e Revert "reordering the #include lets you build this file with latest mingw headers (nw)"
This reverts commit c3b10caf4e.
2017-05-14 16:49:49 +01:00
smf-
c3b10caf4e reordering the #include lets you build this file with latest mingw headers (nw) 2017-05-14 16:09:24 +01:00
Vas Crabb
0f0d39ef81 Move static data out of devices into the device types. This is a significant change, so please pay attention.
The core changes are:
* Short name, full name and source file are no longer members of device_t, they are part of the device type
* MACHINE_COFIG_START no longer needs a driver class
* MACHINE_CONFIG_DERIVED_CLASS is no longer necessary
* Specify the state class you want in the GAME/COMP/CONS line
* The compiler will work out the base class where the driver init member is declared
* There is one static device type object per driver rather than one per machine configuration

Use DECLARE_DEVICE_TYPE or DECLARE_DEVICE_TYPE_NS to declare device type.
* DECLARE_DEVICE_TYPE forward-declares teh device type and class, and declares extern object finders.
* DECLARE_DEVICE_TYPE_NS is for devices classes in namespaces - it doesn't forward-declare the device type.

Use  DEFINE_DEVICE_TYPE or DEFINE_DEVICE_TYPE_NS to define device types.
* These macros declare storage for the static data, and instantiate the device type and device finder templates.

The rest of the changes are mostly just moving stuff out of headers that shouldn't be there, renaming stuff for consistency, and scoping stuff down where appropriate.

Things I've actually messed with substantially:
* More descriptive names for a lot of devices
* Untangled the fantasy sound from the driver state, which necessitates breaking up sound/flip writes
* Changed DECO BSMT2000 ready callback into a device delegate
* Untangled Microprose 3D noise from driver state
* Used object finders for CoCo multipak, KC85 D002, and Irem sound subdevices
* Started to get TI-99 stuff out of the TI-990 directory and arrange bus devices properly
* Started to break out common parts of Samsung ARM SoC devices
* Turned some of FM, SID, SCSP DSP, EPIC12 and Voodoo cores into something resmbling C++
* Tried to make Z180 table allocation/setup a bit safer
* Converted generic keyboard/terminal to not use WRITE8 - space/offset aren't relevant
* Dynamically allocate generic terminal buffer so derived devices (e.g. teleprinter) can specify size
* Imporved encapsulation of Z80DART channels
* Refactored the SPC7110 bit table generator loop to make it more readable
* Added wrappers for SNES PPU operations so members can be made protected
* Factored out some boilerplate for YM chips with PSG
* toaplan2 gfx
* stic/intv resolution
* Video System video
* Out Run/Y-board sprite alignment
* GIC video hookup
* Amstrad CPC ROM box members
* IQ151 ROM cart region
* MSX cart IRQ callback resolution time
* SMS passthrough control devices starting subslots

I've smoke-tested several drivers, but I've probably missed something.  Things I've missed will likely blow up spectacularly with failure to bind errors and the like.  Let me know if there's more subtle breakage (could have happened in FM or Voodoo).

And can everyone please, please try to keep stuff clean.  In particular, please stop polluting the global namespace.  Keep things out of headers that don't need to be there, and use things that can be scoped down rather than macros.
It feels like an uphill battle trying to get this stuff under control while more of it's added.
2017-05-14 21:44:11 +10:00
npwoods
baa7178053 Bug fix to -romident and aux verb cleanup (take two) (#2299)
* Resurrected auxverb_cleanup_and_romident_bugfix

* Changed usage for -romident and minor cleanups

* Supporting auxverbs in any order

The previous patch was supporting 'mame64 -listsource pacman' but not 'mame64 pacman -listsource'
2017-05-13 00:53:46 +10:00
Vas Crabb
e88b5e4f9d Revert "Bug fix to -romident and aux verb cleanup (#2288)"
This reverts commit 78bf804192.
2017-05-12 17:24:56 +10:00
npwoods
78bf804192 Bug fix to -romident and aux verb cleanup (#2288)
* Bug fix to -romident and aux verb cleanup

Made the following changes:
 1.  Fixed a bug where resolved slot/image options would choke -romident (reproducible in MAME 0.185 with 'mame64 -romident coco.zip')
 2.  'mame64 -romident' no longer crashes (though it doesn't do anything useful)
 3.  Changed the aux verb functions to take 'const std::string &'

* Further cleanups to auxillary verb code, as per Vas

Specifically:
 1.  The commands themselves now take 'const std::vector<std::string> &' for their argument lists
 2.  util::core_options now collects command arguments into a separate vector rather than treating them as unadorned arguments

* Vas Crabb feedback

* Now only using trim_spaces_and_quotes() when parsing INIs

Vas pointed out that it is inappropriate to trim spaces and quotes when parsing command line options
2017-05-12 09:18:20 +10:00
Nathan Woods
9d4b370354 Changed 'int ignore_warnings' parameter on core_options::parse_ini_file() to be 'bool ignore_unknown_options' 2017-05-10 09:53:15 +10:00
Vas Crabb
a400c011a9 Revert "Overhaul to how MAME handles options (#2260)"
This reverts commit 536990e77b.

Conflicts:
	src/frontend/mame/mame.cpp

Sorry, but this change was half-baked.  It breaks a lot of existing
functionality and clearly hasn't been tested in more than a tiny subset
of use cases.  Please play this work back onto your own branch, and test
it before submitting another PR.
2017-05-07 14:40:12 +10:00
npwoods
536990e77b Overhaul to how MAME handles options (#2260)
This is an overhaul to how MAME handles options to provide a better foundation for what MAME is already doing in practice. Previously, core_options was designed to provide an input/output facility for reading options from the command line and INI files. However, the current needs (image/slot/get_default_card_software calculus and MewUI) go way beyond that.

Broadly, this PR makes the following changes:
* core_options now has an extensibility mechanism, so one can register options that behave dramatically differently
* With that foundation, emu_options now encapsulates all of the funky image/slot/get_default_card_software calculus that were previously handled by static methods in mameopts.cpp. Changes to emu_options should not automatically cascade in such a way so that it stays in a consistent state
* emu_options no longer provides direct access to the slot_options/image_options maps; there are simpler API functions that control these capabilities
* Many core_options functions that expose internal data structures (e.g. - priority) that were only really needed because of previous (now obsolete) techniques have been removed.
* core_options is now exception based (rather than dumping text to an std::string). The burden is on the caller to catch these, and discern between warnings and errors as needed.

Obviously this is a risky change; that's why this is being submitted at the start of the dev cycle.
2017-05-05 16:17:49 +10:00
Vas Crabb
69d47f3841 Fix off-by-one error (nw)
The +1 was previously needed becasue std::string::assign(char *) expects
the string to be NUL-terminated.  The final NUL is not part of the
result.  It's not needed when adjusting the length of the string
directly.  Can people please be careful when refactoring, and alo when
reviewing pull requests?  This stood out immediately.
2017-05-05 01:12:33 +10:00
Nathan Woods
eb8e8426dd Minor improvement to CHD metadata loading
Writing into an std::string is now legal with C++11
2017-05-04 07:58:27 -04:00
Vas Crabb
d6cd22c5e3 stupid MSVC (nw) 2017-04-24 00:04:20 +10:00
Vas Crabb
dac6dc4f62 srcclean (nw) 2017-04-23 12:27:42 +10:00
Nigel Barnes
29a7778ae7 atom: Added csw cassette format
csw_cas: Fixed Coverity CID 136200 Logically dead code (nw)
2017-04-17 18:49:42 +01:00
Nigel Barnes
79e60cfae2 jfd_dsk: Fix Coverity CID 161175 Uninitialized scalar variable (nw) 2017-04-17 18:49:42 +01:00
Nathan Woods
85b0d8bb04 Pruned out some cruft in src/lib/util/options.[cpp|h] 2017-04-17 08:17:04 -04:00
Nathan Woods
c108986639 More options refactoring
This should address outstanding concerns with PR#2231.  I'm trying to turn emu_options into a self contained structure that encapsulates behaviors related to options, including the gymnastics pertaining to image/slot loading and interactions with get_default_card_software() and "just works".

When the MAME 0.186 development cycle starts up, I hope to take this further.  I want to make core_options::entry an abstract base class so that the entries associated with image options and slot options can derive from it.  This will eliminate the current need for emu_options to directly expose maps for image and slot options.

For now, I'm in stabilization mode, and I hope to get things working for a stable 0.185 release.
2017-04-16 13:08:57 -04:00
npwoods
02ea4fd43c Fixes issues specifying image/slot options fron INI files (reported by Robbbert) (#2231)
This fix really doesn't go far enough.  I added hooks so that options specified at the command line can also be responded to when parsed from INI files, but in the long run much of the logic that is currently in mame_options should go into emu_options so that when an option is specified, all of the wacko logic around slot/image specification "just works" because it is encapsulated within emu_options.

We have a release 11 days away; I want to be in stabilization mode.
2017-04-15 22:32:12 +02:00
Antoine Miné
fee8cc7135 [thomson] fix regressions to (legacy) floppy support (#2224)
* [thomson] fix legacy floppy support

* [thomson] more (legacy) floppy fixes
2017-04-13 10:38:28 +10:00
cracyc
7c9b346ade cdrom: translate from 2336 to 2048 (nw) 2017-04-10 13:59:26 -05:00
couriersud
41b915c712 Minor optimization. (nw) 2017-04-09 23:00:03 +02:00
couriersud
f011567c77 Parametrized device activation in truthtables. (nw) 2017-04-09 23:00:02 +02:00
couriersud
a55419d485 Fix VS2015 build. (nw) 2017-04-09 04:25:49 +02:00
couriersud
5a24cab445 More work on 9316. (nw) 2017-04-09 04:25:09 +02:00
couriersud
6e9637196d Refactored 74715 to one device layout. Removed subdevice. (nw) 2017-04-09 02:42:38 +02:00
couriersud
49d50c3045 Netlist code refactoring:
- more use of c++ features
- some CRTP in pfmtlog
- demangled code for truthtables
- use more constexpr
- rewrite main loop
- use default constructors and assignment operators were applicable.
- optimized 7448 and 9316

All of this has decreased startup time by approx. 25% to 30%. Complex
netlists like pong or kidniki are parsed, analyzed and constructed in
around 15 ms. Run performance has increased by about 5%.

All in all not to bad. A game like pong uses a clock of 7 MHz (after
division by 2). Thats 14 MHz clock invocations. Running at over 200%, 28
MHz. On a 3.9 GHz Machine about 140 cycles/clock change.

[Couriersud]
2017-04-09 00:04:10 +02:00
npwoods
f809f0e08d Introduced an 'util::arbitrary_clock' template class, to represent a clock that "knows" when the epoch starts (#2010)
* Introduced an 'util::arbitrary_clock' template class, to represent a clock that "knows" when the epoch starts

Also:
  - Converted the NTFS filetime code to use util::arbitrary_clock
  - Converted the Mac datetime code to use util::atribrary_clock

This is in preparation for a bigger change to Imgtool where I eliminate usage of time_t
2017-04-06 11:39:00 +10:00
couriersud
58aa97913f pstring, pdynlib, pfmtlog refactoring :
pstring:
- added support for UTF16LE to pstring. 
- renamed size() to mem_t_size()
- renmaed len() to length()
- added size() == length()
- added empty()
- added simple compare()

pfmtlog:
- Simplified pfmtlog, added more c++

pdynlib:
- add a dynproc type to dynlib to wrap dynamic library calls. 

various:
- fix two coverty scan issue.
- various clang warnings fixed.

(nw)
2017-04-04 02:02:56 +02:00
Nathan Woods
44c04cd97a Fixed issue that could cause bogus arguments to be reported incorrectly
Examples:  'mame -whatever nes' would previously be reported as "Unrecognized argument: nes"
2017-04-02 19:41:40 -04:00
couriersud
0c1b6430d0 Fix pedantic clang warnings. (nw) 2017-03-30 23:24:48 +02:00
couriersud
aacee827fe Use char32_t were appropriate. (nw) 2017-03-30 23:17:11 +02:00
couriersud
ac13946ffb Change pstring to use std::string as storage container.
This removes all allocation code from pstring. const_iterator is
consequently now based on pstring::const_iterator. 
Removed pstring_buffer. This was class wasn't a good idea.

Vas was right: This change did not impact runtime performance. Startup
performance (string intensive) increased. (nw)
2017-03-30 22:06:03 +02:00
Vas Crabb
5e8fefbb12 Turn psring iterator into a real forward iterator that works with standard algorithms.
There are a few changes to achieve this:
* Rename to const_iterator since it's immutable
* Typedef iterator to const_iterator for now as there's no mutable iterator
* Add default constrcutor and operator-> required by concept, const-qualify operators
* Remove operator+ and operator+= since it's not a random-access iterator (use std::next and std::advance instead)
* Return reference/pointer to a proxy rather than a code_t value from opertator*/operator->

The final change is required to meet the requirement that operator* for
two equivalent forward iterators return an equivalent reference.  The
pstring doesn't actually contain a sequence of code_t, so there's no way
to return a reference to code_t directly.  Instead, a reference to a
proxy object aliased on the string storage is returned.  The proxy is
implicitly convertible to code_t.  The most noticeable side effect is
that auto c = *s.begin() or for (auto c : s) won't work.  You need to do
for (auto &c : s) or for (code_t c : s) instead.
2017-03-30 15:51:14 +11:00
Vas Crabb
6cb38b0771 srcclean (nw) 2017-03-26 12:57:49 +11:00
Nigel Barnes
f224898523 archimedes: Added JFD floppy format as used by JASPP (Archimedes Software Preservation Project) 2017-03-23 20:47:26 +00:00
Nigel Barnes
d0d342d76c apd_dsk: added notes (nw) 2017-03-23 20:47:26 +00:00
couriersud
6e8b88136d Fix openmp compile. (nw) 2017-03-20 18:42:11 +01:00
Miodrag Milanovic
ad2bedf06b Refactored HTTP handling to be easier to extend and use (nw) 2017-03-19 18:35:05 +01:00
Sergey Svishchev
7d4d6382e7 hp_ipc: de-skeletonize. 2017-03-16 22:26:49 +03:00
R. Belmont
77155c2657 Merge pull request #2138 from shattered/_47be08c
eurocom2, waveterm: new skeleton drivers (Eltec EurocomII SBC, PPG Wa…
2017-03-14 20:56:26 -04:00
Justin Kerk
8b0fae308e New working software list additions
-----------------------------------
ibm5150: EDITEXTE, Label Magic, Multitexte, PrintMaster Plus, Bivouac, Chuck Yeager's Advanced Flight Trainer,
  Double Dragon (5.25", older), Indianapolis 500: The Simulation (3.5", newer), Licence to Kill, Pick'n Pile, Prehistorik,
  Rockford, Skweek [breiztiger]

New NOT_WORKING software list additions
---------------------------------------
ibm5150: Ikari Warriors (alt), First Samurai, JetFighter I: The Adventure, Turbo Driver [breiztiger]
2017-03-12 13:40:02 -07:00
Sergey Svishchev
8fd315da7e eurocom2, waveterm: new skeleton drivers (Eltec EurocomII SBC, PPG Waveterm A) 2017-03-12 17:17:06 +03:00
Sergey Svishchev
58f2def862 formats/cbm_tap: fix CID: 138003 "Dereference before null check" 2017-03-11 02:21:54 +03:00
couriersud
d23cecc86b Fix clang warnings in netlist code.
Fixed -Winconsistent-missing-destructor-override warnings. Made
some constructors of template classes and classes with virtual .. = 0
methods protected. Fixed src/lib/netlist/build/makefile (nw)
2017-03-05 21:59:52 +01:00
Couriersud
3c49610274 More cppcheck fixes. (nw) 2017-03-05 16:19:59 +01:00
Couriersud
c933d239f5 Fix some cppcheck warnings. (nw) 2017-03-05 16:19:58 +01:00
Vas Crabb
28596c7161 fix crash on excessive command-line options, clean up some tabulation, remove long-dead option 2017-03-03 14:18:58 +11:00
Sergey Svishchev
7fb8176ac6 apply clang-format, remove obsolete comments. no code changes. 2017-03-02 01:24:43 +11:00
Nathan Woods
239dcd4449 Fixed regression pertaining to specification of empty strings as slot names
e.g. - 'next -scsibus:1 "" -listdevices'
2017-02-27 01:14:11 +11:00
couriersud
1a2f928403 Netlist refactoring
- align timed_queue closer to std::priority_queue
- use uint8_t in extended clock for better memory usage.
- minor changes to nl_breakout.cpp (nw)
2017-02-25 10:44:04 +01:00
couriersud
454938dad4 Fix clang-5.0 warning .. Maximum of unsigned X and 0 is always X. (nw) 2017-02-24 14:58:34 +01:00
couriersud
7c1ba76f3b Fix netlist stats collection. Code refactoring:
Small improvement for 7493.
Convert 9316 from subdevice to delegate.
Convert 74107 from subdevice style to delegate. 
Also refactored inconsistencies in other parts of the code. (nw)
2017-02-24 14:55:45 +01:00
couriersud
acd0382d90 Added a heap priority queue to the netlist source.
This is currently not used since performance drops by about 40%. The
typical use case would be circuits a lot more complex than those we
currently emulate where the 2*log(n) advantage really applies. (nw)
2017-02-24 14:49:12 +01:00
Vas Crabb
759933ded7 Fixed an issue where device options (e.g. -cart) were reported as unknown when they actually worked (#2081)
Conflicts:
	src/frontend/mame/clifront.cpp
2017-02-24 09:34:15 +11:00
Nathan Woods
41c2350266 Vas feedback 2017-02-23 09:23:41 -05:00
Nathan Woods
8c53c1438e Fixed an issue where device options (e.g. -cart) were reported as unknown when they actually worked
This change also changes around how command line arguments are passed around; specifically I changed argc/argv to be std::vector<std::string>

Note this is not passed around 'const', the reason being that the command line processing will now "eat" the vector
2017-02-22 23:13:41 -05:00
npwoods
709c330a1f Softlist cleanup (#2075)
* Eliminates the need for emu_options::update_cached_options() by providing a hook for when option values change

* This is a preliminary fix to the issue identified in PR#2065

* More softlist related refactoring:
  - We now only parse the command line (with core_options::parse_command_line()) once
  - Options that are set up during slot and image setup go through a 'value_specifier' function
  - Eliminated the command line postprocessing
2017-02-22 23:16:23 +11:00
couriersud
85d915f5cd Fix VS2015 compile. (nw) 2017-02-22 02:04:02 +01:00
couriersud
a82ca2d244 Improve readability. Add more c++11 noexcept and swap semantics.
Also fixed clang-5 warnings. (nw)
2017-02-22 02:04:02 +01:00
couriersud
5c4b7cfef8 Clean up net_t interface and increase readability. (nw) 2017-02-22 02:04:01 +01:00
couriersud
0bdffa7e97 Slightly improve event timing if state changes.
Also introduce a push_force call to reschedule already pending events if
the state will not change. (nw)
2017-02-19 16:55:30 +01:00
Vas Crabb
8f15315a52 srcclean (nw) 2017-02-19 11:40:55 +11:00
couriersud
2acad1f854 Add prodigy to mamenl build. Fix clang5 warnings. (nw) 2017-02-19 01:00:48 +01:00
couriersud
65806114b0 More truthtable rework and clean up. (nw) 2017-02-19 01:00:48 +01:00
couriersud
2ade578dc0 Fix nltool logging. (nw) 2017-02-19 00:59:31 +01:00
R. Belmont
7b193346a8 Merge pull request #2068 from JoakimLarsson/prodigy_display
Prodigy display
2017-02-17 21:59:51 -05:00
couriersud
8536d065e2 Fix mingw 32 bit build. (nw) 2017-02-17 20:10:15 +01:00
couriersud
0716d96514 Reworked truthtables a bit.
- Moved 9312 and 74279 to ttl macro library.
- Renamed TTL_9312_* to DM9312. This is more appropriate.
- Fixed a number of warnings from latest ubuntu clang-5.0.
2017-02-17 20:10:15 +01:00
Curt Coder
044d08a6c3 abc800_dsk: Fixed sector interleave. [Curt Coder] 2017-02-17 13:14:40 +02:00
Joakim Larsson Edstrom
f9f149a579 new netlist device: 74164 - 8bit parallel output serial shift register 2017-02-17 09:05:30 +01:00
couriersud
73b4115c19 Optimized 7493 device. Gives some 5 to 10% improvement to pong.
7493 also is an example on how to use multiple handlers on a device
makes design easier. (nw)
2017-02-16 20:31:42 +01:00
couriersud
32aca6c398 Move from <cstring> to std::copy and friends. (nw) 2017-02-16 20:31:42 +01:00
Olivier Galibert
c1e0a6344a Revert "wd177x_dsk, upd765_dsk: Fixed sector interleaving. [Curt Coder]"
This reverts commit 16f79382aa.
2017-02-16 14:46:45 +01:00
Curt Coder
16f79382aa wd177x_dsk, upd765_dsk: Fixed sector interleaving. [Curt Coder] 2017-02-16 14:10:36 +02:00
R. Belmont
1835b25d6d Merge pull request #2062 from shattered/_fb4f4dd
ms0515.cpp -- hook up keyboard and floppy, improve video emulation etc. (take 2)
2017-02-15 21:58:06 -05:00
Vas Crabb
fb087b6c92 Cherry-pick some features from self-registering drivers PoC:
* Use size_t for sizes and <algorithm> for algorithms
* Fix up some files that were getting linked into multiple libs
* Add missing virtual method to sh2 peripheral class
* Put shortname in driver struct for locality
* Use shared pointers in config LRU cache for safety
2017-02-16 12:20:35 +11:00
couriersud
cc39da9c83 Added state saving and loading to nltool.
First step towards regression and unit tests. (nw)
2017-02-15 01:01:51 +01:00
couriersud
74e690d654 Move inline constructors from header to cpp. (nw) 2017-02-15 01:01:50 +01:00
Sergey Svishchev
a783bb3de4 dsk_dsk format: propagate CRC error flags 2017-02-13 19:33:08 +00:00
Sergey Svishchev
1837531d2d ms0515.cpp -- hook up keyboard and floppy, improve video emulation etc. 2017-02-13 22:09:31 +03:00
couriersud
3c60882f93 Start adding save state support to nltool.
Save states are needed for regression tests going forward. (nw)
2017-02-13 00:54:51 +01:00
couriersud
3e42594830 Add standalone VC2015 build file in src/lib/netlist/build
This was the last platform without standalone compile. Sure needs more
attention, grateful for any help. (nw)
2017-02-13 00:54:40 +01:00
couriersud
290185cf00 Remove duplicate save states / Save state simplification. (nw) 2017-02-13 00:51:41 +01:00
couriersud
f2c3b51553 Separate custom save states. (nw) 2017-02-12 23:48:53 +01:00
couriersud
d7f420ccf7 Optimize queue save state. (nw) 2017-02-12 23:48:52 +01:00
Olivier Galibert
a2557f1b02 Remove emu.h from headers (nw)
Per Vas' request.  If the compile fails for you (i'm thinking osx and
windows native debuggers here in particular), add '#include "emu.h"'
as first include of the cpp files that fail.

Due to our use of precompilation and forced inclusion, emu.h must be
included as the very first non-comment thing we do if we want to be
sure msvc compiles are identical to gcc/clang ones.  Doing it directly
instead of through an include increases the correctness probability by
a magnitude.
2017-02-11 18:31:20 +01:00
couriersud
572ca8100f Reorder include order to comply with best practices. (nw) 2017-02-10 21:53:02 +01:00
couriersud
9a71daa2e0 Make windows builds of nltool and nlwav understand unicode.
nltool and nlwav now use wmain, i.e. UNICODE main on windows. (nw)
2017-02-10 21:53:01 +01:00
couriersud
ab17457707 Make sure netlist includes are not found directly on include path.
Instead, they have to be prefixed by "netlist/". Removed unneeded link
librariers for nltool and nlwav along the way. (nw)
2017-02-10 21:52:09 +01:00
Miodrag Milanovic
90c14be174 Sync with upstream (nw) 2017-02-05 18:32:46 +01:00
couriersud
70051f6c1f Netlist: It is now possible to have multiple handlers per device ...
... for updates. This will make device implementation more flexible and
faster. A nice side-effect is that there was some minor (<5%)
performance increase already. Each input is now assigned a notification
handler. Currently this is update, but going forward this may be a
custom handler. In addition
- fixed MEMPOOL on OSX
- removed dead code
- avoid bit-rot
- added delegate support for emscripten and arm processors
- added delegate support for VS 2015 x64
[Couriersud]
2017-02-05 17:19:53 +01:00
couriersud
427cf984db Fix 9322. (nw) 2017-02-05 17:19:52 +01:00
couriersud
ced71c2b58 Add constexpr add noexcept. (nw) 2017-02-05 17:19:51 +01:00
couriersud
6a770d7086 Doxygen work. How the heck can one enforce a consistent device
documentation? (nw)
2017-02-05 17:19:51 +01:00
couriersud
f61e1f2123 Fix a bug in pstring.cpp causing crash if moved object is reused. (nw) 2017-02-05 17:19:50 +01:00
couriersud
ee8fed61c2 Some documentation work.
Along the way, set default models for devices missing them. 
Fix standalone makefile to work in mingw environment. (nw)
2017-02-05 17:19:49 +01:00
Vas Crabb
4db6e43971 Avoid conflict with Apple C++ runtime header nl_types.h 2017-02-04 12:29:23 +11:00
Vas Crabb
9568b26c35 fix chd build (nw) 2017-02-02 14:36:48 +11:00
Vas Crabb
38a6ab02e4 yo sup dawg (nw) 2017-02-02 14:17:40 +11:00
Nigel Barnes
d5bba41ed6 zx81: added tzx cassette format 2017-02-01 19:40:29 +00:00
Nigel Barnes
51992a75ec apd_dsk: improved identify and simplified load (nw) 2017-02-01 19:40:29 +00:00
Lord-Nightmare
7d05b65840 build fix (nw) 2017-01-31 18:24:49 -05:00
couriersud
e02d8cad2b Fixed a number of issues:
- Fixed crashes on terminals without nets (i.e. connected to a rail)
- Reviewed "FIXMEs" and corrected some minor ones.
- Made m_cur_analog protected. 
- Fixed pmf delegates to work with msvc.
- More optimizations to the solver code.
- Started work on a better signal pipeline in nlwav
- Only generate documentation for entities which are documented.
[Couriersud]
2017-01-31 22:37:25 +01:00
couriersud
c713f9ed1d Separate include file usage for netlist.
Device implementations (all cpp files in netlist/devices) now should
only include nl_base.h. 
Netlist implementation sources should only include "net_lib.h". 
Refactored netlist.h and netlist.cpp to avoid namespace congestion in
netlist.h.
Fixed VC2015 build. (nw)
2017-01-29 15:47:12 +01:00
couriersud
2720512e31 Solver stuff:
Rewrote mat_cr_t to include data as well. 
Fixed some bitrot in other parts.
Simplified solver creation. (nw)
2017-01-29 15:45:50 +01:00
couriersud
fe8e2a7732 Logging enhancement for Joakim.
For netlist device debugging one can now use 
	#define LOG(...) log().info(__VA_ARGS__)
to use debugging and the known
	#define LOG(...) do {} while (0)
do disable debugging on device level. 

To avoid bitrot one could as well use
	#define LOG(...) log().info.log<true>(__VA_ARGS__)
and
	#define LOG(...) log().info.log<false>(__VA_ARGS__)

The later disables debugging. If the compiler can assume that there are
no side effects from e.g. using foo(a/b), 'LOG("abc {1:04x}",
foo(a/b));' should be completely optimized away.

Log channels available are info, verbose, warning, error and fatal.
Don't use debug, it is enabled only on specific debug builds.

Use would be e.g.
	LOG("abc {1:04x}", 2);
The format specifier in the string are enclosed in "{}". "{2}" is the
second parameter after the format string. Types are determined
automatically. "{3:04x}" would format a number as a hexadecimal with 4
leading zeros.
 
[Couriersud]
2017-01-28 03:54:59 +01:00
couriersud
4eee6b09a9 Fix a hidden bug in the GMRES solver and more optimization. (nw) 2017-01-28 03:54:58 +01:00
couriersud
bd20222866 Fix bug which caused hazl1500 to crash. (nw) 2017-01-28 03:52:42 +01:00
couriersud
cb16de91c6 Minor refactoring. (nw) 2017-01-27 18:38:01 +01:00
couriersud
2e5d1c6cb3 Remove macro to avoid copying and replace with a struct. (nw) 2017-01-27 15:22:19 +01:00
couriersud
6d2354264a Do not derive other classes from std::vector. More cleanup. (nw) 2017-01-27 15:22:18 +01:00
couriersud
5c88873a87 Cleanup of includes. (nw) 2017-01-27 15:22:17 +01:00
smf-
1756a54c74 fix for visual studio (nw) 2017-01-26 12:35:48 +00:00
couriersud
716361fd6a Hopefully fix compile on some unknown compiler. (nw) 2017-01-26 11:03:19 +01:00
couriersud
c4dbd26730 Fix netlist code generation. (nw) 2017-01-26 11:03:18 +01:00
Julian Sikorski
c50ddac28b Fixed building using system utf8proc 2017-01-26 09:28:21 +11:00
couriersud
ba03118b09 More netlist refactoring:
- Remove virtual from some destructors and make them protected. 
- Various cleanups.
- Small performance improvement. 
- Fixed some inconsistencies. 
- More c++ refactoring. (nw)
2017-01-25 22:17:48 +01:00
couriersud
25152bd69a Netlist refactoring:
- Refactored netlist pmf code.
- Small optimization for diode calculations. 
- Minor refactoring across the board. (nw)
2017-01-25 22:17:47 +01:00
couriersud
093bda0193 Added infix notation parsing to the function parser. (nw) 2017-01-25 22:17:46 +01:00
Stiletto
9db7b63e9a Updates "2016" strings to "2017 where relevant.
Updates "2016" strings to "2017 where relevant.
2017-01-24 17:29:49 -05:00
Vas Crabb
edf64df1db srcclean (nw) 2017-01-22 15:37:37 +11:00
couriersud
4d15501a30 Netlist: code refactoring
Make streams provide binary access only. Use putf8_reader and
putf8_writer to actually access streams. Replace some char * parameters
with pstring where appropriate. Minor code refactoring and move
functionality were it belongs. (nw)
2017-01-20 22:29:23 +01:00
couriersud
1ae3e29ea3 Assume string literals are UTF8 in netlist code.
At the same time, any char pointer has to be explicitly converted to
pstring by specifying an encoding. Not yet optimal, but certainly better
than what was there before. 
Removed unneeded methods from pstring. (nw)
2017-01-20 22:20:36 +01:00
couriersud
d0b6742563 Default argument on plib::environment now optional. (nw) 2017-01-20 22:20:35 +01:00
couriersud
167d8405ec Converted warnings and fatal log messages to constants.
Also refactored some code to ease the exercise. (nw)
2017-01-20 22:20:35 +01:00
couriersud
ca11021d73 Netlist:
- refactored reverse polish notation evaluator into own source files.
- added function parameter to current and voltage sources VS and CS.
  You can now use those to e.g. produce a sine wave.
- Changed code to allow devices to optionally be treated as dynamic or 
  timestepping devices.
[Couriersud]
2017-01-17 01:35:16 +01:00
Nigel Barnes
2188df0263 apd_dsk: new floppy format 'Archimedes Protected Disk' 2017-01-16 20:44:43 +00:00
couriersud
7bf2939fd8 Register all devices using NETLIB_DEVICE_IMPL. Fix encoding issue. (nw) 2017-01-16 19:49:45 +01:00
couriersud
969e6ed6a0 Keep track were registry elements are created. (nw) 2017-01-16 19:49:44 +01:00
couriersud
10a4ab4af1 Preparation work for automatically generated include file for devices.
nltool now is able to create all defines from the factory definitions.
This will reduce the number of places needed to touch when adding
devices and always ensure that the parser and statically compiled
netlist code use the same syntax. This will enable us to delete most
device include files, e.g. nld_74107.h. 

Netlist usage to create this header file:
./nltool -c header > src/lib/netlist/devices/nld_devinc.h

This is not yet used in production. It will be enabled after additional
tests.

[Couriersud]
2017-01-16 19:49:43 +01:00
couriersud
c612391f8e Move analog devices into "netlist::analog" namespace. Added
documentation to opamp model. (nw)
2017-01-15 17:56:47 +01:00
couriersud
fd59a10f92 Added more documentation to diode and bjt model. (nw) 2017-01-15 17:56:46 +01:00
couriersud
3cfe098bb2 Introduce a more structured approach to models. (nw) 2017-01-15 17:56:45 +01:00
R. Belmont
72cf75f937 Merge pull request #1974 from shattered/_55d0495
minor floppy internals improvements
2017-01-14 23:41:24 -05:00
Sergey Svishchev
89b7801ebe formats/wd177x_dsk: allow override of build_sector_description, like nec765_dsk 2017-01-15 02:24:48 +03:00
couriersud
674077f89f Prepare source for consistent error message usage. (nw) 2017-01-14 16:35:57 +01:00
couriersud
bce5c521a2 Add code to remove devices connected only to rail terminals. 2017-01-14 16:35:56 +01:00
couriersud
ef8b7ccb6b Core refactoring
- connect_late ==> connect
- register nets where they are created
2017-01-14 16:35:55 +01:00
couriersud
5cd17c361f Fix seldom used conditional build options.
- Fixed OPENMP compile
  For congo bongo, using Solver.PARALLEL=1 significantly increases
  performance from 270% to 380%. However, this has to be taken
  with a grain of salt. Enabling this on predominantly logic netlists
  can severly kill performance.
- Increased readability of timed queue code.
2017-01-12 23:20:23 +01:00
couriersud
b1c3586789 Improve readability and remove some trampolines. (nw) 2017-01-12 23:20:23 +01:00
couriersud
c8c7e9a770 Fix timing issue in CD4538. Add "pow" (power) to the function model.
Minor documentation updates. Slight improvement of gorilla sound. (nw)
2017-01-12 23:20:22 +01:00
couriersud
5b4026d13f - setup_t is owned by netlist_t. Stop being complicated.
- Remove gnd() method. 
- Further simplification.
- Fix potential reset and initialization issues. (nw)
2017-01-12 23:20:21 +01:00
R. Belmont
d7dba2bd78 Merge pull request #1950 from shattered/_3aa32de
misc. fixes exposed by Displaywriter WIP
2017-01-09 21:35:37 -05:00
Sergey Svishchev
4add62a083 TeleDisk loader: accept images produced from 8" SSSD disks 2017-01-10 00:31:25 +03:00
Sergey Svishchev
1fda75a0e2 ImageDisk loader: don't crash on tracks with no data 2017-01-10 00:31:24 +03:00
couriersud
9d3d07b771 Move netlists into macro folder. (nw) 2017-01-09 00:28:31 +01:00
couriersud
9e88fd79ea nlwav now accepts stdin and stdout. (nw)
cat log_RO.1.log | ./nlwav | play -
2017-01-09 00:28:30 +01:00
couriersud
5220572228 Reduce memory footprint for parameters. (nw) 2017-01-08 17:31:29 +01:00
couriersud
233b0b7dbe Decrease memory footprint. (nw) 2017-01-08 17:31:28 +01:00
couriersud
f425f2b997 No need for a virtual stop which is needed only by the solver. (nw) 2017-01-08 17:31:27 +01:00
couriersud
1950ff149a Make stop be called again. Fix METHOD parameter. (nw) 2017-01-08 17:31:26 +01:00
couriersud
e26e327ef9 Rename misleading solver parameters. (nw) 2017-01-08 17:31:25 +01:00
couriersud
d790daa2a7 Remove parameter GS_THRESHOLD. It is now outdated. (nw) 2017-01-08 17:31:24 +01:00
couriersud
ff820d6fa9 Fix regression. (nw) 2017-01-08 17:31:23 +01:00
Justin Kerk
57ac19beee pc_dsk: Handle 1.44MB images with 1,024-byte footer, which have turned up in a couple places (nw) 2017-01-08 01:59:46 -08:00
Justin Kerk
7a8d5118b5 pc_dsk: Assume a smaller gap size to allow 400K disk images to load. Fixes e.g. ikari and marble from the ibm5150 softlist. [Justin Kerk] 2017-01-07 22:28:19 -08:00
couriersud
a841ff553e Fix some clang pedantic warnings. (nw) 2017-01-07 17:29:45 +01:00
couriersud
4dfd26b248 Minor refactoring with focus on a bit more readability. (nw) 2017-01-07 17:29:44 +01:00
couriersud
e788dc5dbe Fix startup when there are no timestep devices present, i.e. Capacitors
or inductors. (nw)
2017-01-07 17:29:43 +01:00
couriersud
59cc0a0d22 Fix stuntcyc regression. (nw) 2017-01-06 01:31:36 +01:00
couriersud
0ebd66d72f intX_fast_t may depend on compiler implementation and thus is not suited
for save states. (nw)
2017-01-06 01:31:35 +01:00
couriersud
47492e4821 Make destructors virtual on base classes. (nw) 2017-01-06 01:31:35 +01:00
couriersud
2c0b627f13 More cleanups. (nw) 2017-01-06 01:31:33 +01:00
Vas Crabb
2c8cd1f083 Merge pull request #1911 from npwoods/imgtool_use_wide_console
[Imgtool] Changed to use wcout/wcerr in order to support Unicode console output
2017-01-05 16:36:55 +11:00
couriersud
02c3f45bff Fix clang "-Wno-weak-vtables" warnings in netlist source. Refactored
code along the way. (nw)
2017-01-05 01:43:31 +01:00
couriersud
67841056da Fix some pedantic clang warnings. (nw) 2017-01-05 01:43:31 +01:00
Miodrag Milanovic
74b24ecefb Added websockets as well (nw) 2017-01-04 19:22:13 +01:00
couriersud
78ef96336e Added SIGFPE enabling code to plib/pexception.*. Moved plib exceptions
into these files as well. The code uses <cfenv> which is part of c++11
standard. Non-standard glib extensions are currently only used on linux
and (i386 or x86_64). (nw)
2017-01-04 18:01:22 +01:00
couriersud
85d1aca315 Minor refactoring and renaming exercise. (nw) 2017-01-04 18:01:21 +01:00
couriersud
93d13d1338 Fix pin assignment 4001. (nw) 2017-01-04 18:01:20 +01:00
couriersud
176258e960 Add FREQ parameter to MM5837 noise generator. Specs in datasheet range
from 24000 Hz to 56000 Hz. Properly use VDD for output reference
voltage. (nw)
2017-01-04 18:01:20 +01:00
couriersud
85949f082c Fix MM5837. (nw) 2017-01-04 18:01:19 +01:00
couriersud
424e2d4097 Fix parsing of macro devices. (nw) 2017-01-04 18:01:17 +01:00
Miodrag Milanovic
63e3f48775 Added initial HTTP/HTTPS webserver/websocket server support (nw) 2017-01-04 16:15:57 +01:00
Nathan Woods
b1eed07ad9 Vas Crabb feedback:
1.  Changed the Win32 code to use _O_U8TEXT()
2.  Reordered system #includes
3.  Changed a number of 'std::wcout << ...' to use util::stream_format()

I'm getting massive code compilation issues, and it isn't clear to me what the problem is.  I'm committing my WIP right now, with the intention of reviewing the specifics soon.
2017-01-04 08:06:20 -05:00
Nathan Woods
3231c3f648 [Imgtool] Changed to use wcout/wcerr in order to support Unicode console output
I really don't like the prevalence of '#ifdef WIN32' in this change, both the _setmode() and bypassing codecvt.  I strongly suspect that the latter is the consequence of some mistake that in practice doesn't cause problems in MSVC.  I welcome all eyes.
2017-01-02 11:59:25 -05:00
couriersud
db7cdcb957 Refactored factory. Use namespace "factory" instead of prefix factory_
all over the place. (nw)
2017-01-02 17:33:21 +01:00
couriersud
9a7b32f29d Simplify code. Introduce consistent approach to loading macro devices.
Changed  nltool "listdevices" command accordingly. Fix some bugs which
surfaced by this exercise. (nw)
2017-01-02 17:33:20 +01:00
couriersud
e84461538c Hopefully fix OSX crashes during netlist setup. (nw) 2017-01-01 17:01:26 +01:00
R. Belmont
e7bc92d930 Merge pull request #1897 from npwoods/introduce_utf8proc
Introduced utf8proc and created wrapper code to expose a prettier API
2017-01-01 08:32:39 -05:00
Nathan Woods
5be1b8e6e0 Introduced utf8proc and created wrapper code to expose a prettier API 2016-12-31 11:17:07 -05:00
couriersud
3a4bc804c0 Hook up luigi walking sound in netlist mario sound implementation.
Mario driver now uses netlist audio implementation instead of discrete
implementation. The previous discrete sound emulation has not been
removed yet because it still contains a lot of documentation.
[Couriersud]
2016-12-31 15:21:05 +01:00
couriersud
0eefe5f02d cstr() ==> c_str() (nw) 2016-12-30 23:42:24 +01:00
couriersud
f1a6e2b47e Align noexcept usage. Rename register_con to add_terminal for clearity.
Fix bug introduced with last commit. (nw)
2016-12-30 23:42:23 +01:00
couriersud
b1516cc7a3 Analog to digital proxy rework. (nw)
Properly handle connected inputs when creating a-d proxy. Aligned a-d
proxy to d-a proxy class structure.
2016-12-30 20:31:14 +01:00
Justin Kerk
44d302c1ab pc_dsk: Support 360K images with 512-byte header, found in some softlist entries. [Justin Kerk] 2016-12-29 14:44:50 -08:00
couriersud
1983580e26 Some preparation for future changes on proxies and chip families. (nw) 2016-12-28 13:48:49 +01:00
couriersud
63f4e52dae Moved proxy code into separate file. (nw) 2016-12-28 13:48:48 +01:00
couriersud
419a7da172 Fix 74629 and some internals. (nw) 2016-12-27 19:37:30 +01:00
couriersud
4ee3f42d36 Fix bug in 74123. (nw) 2016-12-27 19:36:04 +01:00
couriersud
016535b3d0 Simplify. (nw) 2016-12-27 15:19:18 +01:00
couriersud
28a734436e Added "-r" option to nltool to pass path to a folder containing rom
files. Multiple "-r" options may be given. Zip files are not supported,
just individual files. [Couriersud]
2016-12-27 11:25:00 +01:00
couriersud
54cbd67a42 Fix loading roms in two devices. (nl) 2016-12-27 04:33:18 +01:00
couriersud
bf1a504545 Fix nullptr exception. (nw) 2016-12-27 04:33:17 +01:00
couriersud
f43e45a5cf Netlist: Roms now specify an identifier in the netlist.
The identifier is used to load data from a source_t implementation. This
allos a consistent approach in netlists independent of netlist
implementation. Both sources code and parameter code needed quite some
rewrite to support this. [Couriersud]
2016-12-27 02:44:45 +01:00
MooglyGuy
4f3b59ef31 Well, it sorta looks like Stunt Cycle, at least. (nw) 2016-12-26 20:34:03 +01:00
Olivier Galibert
0a4211b73e Gross doesn't even begin to describe it (nw) 2016-12-26 18:55:19 +01:00
MooglyGuy
538d76efe3 -stuntcyc: Added netlist. Currently does not show anything on-screen. [Ryan Holtz] 2016-12-26 12:48:39 +01:00
Vas Crabb
03d486e9b5 netlist: Added LM747, LM747A and 2N2565. 2016-12-26 02:22:25 +11:00
Vas Crabb
127fd9b427 first srcclean pass (nw) 2016-12-25 13:57:31 +11:00
couriersud
8446519012 Netlist: align naming of 9334/make nl_hazelvid.cpp parseable by nltool
Renamed DM9334 to 9334 to align with naming convention used for other
93XX chips.
Added proper connection information for a number of chips to
net_lib.cpp. This allows to parse and run nl_hazelvid.cpp using nltool:

nltool -t 1 -f nl_hazelvid.cpp
2016-12-25 02:07:42 +01:00
MooglyGuy
fbb8ee0fe8 -netlist: Added 82S123 256-bit (32x8) TTL bipolar PROM. [Ryan Holtz] 2016-12-24 22:09:59 +01:00
couriersud
c0da1cee57 Leave more comments on differences between 74107 and 74107A.
Bought two 74107 for an incredible price on eBay :-( (nw)
2016-12-24 01:56:04 +01:00
couriersud
2620b4ccac Fix 74107 and 74107A timings to typical values. (nw) 2016-12-24 01:12:35 +01:00
couriersud
3506240e19 Added inductor to netlist. (nw) 2016-12-24 00:58:36 +01:00
couriersud
c6440a43d4 Remove extra semicolon. (nw) 2016-12-24 00:58:36 +01:00
couriersud
dd785aa19c Leave a note about compatibility of 74161 and DM9316. (nw) 2016-12-24 00:58:34 +01:00
therealmogminer@gmail.com
ad78023dc3 Back out part of my most recent netlist change (nw) 2016-12-24 00:14:23 +01:00
therealmogminer@gmail.com
6a6fdbdb82 Fleshing out nl_stuntcyc a little more (nw) 2016-12-23 23:29:45 +01:00
therealmogminer@gmail.com
9c4c4d0a5b -netlist: Added 82S126 4kbit (512x8) TTL bipolar PROM. [Ryan Holtz] 2016-12-23 23:29:45 +01:00
Sandro Ronco
8f4e1dc37e Archimedes: make floppies work. 2016-12-23 19:41:27 +01:00
Vas Crabb
386eb6b7b8 helps to git add 2016-12-23 15:18:29 +11:00
Vas Crabb
f5bc78c211 netlist: Added 4316 bilateral switch pack. 2016-12-23 14:54:54 +11:00
Vas Crabb
e2ec57aa48 netlist: add uA741 in 8-, 10- and 14-pin DIP variants 2016-12-23 13:39:39 +11:00
therealmogminer@gmail.com
677aaaec3d -netlist: Added 74165, 74194, 7475, 7485, and DM9322 devices. [Ryan Holtz] 2016-12-22 19:39:52 +01:00
smf-
7d7023cc0a fix clang on windows build (nw) 2016-12-22 14:14:55 +00:00
therealmogminer@gmail.com
780732f563 My name is not Ryan 161 (nw) 2016-12-22 01:34:59 +01:00
therealmogminer@gmail.com
0e85817c8a Added a chip burn-down list to atarittl, listing which chips still need to be emulated for Indy 4 and Stunt Cycle (nw) 2016-12-22 01:14:28 +01:00
therealmogminer@gmail.com
2987115966 -netlist: Various fixes: [Ryan Holtz]
* 7473: Made device only transition on a falling clock.
 * 74161: Inverted Clear and Clock inputs to match datasheet.
 * 74260: Fixed number of inputs.
 * Am2847: Fixed shift register size (was 160 bits, should have been 80 bits)
 * DM9334: Inverted C and E inputs to match datasheet.
2016-12-21 20:32:50 +01:00
therealmogminer@gmail.com
66abfa8e6d -netlist: Added shared RAM pointer, for use by netlist RAM devices which need updating by non-netlist driver code. [Ryan Holtz]
-netlist: Added new devices: [Ryan Holtz]
 * Intel 2102A 1Kbit (1024 x 1) Static RAM
 * 74365 Hex Bus Driver with 3-State Outputs
 * Generic 2- and 3-terminal Tristate device
 * Note: Tristate device and 74365 do not actually tristate, they are simply a way of combining multiple outputs + chip enables.
2016-12-21 20:32:49 +01:00
therealmogminer@gmail.com
ac56130251 -netlist: Added 74260 Dual 5-Input NOR Gate device. [Ryan Holtz] 2016-12-21 20:32:49 +01:00
therealmogminer@gmail.com
8dfbe8e538 Minor netlist syntax changes, (nw) 2016-12-21 20:32:48 +01:00
therealmogminer@gmail.com
4a71e6bdcf -netlist: Added 74166 Parallel-Load 8-Bit Shift Register device. [Ryan Holtz] 2016-12-21 20:32:48 +01:00
therealmogminer@gmail.com
e3e38025c3 -netlist: Added 2716 16 Kbit (2 Kbit x 8) UV EPROM. [Ryan Holtz] 2016-12-21 20:32:47 +01:00
therealmogminer@gmail.com
32d0f10418 -netlist: Added 74174 Hex D-Type Flip-Flop with Clear [Ryan Holtz] 2016-12-21 20:32:47 +01:00
therealmogminer@gmail.com
19165cfbfd netlist: Added 82S126 1K-bit bipolar PROM device. [Ryan Holtz] 2016-12-21 20:32:47 +01:00
therealmogminer@gmail.com
72f4f2a20e netlist: Device additions: [Ryan Holtz]
* 74161 Synchronous 4-Bit Binary Counter with Clock
 * 7473 Dual Master-Slave J-K Flip-Flops with Clear and Complementary Outputs
 * Am2847 Quad 80-bit Static Shift Register
 * DM9334 8-bit Addressable Latch
2016-12-21 20:32:46 +01:00
therealmogminer@gmail.com
3fcf6e6a3c -netlist: Add simple ROM hookup capability. [Ryan Holtz] 2016-12-21 20:32:45 +01:00
Vas Crabb
23df89c965 Make bitmaps movable, allowing them to be used in vectors and emplaced easily.
You're still responsible for ensuring you don't move a bitmap while a texture refers to it.
2016-12-15 20:10:36 +11:00
Vas Crabb
be26ac9abf coretmpl: add an associative LRU cache with map-like behaviour
selmenu: use LRU cache so icons don't all need to be reloaded on scroll

uismall.bdf: set default character for missing glyphs

rendfont.cpp:
* encapsulate many BDF and BDC handling details
* make file I/O 64-bit clean, check for allocation errors
* more solid BDF parser with error messages and trace logging
* fix heap smash when building bitmaps for BDF fonts
* extend BDC format to support high planes and default character
* render default character if glyph not found for BDF/BDC
2016-12-15 17:00:34 +11:00
Vas Crabb
c8f1954467 XML refactoring:
* move stuff to namespace util::xml
* scope down some enums
* split config load/save delegate types
* make config load take const so it can't mangle data
2016-12-11 18:15:41 +11:00
Olivier Galibert
962fda50bc delegates: Don't crash on late binding if no object is actually needed [O. Galibert]
pci9050: Fix the mappings [O. Galibert]
2016-12-09 17:23:03 +01:00
Vas Crabb
7238415d1f srcclean (nw) 2016-11-27 09:56:49 +11:00
Scott Stone
30cda1d3e5 A round of spelling/typographical fixes to source comments (nw) 2016-11-24 09:24:01 -05:00
Miodrag Milanovic
dbbd5e9c98 As promised, removing this part of code since it is used for compilers check, no need for this to be in release (nw) 2016-11-23 08:37:05 +01:00
Vas Crabb
0757bf61fd Work around buggy standard libraries (nw) 2016-11-21 07:48:43 +11:00
Vas Crabb
8179a84458 Introduce u8/u16/u32/u64/s8/s16/s32/s64
* New abbreviated types are in osd and util namespaces, and also in global namespace for things that #include "emu.h"
* Get rid of import of cstdint types to global namespace (C99 does this anyway)
* Remove the cstdint types from everything in emu
* Get rid of U64/S64 macros
* Fix a bug in dps16 caused by incorrect use of macro
* Fix debugcon not checking for "do " prefix case-insensitively
* Fix a lot of messed up tabulation
* More constexpr
* Fix up many __names
2016-11-19 05:38:48 +11:00
Vas Crabb
1b12a8940b gah, wasn't quite compatible (nw) 2016-11-17 21:04:52 +11:00
Vas Crabb
346e0a8a92 more xmlfile cleanup (nw)
* an empty tag and a self-closing tag are semantically equivalent, so std::string can be used saving some manual allocation
* a valid tag can't have an empty name, so that can be std::string too
* still expose empty strings as nullptr to API users
* scope down the int_format enum
* # is not £ ffs
2016-11-17 20:38:38 +11:00
Miodrag Milanovic
8a22a1f14d Reverting this change, it is compiler bug, confirmed by Microsoft VSO#292426 (nw) 2016-11-17 08:08:53 +01:00
Miodrag Milanovic
d5bf30edb8 Fix compilation under VS2017 (nw)
default_semantics is used by apply so need to be public
2016-11-16 21:00:29 +01:00
Vas Crabb
2354a42010 Turn xmlfile API into something that looks like C++
It's still a bit quirky but it's far better encapsulated before, and it plays nice with const (nw)
2016-11-17 01:44:03 +11:00
Vas Crabb
4d481a075a fix up pstring code (nw)
* instantiate static constant members for ODR context
* declare static members of template classes properly
* declare external template instantiations
* fix blind use of autocomplete ("treats" really?)
* fix ptype_traits on platforms where char is unsigned
* signed char is never an alias for char even if char is signed
* even if eclipse doesn't like using type, surely it supports typedef
2016-11-16 06:46:05 +11:00
Miodrag Milanovic
e71e37e54f Revert "using of IS_ENABLED in files used in tiny build (nw)"
This reverts commit 1efccdd38d.
2016-11-12 09:12:35 +01:00
Miodrag Milanovic
2131d9ad3a Revert "Use true/false if type used is bool (nw)"
This reverts commit dbd07cef38.
2016-11-12 09:12:35 +01:00
Miodrag Milanovic
dbd07cef38 Use true/false if type used is bool (nw) 2016-11-11 20:50:25 +01:00
Miodrag Milanovic
1efccdd38d using of IS_ENABLED in files used in tiny build (nw) 2016-11-11 20:43:19 +01:00
Miodrag Milanovic
7c765ea147 No need for osd_malloc, osd_malloc_array and osd_free (nw)
MALLOC_DEBUG not applicable anymore since we use new to allocate in 99.9% of cases
2016-11-11 16:12:01 +01:00
Miodrag Milanovic
ef51470515 delegate fix - lambda always have object (nw) 2016-11-08 08:14:28 +01:00
Miodrag Milanovic
689cf4d947 typo fix (nw) 2016-11-07 13:14:48 +01:00
Miodrag Milanovic
fc58a0bec8 Added basic HTTP server, not active yet, based on ASIO example with small refactoring included (nw) 2016-11-07 10:42:23 +01:00
smf-
e565b0c6aa Fix heap corruption when loading a new chd fails. Throw CHDERR_FILE_NOT_WRITEABLE rather than CHDERR_UNSUPPORTED_VERSION if you try to open an old version for writing [smf] 2016-11-06 16:50:35 +00:00
Miodrag Milanovic
2027d59e7f Do not use FUNC in delegate where applicable (nw) 2016-11-06 14:11:55 +01:00
Miodrag Milanovic
4a096d1ccb try to make GCC 5.4.0 happy (nw) 2016-11-05 20:36:08 +01:00
Miodrag Milanovic
dedf3c9b9d Delegate support for lambdas and std::functions in general, also supporting const members now [Miodrag Milanovic] 2016-11-05 20:26:04 +01:00
Vas Crabb
c15306c628 fixum (nw) 2016-11-05 00:35:09 +11:00
Joakim Larsson Edstrom
f1a1b77595 Added 'poke' and 'clear' methods to fifo template 2016-11-04 14:13:00 +01:00
Vas Crabb
c96ed5b4a6 there you go, Robbbbbbbbert (nw) 2016-11-01 21:11:25 +11:00
Vas Crabb
e7d31b6009 add a fifo template in util for Edstrom 2016-11-01 20:14:03 +11:00
Jordi Mallach
94220aa08b Misc typo fixes. 2016-10-27 13:45:15 +02:00
therealmogminer@gmail.com
347b8cd925 More ie15 optimizations, nw. Also removes cache-line padding of dubious performance value in core bitmap class in favor of behavior of least surprise 2016-10-23 14:22:07 +02:00
Miodrag Milanovic
aa2e6f9df3 Reverting part of changes from previous commits as described in mail on list (nw) 2016-10-23 09:11:47 +02:00
AJR
b83078eb46 Erase bitmap_rgb32::erase (nw) 2016-10-22 22:30:09 -04:00
AJR
7d41a1f619 Improvements to rgb_t (nw)
- Make most class methods constexpr
- Make color constants (white, black, etc.) into constexpr factory methods, in order to fix a static initialization problem discussed on the MAMEWorld forums.
  (Note that while C++14 allows constexpr member variables to be initialized outside classes, current compilers' support for C++14 constexpr rules has proven to be lamentably deficient.)
- Create bitmap_rgb32::erase to simplify syntax in update handlers
2016-10-22 18:45:04 -04:00
Miodrag Milanovic
e42ed88254 there you go (nw) 2016-10-22 21:37:06 +02:00
Miodrag Milanovic
fc340e9e7d cleaning "mess" for OCD people (nw) 2016-10-22 21:23:44 +02:00
Miodrag Milanovic
88b5a5c09f Cleanup linux OSD (nw) 2016-10-22 18:42:47 +02:00
Miodrag Milanovic
a6bdefec8c more TRUE/FALSE cleanup (nw) 2016-10-22 16:37:12 +02:00
Miodrag Milanovic
ddb290d5f6 NOTICE (TYPE NAME CONSOLIDATION)
Use standard uint64_t, uint32_t, uint16_t or uint8_t instead of UINT64, UINT32, UINT16 or UINT8
also use standard int64_t, int32_t, int16_t or int8_t instead of INT64, INT32, INT16 or INT8
2016-10-22 13:13:17 +02:00
Miodrag Milanovic
23ad94073f use standard types uintptr_t, char16_t and char32_t instead of FPTR, utf16_char, unicode_char (nw) 2016-10-22 11:31:49 +02:00
Miodrag Milanovic
d2e8f61149 dynamic_buffer is just std::vector<UINT8> (nw) 2016-10-21 12:35:05 +02:00
Miodrag Milanovic
a291e77b2c some bool <-> int not needed conversions, also cleaned drivenum.* was using memset for clearing vector (nw) 2016-10-21 11:54:18 +02:00
Vas Crabb
33b2c73395 srcclean (nw) 2016-09-26 04:51:59 +10:00
therealmogminer@gmail.com
239d09546f Bad OG, no cookie, nw either 2016-09-25 01:29:22 +02:00
Nathan Woods
1a017c9302 Consolidated code that inputs characters into buffers 2016-09-19 08:25:10 -04:00
Michael Zapf
2bf93a51e8 Added HxC HFE disk format. 2016-09-18 12:31:13 +02:00
Nathan Woods
c51de7aa95 Fixed a potential buffer overrun in the code that reads headers for the CoCo JVC disk image format 2016-09-13 06:50:08 -04:00
Nathan Woods
aea10e0b4d Alphabetizing the #include's, and added typedef's for the reverse iterators 2016-09-12 20:56:32 -04:00
Nathan Woods
86e242472f Fixed some stupid errors 2016-09-12 20:45:43 -04:00
Nathan Woods
714b78d084 Folded util::contiguous_sequence_wrapper<T> into coretmpl.h, and fixing the reverse_iterators 2016-09-12 20:33:05 -04:00
Nathan Woods
88c952adb3 Forgot to remove these m_ptr's 2016-09-12 18:45:10 -04:00
Nathan Woods
524d750106 Implementing util::contiguous_sequence_wrapper<T>::[c]r[begin|end]()
...correctly (I think).  Since we're not actually using this it isn't really tested
2016-09-12 07:51:15 -04:00
Nathan Woods
af1c5b26b8 Renamed util::view<T> to util::contiguous_sequence_wrapper<T>, changed ::iterator and ::const_iterator to just be pointers and other cleanups 2016-09-12 06:56:55 -04:00
Nathan Woods
91fb8f5bc3 Introduced an STL container for a view (util::view<T>), and changed opresolv to use it 2016-09-11 10:49:23 -04:00
Nathan Woods
cc70910693 Subscripting std::array<..., 0> is bad; working around this specific case 2016-09-10 15:16:45 -04:00
Vas Crabb
6a2b41aa0b Merge pull request #1332 from npwoods/option_guide_and_imgtool
option_guide C++-ification, touched up imgtool
2016-09-10 10:15:30 +10:00
Nathan Woods
b5a2d1bc77 Changing an 'assert(false)' to 'throw false', so that this always errors even in non-debug builds 2016-09-09 06:59:54 -04:00
Nathan Woods
402d84ff34 Properly catching another out of memory condition 2016-09-09 06:29:40 -04:00
Michael Zapf
44e74fcc99 ti99: Explicitly add the cell_size to mfm_w call (nw) 2016-09-05 00:08:09 +02:00
Nathan Woods
4251194fe5 Worked around the OPTION_GUIDE_EXTERN issue by using a crazy trick involving namespaces
Caveats:
  1.  Because of how this trick works, it is no longer possible to declare an option guide as static, so I had to make a bunch of changes
  2.  I'm going to want the hardcore C++ guys (i.e. - Vas) to review this with a fine toothed comb
2016-09-03 16:11:58 -04:00
Nathan Woods
be3c18302e Figured out a slightly better way to make the option guide macros to work
I was able to eliminate the need for a dummy entry at the end
2016-09-03 08:12:51 -04:00
Nathan Woods
965fb61f95 Attempting to make option_guide and option_guide::entry POD types; need to figure out a better way to do OPTION_GUIDE_EXTERN 2016-09-02 23:52:30 -04:00
Nigel Barnes
a7946f9c61 added header checks to identify in uef_cas and csw_cas formats 2016-09-02 21:47:02 +01:00
Nathan Woods
9c06ec0b6a Incorporating Vas Crabb feedback 2016-09-01 06:49:54 -04:00
Vas Crabb
46bf1ce04b More cleanup on the back of Osso's fix for a7e393b36b (nw)
* Make iterators actually meet requirements of ForwardIterator (and by consequence, ForwardIterator, Iterator and EqualityComparable)
* Don't use function statics if they can be avoided - it isn't thread-safe
* Remove leftover crud from when dynamic_buffer and friends were templates in lib/util

It's still dangerous that the const behaviour of iterators doesn't match STL.
Also, simple_list members with similar functionality to STL container members should be renamed.
2016-08-30 01:31:23 +10:00
Vas Crabb
c960435d3e srcclean and translation regeneration 2016-08-29 02:02:04 +10:00
Nathan Woods
b60879e595 option_guide C++-ification, touched up imgtool
The main point of this change is to C++-ify option_guide.  It was changed from a struct array to a class, namespaced etc, with the ultimate hope of incorporating an in-emulation image creation UI.

Imgtool got hit with a number of changes; I'll probably have to bring that off of the backburner and touch that up too
2016-08-27 16:41:11 -04:00
Miodrag Milanovic
62fe8b8980 some C++14 features are not supported by VS2013. VS2015 is free for home use so no need for legacy support (nw) 2016-08-27 11:15:38 +02:00
Vas Crabb
6e47d26589 gah how did I miss that (nw) 2016-08-27 17:02:11 +10:00
Vas Crabb
75be4dff5f While I'm causing full recompiles all the time, reduce necessary number of instantiations of parts of string formatting engine 2016-08-27 16:45:53 +10:00
Michael Zapf
596b04dd5c ti99: Fixed another issue with double stepping. 2016-08-25 19:26:46 +02:00
Michael Zapf
bade8ef9a9 ti99: Forgot to reset the TRACE flag. 2016-08-24 14:53:01 +02:00
Michael Zapf
294e196532 Forgot srcclean 2016-08-24 14:25:01 +02:00
Michael Zapf
19a2c632ae ti99: Fix a problem with formatted disk images that do not match the expected file size 2016-08-24 14:25:01 +02:00
Nathan Woods
846cd43287 Performs argument checking on the return value of CassetteLegacyWaveFiller.chunk_sample_calc()
This is just better error checking.  You can see this if you create a garbage file named 'foo.csw' and invoke the following command:

	mame bbcb -cass1 foo.csw

With this change you get an invalid image error.  Without it, you get this:

	Caught unhandled St12length_error exception: vector::_M_default_append
2016-08-23 07:56:48 -04:00
Nathan Woods
16d4c4e358 Fixed regression with cassette code that caused hangs to happen when loading cassette image formats that lacked read/write support
This entailed reintroducing device_image_interface::make_readonly(); I also reimplemented the feature in the cassette code in a less hacky way.
2016-08-20 22:42:53 -04:00
Nathan Woods
d1227cb38f casserr_t ==> enum class cassette_image::error 2016-08-20 19:59:04 -04:00
Nathan Woods
02b9749216 Stop forcing cassette image create when loading zero-length images. Also minor C++-ifications to cassette code (usage of bool and std::string, C++ comments) 2016-08-20 16:58:24 -04:00
Nathan Woods
d3b374d545 Fixed an issue with legacy floppy loading caused by filetype() now being a std::string
This caused 'mame a800 -flop1 brucelee' to fail on startup, but after this fix the image mounts but incorrectly.
2016-08-18 21:25:28 -04:00
Curt Coder
278cb2fc4e abc80x: Fixed ABC-838 disk image cell size. [Curt Coder] 2016-08-15 16:05:49 +03:00
Michael Zapf
bec5bd5022 hdc92x4: Added 9224 emulation; ti99_dsk: Fixed issue with deleted data marks in FM 2016-08-14 21:48:23 +02:00
Curt Coder
6a1ac985d4 victor9k: WIP. (nw) 2016-08-14 17:32:19 +03:00
Curt Coder
20127228a0 victor9k: Set floppy RPM after track step. Boots to CP/M now. [Curt Coder] 2016-08-12 15:15:14 +03:00
couriersud
d0970c215f Add a preliminary parser for RINF netlist format. (nw) 2016-08-10 23:08:35 +02:00
Miodrag Milanović
f67311c5a5 Merge pull request #1180 from npwoods/split_softlist_code_redo
Redo of split of src/emu/softlist.[cpp|h]
2016-08-08 13:43:06 +02:00
couriersud
7b8179bb04 Add target minw to standalone netlist makefile. (nw) 2016-08-07 22:28:06 +02:00
couriersud
8c297602c4 Fix noexcept and NL_NOEXCEPT to pass g++ 6.x builds. (nw) 2016-08-07 22:28:04 +02:00
Miodrag Milanovic
3751d8aa60 removed NL_NOEXCEPT since there is a case when these calls throws exceptions (nw) 2016-08-07 11:11:43 +02:00
AJR
2f312c14d2 More consistent use of NL_NOEXCEPT macro to fix debug build (nw) 2016-08-06 21:47:57 -04:00
couriersud
5b1d15383d Use noexcept in netlist code where appropriate.
Use macro NL_NOEXCEPT if debug builds would throw an exception (e.g. by
using nl_assert). This is not entirely safe. Going forward, nl_assert
should call log first and than throw. (nw)
2016-08-07 01:44:55 +02:00
couriersud
7a7c123d1e Added doc target to netlist makefile. Removed old style cast. (nw) 2016-08-06 19:22:29 +02:00
couriersud
20a584b348 Various netlist fixes:
- minor include cleanup
- fix a memory hole (caused by assign operators)
- more C++.
2016-08-06 19:22:28 +02:00
Nathan Woods
c77310389e Removed src/lib/util/cstrpool.[cpp|h]; it is no longer used 2016-08-05 08:29:32 -04:00
Vas Crabb
8e07fb8117 Fix UTF-16 encode, pass UTF-16 to Windows character drawing (unfortunately still no nice speaker icon) 2016-08-02 18:24:14 +10:00
Vas Crabb
889ecdfd4f Let's give the new srcclean a spin... 2016-08-02 16:59:02 +10:00
Nathan Woods
59ca4d1763 1. Merge branch 'master' into diimage_filetype_as_stdstring
2.  Introduced is_filetype(), instead of normalizing filetype() to lower case
2016-07-31 23:52:57 -04:00
Nathan Woods
a4f24a24d3 This changes device_image_interface::filetype() to return 'const std::string &' instead of 'const char *'.
In the interests of removing burdens from client code, I also changed the following:
- filetype() will always return the file extension in lower case
- device_image_interface::filetype() will return the correct extension for files loaded as a part of softlists
- The code for extracting a file extension is now encapsulated in core_filename_extract_extension()

Client code has been updated
2016-07-31 15:06:06 -04:00
Miodrag Milanovic
6f5e223853 for bool type use true and false (nw) 2016-07-31 20:02:56 +02:00
Vas Crabb
a0ce6c3b37 fix after pass through the diff 2016-08-01 01:20:03 +10:00
Miodrag Milanovic
f127621e13 made constexprs lower case and used constexpr for returning input value as well for rest of defines in osdcomm.h (nw) 2016-07-31 16:47:26 +02:00
Miodrag Milanovic
eaa70ae031 cleanup of some conversions (nw) 2016-07-31 16:41:26 +02:00
Miodrag Milanovic
d91322223b fixed clang (nw) 2016-07-31 15:59:39 +02:00
Miodrag Milanovic
aeadbfe2b1 fix linux compile (nw) 2016-07-31 14:59:01 +02:00
Miodrag Milanovic
9667c6a8cc std::min and std:max instead of MIN and MAX, also some more macros converted to inline functions (nw) 2016-07-31 14:41:02 +02:00
Nathan Woods
bfbc8d38f1 Another correction 2016-07-29 22:20:53 -04:00
Nathan Woods
8db5491763 Third time is a charm :-) 2016-07-29 22:14:51 -04:00
Nathan Woods
22c402885d Better use of std::string::size_type and other cleanups 2016-07-29 21:51:55 -04:00
Nathan Woods
bf111bbc6e Converted a number of zippath calls that took 'const char *' to std::string 2016-07-29 18:00:46 -04:00
Nathan Woods
3ac2d79f09 Adding an assert() 2016-07-27 07:59:43 -04:00
Miodrag Milanovic
4887ce1844 Cleanups and version bump 2016-07-27 09:26:22 +02:00
MetalliC
85488e4328 chdman: set pregap subcode type to NONE for .CUE and .TOC for consistency with other formats 2016-07-25 20:24:59 +03:00
R. Belmont
e681889d88 Merge pull request #1139 from GiuseppeGorgoglione/master
Fix for netlist library when built for WINDOWS with UNICODE defined
2016-07-24 14:42:37 -04:00
MetalliC
0c85178c1e chdcd: fix >2GB .iso parsing 2016-07-24 14:30:32 +03:00
Giuseppe Gorgoglione
1344df7496 Fix for netlist library when built for WINDOWS with UNICODE defined
When UNICODE is defined LoadLibrary is redefined to LoadLibraryW which expects a widechar string as library name, while libname is always UTF8. Fixed copying TCHAR conversion code from strconv.cpp since netlist is meant to be also a stand-alone library.
2016-07-24 13:27:08 +02:00
Nathan Woods
4aa0ab1724 Moved src/emu/hash.[cpp|h] into src/lib/util, and namespaced that code (and hashing.[cpp|h]) into util:: 2016-07-23 12:49:33 -04:00
couriersud
1e40d95e8b Netlist updates:
- Removed trampolines (OUTLOGIC, INPLOGIC and friends). 
- Started using doxygen comment and documentation style. Added doxygen
files to documentation folder. 
- Refactored code triggered by doxygen output. 
- Moved internal and support classes into namespace detail. 
- Use an anordered map in parser. 
- -Wconversion fixes - All done now. 
- Fixed -Wold-style-cast warnings in netlist code. 
- Added iterators to pstring. 
- Moved two macros, added more RAII and improved exceptions. Fixed some
bugs in parser code. 
- Fixed a number of bugs in parser code and exception handling. 
[Couriersud]
2016-07-21 11:05:55 +02:00
ImJezze
89af2864ed Fixed MT #6291
* fixed copy of texture data to bitmap in BGFX
* changed AVI dimension to a lowest integral multiple of 4
  (2 was still to low for most video players, e.g. VLC)
* added audio to AVI record in HLSL
* HLSL AVI record now uses window dimension instead of snap dimension
2016-07-16 20:54:37 +02:00
Nigel Barnes
9104c9d523 renamed bbc_dsk to acorn_dsk
- split ssd/dsd formats
- added opus ddos format
- split adfs into oldmap and newmap formats for archimedes
- logging
2016-07-16 19:48:44 +01:00
Nigel Barnes
97c122ca4f fsd_dsk: more logging (nw) 2016-07-16 19:48:44 +01:00
ImJezze
6a592feca9 Added generic fix for #6286
- this does not fix #6291
2016-07-16 14:42:41 +02:00
Olivier Galibert
9eb57470c9 Fix archimedes disk format [O. Galibert] 2016-07-15 12:43:40 +02:00
Vas Crabb
31c4a81369 misc fixes (nw)
* remove a temporary
* fix deps
* remove a vestigial member
* play nicer with dotfiles
* play nicer with pch
2016-07-12 13:09:42 +10:00
Nathan Woods
210d5cb451 Fixed issue that could cause core_filename_ends_with() to return true when extension.size() > filename.size() 2016-07-11 18:05:23 -04:00
Nathan Woods
32230ae648 Adding a check for reverse overflow when extensions is longer than filename 2016-07-11 10:46:36 -04:00
Nathan Woods
0e4cb93bc5 Adopting std::find() and std::find_if() in core_filename_extract_base() 2016-07-11 10:20:56 -04:00
Nathan Woods
2bd5932b42 Deeper C++-ification 2016-07-11 08:27:03 -04:00
Nathan Woods
09b3fbf52c C++-ification of some corefile static functions 2016-07-10 23:38:44 -04:00
couriersud
011dbbe713 Moved two macros, added more RAII and improved exceptions. Fixed some
bugs in parser code. (nw)
2016-07-09 00:13:18 +02:00
Nathan Woods
a2ce6a9ca4 Changed some int's to size_t's and added assertions where we were assuming that option_resolution was a requirement 2016-07-07 19:48:36 -04:00
Nathan Woods
e3cb2c7d78 C++-ification of src/lib/util/opresolv.[cpp|h] (moved to util:: namespace, changed option_resolution to be a class, etc) 2016-07-07 06:59:35 -04:00
Nathan Woods
bdf2059bf4 As per Vas Crabb, readding overloads that take a std::string& parameter for the result 2016-07-04 23:22:37 -04:00
Nathan Woods
de6bbdf176 Changed a few zippath related functions to return their strings as a return value, as opposed to passing in a destination buffer 2016-07-03 13:28:09 -04:00
Nathan Woods
587e9f5e32 Changed zippath.[cpp|h] to use C++-style comments 2016-07-03 13:21:09 -04:00
Vas Crabb
cde4eddeb3 override without virtual looks uncomfortable (nw) 2016-07-03 14:02:26 +10:00
Nathan Woods
d67695e724 Converted menu_file_create to use std::string for its filename buffer 2016-07-02 14:23:54 -04:00
Nathan Woods
facb76a669 C++-ification of src/lib/util/unicode.[cpp|h] 2016-07-02 14:22:14 -04:00
couriersud
caafc0f782 Netlist improvements:
- nltool now accepts -Ddefine=value to pass on to netlists
- improved option handling and added "dummy" options to add grouping and
  examples in help output.
- improved --cmd=listdevices output
- Fix dynamic timestepping. This will work with breakout using real
  capacitor modelling instead of delay devices. Really slow, but very
  useful to calibrate timings.
- Fix an awful bug in timing for delay devices.
- Switched to clang 3.8 and made code compile with
  -Weverything -Werror -Wno-old-style-cast -Wno-padded -Wno-weak-vtables
  -Wno-missing-variable-declarations -Wno-conversion -Wno-c++98-compat
  -Wno-float-equal -Wno-cast-align -Wno-global-constructors
  -Wno-c++98-compat-pedantic -Wno-exit-time-destructors
  -Wno-format-nonliteral -Wno-weak-template-vtables
  This was a helpful exercise since it brought forward some 
  serious issues with implicit constructors. 
[Couriersud]
2016-07-01 02:09:14 +02:00
Miodrag Milanovic
63f9a01f8c Cleanup and version bump 2016-06-29 08:34:30 +02:00
Vas Crabb
923151d00b Fixed incorrect implementation of win_time_point_from_filetime() 2016-06-26 22:44:21 +10:00
Nathan Woods
5009b55430 Introduced src/lib/util/timeconv.[c|h], moved code from un7z.cpp into it, and implemented win_time_point_from_filetime() in terms of it 2016-06-26 08:12:07 -04:00
Brad Hughes
fb54827cb4 Fix Clang compile on OSX 2016-06-25 20:47:02 -04:00
Miodrag Milanovic
f75a33f7d1 clang on windows fixes (nw) 2016-06-25 20:06:02 +02:00
Vas Crabb
7f22918675 Supply modified time for files in archives [Vas Crabb] 2016-06-25 20:56:59 +10:00
arbee
7ff2301047 fix Clang build. it still fails b/c of the file and directory stuff. (nw) 2016-06-24 21:13:46 -04:00
couriersud
af750f143c Srcclean on netlist files. Avoid the merge massacre. (nw) 2016-06-25 00:20:17 +02:00
couriersud
798bb79567 Merge remote-tracking branch 'origin/master' into netlist_dev 2016-06-24 23:28:42 +02:00
couriersud
bc37304ef9 Add explicit to constructors to avoid bad surprises later. (nw) 2016-06-24 23:25:46 +02:00
Vas Crabb
5cee9e9bc4 POSIX implementation for new directory read features, cleanup of Windows implementation, return directory handle as smart pointer, fix full build [Vas Crabb] 2016-06-25 03:35:23 +10:00
couriersud
634473c1ff Merge remote-tracking branch 'origin/master' into netlist_dev 2016-06-24 17:45:46 +02:00
couriersud
d1cd307f83 Remove shared_ptr usage and replace with plib:owned_ptr. Clean up nltool
a bit. (nw)
2016-06-24 17:45:17 +02:00
Vas Crabb
20a95045e1 Load save state preparations [Nathan Woods]
* A number of changes and refactorings in preparation for a new load/save state menu. Most notably, I am C++-ifying osd_directory (now osd::directory) and changing osd_stat() to return std::unique_ptrosd::directory::entry
* Take note that this change completely omits POSIX support, simply because I lack a development environment to support it. This will have to be done by someone else.
2016-06-24 23:53:38 +10:00
Nathan Woods
4ddfc6a6e4 Changed osd_stat() to return std::unique_ptr<osd::directory::entry> 2016-06-24 07:39:37 -04:00
Nathan Woods
cd8b414e6b C++-ified osd_directory (now osd::directory), and added last_modified to osd::directory::entry 2016-06-24 07:13:18 -04:00
Vas Crabb
15f02da7bd Improved workaround for missing cbegin/cend in glibstdc++ [Alex Miller] 2016-06-24 19:56:50 +10:00
couriersud
c6e6911aed Netlist changes
- Replaced shared_ptr by unique_ptr. 
- Better seperation of setup_t and netlist_t. 
- Fixed bugs in rdtsc code. Refactored timer code. 
- Simplify conditional activation/deactivation. 
- Introduced HINT(device, hint) to clarify that hints are inheritent 
  and not specific to devices. 
- Added improved profiling support to netlist. Statistics output now
  proposes devices for which whole device activation/deactivation be
  disabled. No significant improvement for pong, but breakout
  experiences a 10% improvement. 
- Moved options code from include to cpp file.
- Minor modifications to 7493 and 9316
- Introduced perftime_t and perfcount_t for gathering statistics. These
  templates do not create any code if statistics are not kept.
- Make help2man ./nltool produce usuable output. 
- More truthtable refactoring. Removed half-finished code for internal
  state support. As implemented, this would have had no support for
  timing delays. 
[Couriersud]
2016-06-23 02:04:51 +02:00
Nathan Woods
5619297374 Added rgb_t::transparent constant 2016-06-18 14:03:50 -04:00
Miodrag Milanovic
1d0e0ac12a remove all usages of tagmap 2016-06-18 15:32:15 +02:00
Olivier Galibert
7099d6eaa2 gcc 6.1.1 warning fixes (nw) 2016-06-16 14:21:44 +02:00
couriersud
404e589cff Merge netlist_dev branch, all code_refactoring: (nw)
Object model optimisation. 
    Merge remote-tracking branch 'origin/master' into netlist_dev
    Fix a merge issue. 
    #if ==> #elif. Ouch. 
    Default PHAS_PMF_INTERNAL=0 for 32bit windows mingw. 
    Change UINT8 to uint_[fast|least|8_t. 
    Move state_var so it can be used by base devices as well. 
    Remove last traces of ATTR_ALIGN. 
    Refactored netlist_time into a template.
    Removed implicit double assignment to netlist. Doomed to produce
bugs.
    Instead, use netlist_time::from_double.
    Switch to using proper (i.e. bool type) param_logic_t. 
    Formally differentiate between logic inputs (e.g. switches) and int
    inputs (e.g. resistor ladders or selection switches). 
    Added parameter USE_DEACTIVATE to truthtable devices.
    Added more constexpr to netlist_time.
    Fixed some ifdef code paths.
    - More c++.
    - Simplify main processing loop. As a nice side-effect that squeezed
out some cycles.
    - More cycle squeezing.
    - Removed pvector_t.
    - Use std::sort.
    - Refactored netlist state manager.
    - Introduction of state_var object template to be used on device
state
    members.
    - Changed remaining save occurrences to state_var.
    - Rewrote nltool's listdevices command. This allowed removal of one
    member from devices which served solely for listdevices.
    - Remove hashmap_t. Fix kidniki regression.
2016-06-16 00:01:47 +02:00
Robbbert
13526f680b MT 06236 [Robbbert] 2016-06-15 23:27:01 +10:00
Robbbert
309d977066 MT 05783 [Robbbert] 2016-06-12 00:01:38 +10:00
couriersud
bf281b3cad add cmath include to plists.h 2016-06-07 23:27:03 +02:00
couriersud
d6616e1786 Fix travis build. (nw) 2016-06-07 23:13:34 +02:00
couriersud
81880659d2 - More code cleanup.
- Dead code removal and minor refactoring.
- Simplify. Align naming with stl. Fix somed pedantic warnings.
- More STL compatability.
- Remove ATTR_HOT and ATTR_COLD. Refactored netlist_time. 
- Fix long standing workaround which would ignore policy of change-only"
propagation.
- Rewrote for loops to use auto : semantics.
- Truthtable cleanup. (nw)
- Get rid of nl_math. Remove nl_util.h and moved contents to
plib/putil.h.
- Fix standalone build. Refactor ptypes.h. 
[Couriersud]
2016-06-07 21:44:15 +02:00
couriersud
3d3f5761f0 - Added constructors to prepare to move terminal setup into constructor.
- Reworked twoterm setup. Fixed some timebombs along the way.
- Fix r2r dac. Remove dead code.
- analog_outputs now created in constructor.
- moved analog_input creation into constructor. 
- moved logic output creation to constructor.
- moved all logic inputs into constructor.
- Completely removed init_object. Finally. 
[Couriersud]
2016-06-07 21:41:54 +02:00
balr0g
b277908905 - Minor cosmetic refactoring. Added a "uninitialised array" template to
allow in-place creation (for increased locality) of netlist classes.
Main use is in truthtable class.
- Remove PLIB_NAMESPACE macros.
- Remove namespace macros. Use explicit namespace declarations.
- Moved device definitions into cpp files.
- Moved more device definitions into cpp files.
- New prefix "nlid" for include files flags purely internal include
files not to be leaked into userland. 
- Fix factory code.
2016-06-07 21:40:30 +02:00
Nigel Barnes
55724435b2 fsd_dsk: logging (nw) 2016-06-05 22:53:37 +01:00
Nigel Barnes
e4ea1303b3 e01: added acorn filestore floppy format and softlist 2016-06-05 22:53:37 +01:00
Robbbert
bb10b1beb0 sorcerer: calculate baud rates based on actual dividers on pcb. Fixed a bug with quickload. 2016-06-05 23:27:46 +10:00
MetalliC
2cea059009 chdman: attempt to workaround hang during chd creation
TODO: find out its real cause
2016-06-04 19:44:53 +03:00
Vas Crabb
6b9c752850 misc fixes (nw)
* fix a mismatched new[]/delete error in corealloc
* _name massacre in corealloc while at it
* add template/macro for delaring array with equivalent dimensions
2016-05-28 15:10:28 +10:00
couriersud
5d7f5d6c22 Fix pongf. (nw) 2016-05-27 17:23:16 +02:00
smf-
f1f681e642 build with MSVC (nw) 2016-05-27 15:12:13 +01:00
couriersud
02e3213897 Leading underscore massacre. (nw) 2016-05-27 01:20:09 +02:00
couriersud
fd62273a87 Moved more code into plib namespace. (nw) 2016-05-27 01:19:59 +02:00
couriersud
111c5a3dc0 Remove dependency on osd_ticks. Converted palloc and friends into
templates. First effort on a separate plib namespace. (nw)
2016-05-27 01:17:39 +02:00
couriersud
f5179f7ec8 Make netlist compile with c++11, use own implementation of make_unique
to avoid c++14. (nw)
2016-05-25 14:52:40 +02:00
couriersud
cac1c41edf Moved all parameter definitions in constructors. (nw) 2016-05-25 14:31:43 +02:00
couriersud
c97c3ae855 Fixed breakout attract mode. (nw) 2016-05-25 13:43:23 +02:00
Miodrag Milanovic
68785dccfe Cleanups and version bump 2016-05-25 08:19:21 +02:00
Miodrag Milanovic
b0d3ce6877 fix android build (nw)
please do not use _ prefixed names, those are reserved
2016-05-24 10:52:26 +02:00
Miodrag Milanovic
d6d177a29d Fixed multiple instance of operator = , fixes VS build (nw) 2016-05-22 09:06:50 +02:00
couriersud
53e66cf6aa Fix VS c++ compile following
https://msdn.microsoft.com/de-de/library/ms177415.aspx
2016-05-21 14:33:15 +02:00
couriersud
ee5b02ebfb Added == operator to netlist_time 2016-05-21 13:31:18 +02:00
couriersud
fdf63818de All netlist devices now follow new syntax. Removed dead code. All sub
devices are now forced to be initialized in the constructor. Device
setup now completely in constructor. Removed start call. [Couriersud]
2016-05-21 13:31:17 +02:00
couriersud
9102271ef7 More memory timebombs removed. (nw) 2016-05-21 12:58:24 +02:00
couriersud
d200744fbf Converted more devices to new layout. Improved memory handling in
factories. (nw)
2016-05-21 12:58:23 +02:00
Vas Crabb
ce21ce6410 Bad boy, Micko (nw) 2016-05-19 21:16:43 +10:00
Miodrag Milanovic
df5c8faa85 Fixed name conflict making Android build non-working (nw) 2016-05-17 12:15:45 +02:00
couriersud
332534cdf5 Continuing work to move object initialization from start to constructor.
Removed family_t. All of this can be determined at runtime from object
as well. As part of this, the "template" to write devices has changed.
Converted a number of devices to use the new template. [Couriersud]
2016-05-16 12:50:50 +02:00
couriersud
f35ba3f5fd More automatic memory handling. (nw) 2016-05-16 12:41:20 +02:00
couriersud
7d9c8b78ea Some use of share_ptr to ease memory management. (nw) 2016-05-12 01:15:19 +02:00
couriersud
c2fb41964c Code simplification 2016-05-12 01:15:19 +02:00
couriersud
bd1123dc30 mergeme 2016-05-12 01:15:18 +02:00
couriersud
f404f86570 Devices are now created after the netlist was parsed. This enables us
going forward to move everything in start() into the constructor and get
a much cleaner object model. (nw)
2016-05-12 01:15:17 +02:00
couriersud
2fe1ba1eee Don't include netlist name in device names. (nw) 2016-05-12 01:15:17 +02:00
couriersud
bc57c965bd Code simplification. (nw) 2016-05-12 01:15:16 +02:00
couriersud
b7a29d4575 A step towards late creation of devices. (nw) 2016-05-10 00:47:32 +02:00
couriersud
ccf66bee16 Align object registration syntax. (nw) 2016-05-10 00:47:21 +02:00
couriersud
4bf639f3e2 Rename connect_direct to connect_post_start to reflect usage. (nw) 2016-05-10 00:41:35 +02:00
couriersud
38ca93a5d7 Simplify object model by removing default_logic_family(). 2016-05-08 15:05:59 +02:00
couriersud
df8280806b Some minor changes towards c++11. 2016-05-08 15:05:58 +02:00
couriersud
1eb9c20772 Fix standalone-compile. 2016-05-06 01:10:21 +02:00
couriersud
658f6b432a Converted 7486 to macro module 2016-05-05 23:33:01 +02:00
couriersud
d3c0199769 Removed drivers/signal.h since netlist devices no longer use it. (nw) 2016-05-05 15:18:37 +02:00
couriersud
add61d2a00 Convert 7430 to macro module. 2016-05-05 15:18:37 +02:00
couriersud
38d3050da0 Convert 7425 to macro modul 2016-05-05 15:18:36 +02:00
couriersud
87541ec5ca Converted 7420 to macro modul 2016-05-05 15:18:36 +02:00
couriersud
cbe5b6abaa Fix conditional compile path 2016-05-05 15:18:35 +02:00
couriersud
a920da0ec3 Convert 7432 to macro device. 2016-05-04 00:51:51 +02:00
couriersud
1ea05793be Converted 7437 to macro device 2016-05-04 00:08:09 +02:00
couriersud
467b7b23dd Some header maintenance 2016-05-04 00:08:08 +02:00
couriersud
ba57ebf222 Converted 7427 to macro device 2016-05-04 00:08:07 +02:00
couriersud
e93ebba837 Converted 7411 into a macro device. 2016-05-04 00:08:07 +02:00
couriersud
e85517d642 Converted 7410 into macro device. 2016-05-04 00:08:06 +02:00
couriersud
3acd03bd5f Implement 7402, 7408 as macro device. (nw) 2016-05-03 02:35:07 +02:00
couriersud
6f889d51ae Implement 7404 as macro device. (nw) 2016-05-03 02:35:06 +02:00
couriersud
576189b169 Converted most subdevices to unique_ptr. This is a temporary measure
until the device initialisation is moved into the constructor. Started
converting constructors of devices to be passed name and netlist. (nw)
2016-05-02 21:56:57 +02:00
AJR
b8c05fd084 Workaround for MT 06194 (potential segfault during floppy load) 2016-05-01 10:26:28 -04:00
Robbbert
a320b64f3a MT 06189 2016-05-01 15:36:56 +10:00
Miodrag Milanovic
cfee536f22 Cleanups and version bump 2016-04-27 08:13:59 +02:00
etabeta78
24900375fd cgenie.cpp: expanded .cas support so that also files created by
Genieous emulator can be loaded. [Fabio Priuli]
2016-04-24 16:07:06 +02:00
Miodrag Milanovic
89c5e1f681 Various cleanups suggested by static analyzer (nw) 2016-04-24 12:58:31 +02:00
AJR
fb08fefaee Move a few odds and ends out of the emu core 2016-04-23 15:27:59 -04:00
couriersud
64eeebb967 Add missing files. 2016-04-23 14:20:48 +02:00
couriersud
1d7b7f59dd Implemented dynamic loading of precompiled solver code. [Couriersud] 2016-04-23 13:54:32 +02:00
couriersud
4bf89be02c Simplify solver infrastructure. 2016-04-18 18:31:51 +02:00
couriersud
222adaf847 merge me later bug fix 2016-04-18 18:31:50 +02:00
couriersud
2762b9f5ac Merge me later 2016-04-18 18:31:49 +02:00
Miodrag Milanović
1f418ad90e Merge pull request #809 from jmakovicka/master
Fix type mismatch
2016-04-16 08:57:16 +02:00
dankan1890
edb0904e76 chd: initialized m_hunknum inside the constructor. (nw) 2016-04-15 17:23:56 +02:00
dankan1890
295c7294d3 cdrom: declared (std::nothrow) some allocations. (nw) 2016-04-15 17:20:50 +02:00
couriersud
d9df811529 Significant speed improvement:
- added a new solver using compressed row format
- fixed sorting

As a result, netlist performance on kidniki nearly doubled. The
performance increase is mainly due to the fact that sorting decreases
the number of operations for gaussian elimination of the kidniki matrix
from ~7800 to 707. In addition, compressed row format improves L1 usage. 
[Couriersud]
2016-04-15 02:09:41 +02:00
couriersud
cd0441b678 Recover from creating solvers by copy paste. Move common code were it
belongs. (nw)
2016-04-15 02:09:41 +02:00
couriersud
4f1ca77643 Moved solver members to proper place. Minor code changes. (nw) 2016-04-15 02:09:26 +02:00
Jindřich Makovička
4422b2cf84 Fix type mismatch 2016-04-13 09:44:42 +02:00
R. Belmont
3ed3b7e7fc Merge pull request #776 from jmallach/typos
Fix typos throughout the codebase
2016-04-12 08:48:35 -04:00
Vas Crabb
a21453fcde Make un7z a bit chattier, too 2016-04-11 18:09:54 +10:00
Vas Crabb
efffa8a6f3 Make unzip less opaque about what it's doing 2016-04-11 15:47:57 +10:00
couriersud
19397471c1 netlist_t no longer descends from netlist::object_t. 2016-04-10 17:16:20 +02:00
couriersud
71d2cf2625 Get rid of some init_object calls. 2016-04-10 17:16:19 +02:00
couriersud
521353d8d7 Replace macros with templates. 2016-04-10 17:16:18 +02:00
Vas Crabb
467a1fae80 Fix crash 2016-04-10 18:42:53 +10:00
Vas Crabb
a723548a8f Second thoughts about default status 2016-04-10 18:36:44 +10:00
Miodrag Milanovic
ed209c842d Visual Studio says it can be uninitialized (nw) 2016-04-10 10:15:03 +02:00
Vas Crabb
7d1ec41744 foobar is not a subdirectory of foo called bar 2016-04-10 17:21:46 +10:00
Vas Crabb
a26f4f3428 STL makes life easier 2016-04-10 16:02:41 +10:00
Vas Crabb
d74f5db813 Fix for archives containing directories like foobar following foo 2016-04-10 15:47:51 +10:00
Vas Crabb
760b4bd93b Fix phantom files in archives containing directories 2016-04-10 15:35:40 +10:00
Vas Crabb
33e62ec403 Work with more ZIP64 files 2016-04-10 12:05:53 +10:00
Vas Crabb
df4bb8b404 zip cleanup 2016-04-10 10:14:51 +10:00
couriersud
7d2c7a125e Use templates in nl_math. 2016-04-09 23:45:44 +02:00
couriersud
fc31cd6289 Use c++11 features to use more templates. 2016-04-09 23:45:43 +02:00
couriersud
0d1e57cc40 Solver model simplification. 2016-04-09 23:45:42 +02:00
Vas Crabb
5eed772e4e zip method 14 2016-04-09 23:47:55 +10:00
Vas Crabb
096c94743a More ZIP support 2016-04-09 21:52:09 +10:00
Vas Crabb
e925c494fe Update LZMA SDK to 15.14 2016-04-09 21:52:08 +10:00
couriersud
b13e02f975 Align with standalone-build. 2016-04-09 12:44:41 +02:00
Vas Crabb
f5f9b45da8 ZIP64 support [Vas Crabb] 2016-04-09 15:28:58 +10:00
yz70s
62d6d7f24b nld_ms_sm.h: better use '!' instead of 'not' (nw) 2016-04-08 23:54:10 +02:00
couriersud
28d364bc8f Add includes for dependency documentation. There is still inconsistent
use of assert(...) in src/lib/util. libutil compile will use assert from
<assert> while other parts of mame will be compiled with assert from
emucore.h.
2016-04-08 17:53:52 +02:00
couriersud
07645b6670 Minor changes, mostly signed comparisons and adding includes for
dependency documentation.
2016-04-08 17:02:48 +02:00
couriersud
bc936dbc26 Added m62(kidniki) to nl.lua. Started some experiments around parallel
solving of linear equations. This code is not active. Fix kidniki audio
performance. [Couriersud]
2016-04-08 03:30:11 +02:00
Vas Crabb
865253ccb0 Improve 7zip file I/O code (should fix >=4GB 7z archives on LP32/LLP64) 2016-04-06 15:11:30 +10:00
AJR
ee12b7d2f7 Revert software-installed slot/image options when changing software
- Remove emu.h's stealth include of emuopts.h through mconfig.h; reduce dependency on emuopts.h in other headers and source files.
- MCFG_CPU_FORCE_NO_DRC is now a CPU configuration parameter rather than a global one; it still works to override the -drc option setting.
2016-04-04 23:46:44 -04:00
Olivier Galibert
cdc04a9b7c screen: POC||GTFO of svg rendering from inside the rom. [O. Galibert]
It's damn slow, ~50ms/frame on cdkong.  Caching and/or hw accel will
solve that easily.  It doesn't look very good, nanosvg need better
anti-aliasing.  It also doesn't do texturing very well and images not
at all, so some of our current svgs won't look good.  But all that's
fixable.
2016-04-04 11:33:34 +02:00
dankan1890
1aa8a350d3 fix: inline not allowed. (nw) 2016-04-03 18:54:04 +02:00
dankan1890
37f39ecf3c Small changes. (nw) 2016-04-03 18:45:34 +02:00
Jeffrey Clark
ca3e65e35f refactor miscmenu and add adv menu (nw) 2016-04-03 07:02:38 +00:00
Jordi Mallach
80890952a7 Typo fix: nonexistant → nonexistent 2016-04-01 02:28:15 +02:00
Jordi Mallach
1d052674c9 Typo fix: threshholds → thresholds 2016-03-31 23:17:32 +02:00
AJR
b0e033146a Avoid auto return types; silence some unused variable warnings (nw) 2016-03-31 13:50:31 -04:00
AJR
54f7422c2a Conflict resolution (nw) 2016-03-31 10:29:46 -04:00
AJR
a7e393b36b Iterate over core classes C++11 style
C++11 range-based for loops can now iterate over simple_list, tagged_list, core_options, device_t::subdevice_list, device_t::interface_list, render_primitive_list and all subclasses of the above, and much code has been refactored to use them. Most core classes that have these lists as members now have methods that return the lists themselves, replacing most of the methods that returned the object at an owned list's head. (A few have been retained due to their use in drivers or OSD.)

device_t now manages subdevice and interface lists through subclasses, but has given up the work of adding and removing subdevices to machine_config.

memory_manager has its tagged lists exposed, though the old rooted tag lookup methods have been removed (they were privatized already).
2016-03-31 09:43:53 -04:00
dankan1890
0bab931a80 Visual Studio 2015 netlist fix. (nw) 2016-03-30 19:09:40 +02:00
yz70s
f7dd940081 Try to fix netlist build visual studio 2015 2016-03-30 10:12:18 +02:00
Miodrag Milanovic
913ab1e140 Cleanups and version bump 2016-03-30 08:35:21 +02:00
Jeffrey Clark
18d7e34620 cleanup build includes (nw) 2016-03-28 22:46:00 -05:00
couriersud
ca99eb00ae Remove sorting from Sherman-Morrison solver. It doesn't help.
[Couriersud]
2016-03-29 01:59:51 +02:00
couriersud
8eec0786b5 Added woodbury solver to netlist. [Couriersud] 2016-03-29 01:59:51 +02:00
dankan1890
68ebc2b0e5 Visual Studio compile fix. (nw) 2016-03-28 22:57:35 +02:00
dankan1890
966db2f2f7 fix compile. (nw) 2016-03-28 16:14:32 +02:00
couriersud
628cef3d97 Added some notes about Sherman-Morrison. 2016-03-28 13:48:28 +02:00
couriersud
8c69d3ad15 Fix crash in stat output when no calculations were run 2016-03-28 13:48:27 +02:00
couriersud
97b9fc11d6 First version of Sherman-Morrison solver. 2016-03-28 13:03:51 +02:00
couriersud
93414a8bd7 Fix pivoting and float usage. 2016-03-28 13:03:50 +02:00
couriersud
9d2f61ee92 netlist:
- more code optimization
- hide matrix_solver_t implementation
- use netlist_time for time deltas
2016-03-27 15:41:42 +02:00
couriersud
2e21930b27 netlist:
- Simply solver code.
- Remove ATTR_HOT from solver code.
- make virtual members protected
2016-03-27 15:41:41 +02:00
couriersud
1a36bfd0eb Fix kidniki sound speed. Make more class members private. 2016-03-26 16:17:39 +01:00
couriersud
f5bcee0db3 netlist: prepare code so that matrices can be allocated in one chunk of
memory.
2016-03-26 16:17:38 +01:00
couriersud
2ac1e54bd9 Fix a bug. 2016-03-26 16:17:38 +01:00
Vas Crabb
54279dbf11 Make emu_file archive searh order CRC+path, CRC+partial path, CRC, path, partial path and fold some redundant code 2016-03-25 15:25:30 +11:00
couriersud
489e2919db Netlist: code maintenance
- rename netlist_analog_t to analog_t 
- straighten object model
- reduce access to member variables
- use pvector<analog_net_t::list_t> for groups.
- simple coverity fixes.
2016-03-23 22:03:26 +01:00
Vas Crabb
f83078d8bf Use std::atomic in nl_lists.h with OpenMP 2016-03-22 12:42:19 +11:00
Justin Kerk
d9d86e1909 Enable the internal delegates for Emscripten too (nw) 2016-03-20 19:51:43 +00:00
Vas Crabb
f07d5bf4bd Fix boundary check on parsing ZIP ECD 2016-03-21 04:58:48 +11:00
Vas Crabb
cb231cea0a Fix many valgrind Mismatched free() / delete / delete [] errors 2016-03-21 03:58:09 +11:00