summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/machine/ram.cpp
Commit message (Collapse)AuthorAgeFilesLines
* odyssey2/homecomp: make ram size configurable hap2021-02-011-1/+6
|
* Much more core std::string_view modernization AJR2021-01-201-0/+2
| | | | | | | | | | | | | | | - Remove corestr.h from emu.h; update a few source files to not use it at all - Change strtrimspace, strtrimrightspace and core_filename_extract_* to be pure functions taking a std::string_view by value and returning the same type - Change strmakeupper and strmakelower to be pure functions taking a std::string_view and constructing a std::string - Remove the string-modifying version of zippath_parent - Change tag-based lookup functions in device_t to take std::string_view instead of const std::string & or const char * - Remove the subdevice tag cache from device_t (since device finders are now recommended) and replace it with a map covering directly owned subdevices only - Move the working directory setup method out of device_image_interface (only the UI seems to actually use the full version of this) - Change output_manager to use std::string_view for output name arguments - Change core_options to accept std::string_view for most name and value arguments (return values are still C strings for now) - Change miscellaneous other functions to accept std::string_view arguments - Remove a few string accessor macros from romload.h - Remove many unnecessary c_str() calls from logging/error messages
* use C++ library includes (nw) firewave2020-01-221-2/+2
|
* Make osd_printf_* use util/strformat semantics. Vas Crabb2019-09-261-3/+3
| | | | | | | | | | | | | | | | | (nw) This has been a long time coming but it's here at last. It should be easier now that logerror, popmessage and osd_printf_* behave like string_format and stream_format. Remember the differences from printf: * Any object with a stream out operator works with %s * %d, %i, %o, %x, %X, etc. work out the size by magic * No sign extending promotion to int for short/char * No widening/narrowing conversions for characters/strings * Same rules on all platforms, insulated from C runtime library * No format warnings from compiler * Assert in debug builds if number of arguments doesn't match format (nw) Also removed a pile of redundant c_str and string_format, and some workarounds for not being able to portably format 64-bit integers or long long.
* Allow passing std::unique_ptr<TYPE> directly to save_pointer and remove ↵ AJR2018-06-241-1/+1
| | | | now-superfluous .get() in many drivers/devices (nw)
* restore RAM default fill (nw) Vas Crabb2018-04-031-1/+1
|
* neogeo: Split into real models: Vas Crabb2018-03-291-0/+4
| | | | | | | | | | | * Moved common stuff (mostly video) into a base memory map. * Split common edge connector inputs into JAMMA and MVS. * Added clones with different numbers of game slots, edge connector, controller ports, memory card, and speakers. * Based fixed-software drivers on MV-1 JAMMA board configuration. * Removed memory card and controller ports from single-PCB games and converted to mono output. * Coin lockouts/counters still not connected, and LED/EL output isn't suppressed for variants that lack it. (nw) suppress leading space in RAM option names
* minimaws: expose RAM size Vas Crabb2018-03-271-5/+20
|
* Always show default RAM size in XML output Vas Crabb2018-03-261-36/+35
|
* srcclean (nw) Vas Crabb2017-06-251-7/+7
|
* [Ram Device] Better detection of bad -ramsize strings, move some private ↵ npwoods2017-06-011-68/+77
| | | | | | | | | | code to anonymous namespace (#2336) * [Ram Device] Better detection of bad -ramsize strings, move code to anonymous namespace There was a longstanding bug where '-ramsize 16kfoo' would be treated as '-ramsize 16k' * Changed parse_string() to explicitly look for the suffixes "[k|m][|b|ib]"
* Cleanups to ram_device (#2324) npwoods2017-05-241-98/+95
| | | | | | Specifically: 1. Changed ram_device to expose specific options, removing the burden for clients to parse RAM strings 2. Moved validation of command line arguments out of device_validity_check(); that method is only intended for checking the device itself 3. Miscellaneous polishing
* Move static data out of devices into the device types. This is a ↵ Vas Crabb2017-05-141-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* Revert "Overhaul to how MAME handles options (#2260)" Vas Crabb2017-05-071-1/+3
| | | | | | | | | | | | This reverts commit 536990e77b49ccc50ef275bfbf1018cc29c16154. 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.
* Overhaul to how MAME handles options (#2260) npwoods2017-05-051-3/+1
| | | | | | | | | | | | 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.
* Self-registering devices prep: Vas Crabb2017-02-271-1/+1
| | | | | | | | | | | | | | * Make device_creator a variable template and get rid of the ampersands * Remove screen.h and speaker.h from emu.h and add where necessary * Centralise instantiations of screen and speaker finder templates * Add/standardise #include guards in many hearers * Remove many redundant #includes * Order #includesr to help catch headers that can't be #included alone (nw) This changes #include order to be prefix, unit header if applicable then other stuff roughly in order from most dependent to least dependent library. This helps catch headers that don't #include things that they use.
* Taito 68705 interface improvements: Vas Crabb2017-01-151-0/+3
| | | | | | | | | * Moved stuff arkanoid/puzznic have in common with other games to new abstract base class * Got rid of the unnecessary hacks for bigevglf, it doesn't need anything special * Moved xsleena (xain.cpp) to the common interface class * This fixes regressions in tokio and daikaiju (nw) started instantiating common device finders with the devices to marginally improve build/link time
* No need for osd_malloc, osd_malloc_array and osd_free (nw) Miodrag Milanovic2016-11-111-1/+1
| | | | MALLOC_DEBUG not applicable anymore since we use new to allocate in 99.9% of cases
* converted lot of TRUE/FALSE to real boolean and updated types (nw) Miodrag Milanovic2016-10-221-6/+6
|
* NOTICE (TYPE NAME CONSOLIDATION) Miodrag Milanovic2016-10-221-6/+6
| | | | | 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
* consistency fixes and add missed files (nw) Miodrag Milanovic2016-03-041-1/+1
|
* * Support *n conversion in stream_format/string_format Vas Crabb2016-03-011-4/+4
| | | | | | | | | * Make stream_format return characters printed * Add iostreams with std::vector storage * Move to type-safe templates for logerror and popmessage * Remove now-unnecessary I64FMT from calls to logerror/popmessage * Put some lib/util stuff in util:: namespace * Some fixes to Japanese translation
* Replace strformat, strprintf and strcatprintf with type-safe steam_format ↵ Vas Crabb2016-02-281-6/+6
| | | | | | | | | and string_format Update MAME to use new function Instantiate ODR-used static constant members Make some of the UI code more localisable Remove use of retired functions in tools
* ram device: switch to bsd3 by request Dirk Best2016-02-131-11/+2
|
* reverting: Miodrag Milanovic2016-01-201-3/+3
| | | | | | | SHA-1: 1f90ceab075c4869298e963bf0a14a0aac2f1caa * tags are now strings (nw) fix start project for custom builds in Visual Studio (nw)
* tags are now strings (nw) Miodrag Milanovic2016-01-161-3/+3
| | | | fix start project for custom builds in Visual Studio (nw)
* clang-modernize part 3 Miodrag Milanovic2015-12-041-9/+9
|
* Some cleanups and init fixes with help of ReSharper C++ (nw) Miodrag Milanovic2015-11-111-3/+3
|
* Rename *.c -> *.cpp in our source (nw) Miodrag Milanovic2015-11-081-0/+222