Commit Graph

670 Commits

Author SHA1 Message Date
Nathan Woods
b8453021df Added a facility to allow logerror output to reside in traces
As a consequence, the debugger 'trace' command was changed so that the third parameter is a list of '|' delimited options
2017-01-16 20:13:03 -05:00
Nathan Woods
d8d82358c3 Augmenting help file 2017-01-16 20:07:50 -05:00
Nathan Woods
46b62fb194 Created a new debugger command 'tracesym'
'tracesym' is intended to be a shorthand of 'tracelog', whereby the user doesn't have to specify a format string; the default format string is used
2017-01-15 16:19:03 -05:00
Vas Crabb
c9647f6e28 debugger: use 0o for octal prefix, and add support for binary with 0b a la C++, also support uppercase radix speifier 2017-01-06 15:37:43 +11:00
R. Belmont
2c7ab7fe83 Merge pull request #980 from shattered/_ad3979c
debugger: parse octal expressions (prefixed by '0')
2017-01-05 15:18:42 -05: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
998e196d55 dimemory: Remove the magic bypass [O. Galibert] 2016-12-10 13:40:26 +01:00
Olivier Galibert
7f0ba30ec5 sharc: Use standard memory maps [O. Galibert] 2016-12-09 20:11:33 +01:00
AJR
f050607f8e One more command that lacked an 'o' version (nw) 2016-12-02 05:39:22 -05:00
AJR
ff4f03694f Add 'o' variants to memory debugging commands to request decrypted opcodes space 2016-12-01 21:11:35 -05:00
Vas Crabb
b8b0774997 Merge pull request #1317 from npwoods/disasm_stdstring
Refactored device_disasm_interface::disassemble() and dasm_override_delegate to take string buffers as std::string
2016-11-21 11:30:06 +11:00
Nathan Woods
7c868e53d0 Moving disasm.clear()/disasm.seekp(0) out of if statement, so the stream is always reset 2016-11-20 19:18:32 -05:00
Nathan Woods
932f69d6e9 Eliminated 'device_disasm_interface::disassemble(std::string &buffer, ...' 2016-11-20 18:27:25 -05:00
Vas Crabb
c7352f5684 Revert "moved debugger_access() from address space to machine & removed the anti-patterns that updated cascading address spaces. [smf]"
This reverts commit 5f05fbf613.
2016-11-21 05:57:46 +11:00
Nathan Woods
a29891d2e5 Changed disassembler infrastructure to not use char buffers internally 2016-11-20 08:49:30 -05:00
smf-
5f05fbf613 moved debugger_access() from address space to machine & removed the anti-patterns that updated cascading address spaces. [smf] 2016-11-19 22:18:58 +00:00
smf-
9e93cdcd55 Fix for the nonstandard types when not using the broken precompiled headers. (nw) 2016-11-19 13:19:29 +00: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
Miodrag Milanovic
79714c47d2 Fix Visual Studio build (nw) 2016-11-16 16:25:17 +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
Miodrag Milanovic
6b18f90438 Revert "Added IS_ENABLED, so we have compiler check for non used part, it is checked but not compiled in (nw)"
This reverts commit c0407f073b.
2016-11-12 09:12:36 +01:00
Miodrag Milanovic
c0407f073b Added IS_ENABLED, so we have compiler check for non used part, it is checked but not compiled in (nw)
false and true now used instead of integer where used as bool
2016-11-11 18:50:14 +01:00
Miodrag Milanovic
2027d59e7f Do not use FUNC in delegate where applicable (nw) 2016-11-06 14:11:55 +01:00
smf-
e125186e15 Moved device_memory_interface from driver_device to dummy_space_device. Exposed the dummy_space_device as machine().dummy_space(), with a trampoline in driver_device for existing callers. Debugger no longer needs to special case root_device() to avoid showing the dummy address space. [smf] 2016-11-03 19:21:20 +00: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
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
AJR
28cc18b698 Add row size as sixth parameter to debug dump command 2016-10-16 11:55:09 -04:00
AJR
f1b0dfe64a Separate natural keyboard support from ioport.cpp (nw) 2016-10-02 00:07:43 -04:00
Jordi Mallach
6f103c2391 Fix various spelling fixes. 2016-09-29 10:14:48 +02:00
smf-
fd279ffffa Make sure all cpu's export STATE_GENPCBASE and use safe_pcbase() for everything in the debugger, which allows interruptible cpu's to work properly. [smf] 2016-09-28 17:45:37 +10:00
Vas Crabb
1de6465b18 fix disassembly if 6809 is interrupted mid-instruction [smf] 2016-09-28 17:45:36 +10:00
Lord-Nightmare
32a5bcf975 Revert "fix disassembly if 6809 is interrupted mid-instruction [smf]"
This reverts commit 320121823c.
2016-09-27 18:05:57 -04:00
Lord-Nightmare
e8d2853334 Revert "Make sure all cpu's export STATE_GENPCBASE and use safe_pcbase() for everything in the debugger, which allows interruptible cpu's to work properly. [smf]"
This reverts commit 1a186c8a3a.
2016-09-27 18:05:19 -04:00
smf-
1a186c8a3a Make sure all cpu's export STATE_GENPCBASE and use safe_pcbase() for everything in the debugger, which allows interruptible cpu's to work properly. [smf] 2016-09-27 14:26:27 +01:00
Vas Crabb
320121823c fix disassembly if 6809 is interrupted mid-instruction [smf] 2016-09-27 20:57:45 +10:00
smf-
c56cd675f2 Fixed trace command access a parameter beyond the list supplied, added an error message if you provide an invalid boolean, allow boolean to be case-insensitive and skip empty strings when parsing booleans. [smf] 2016-09-20 13:34:54 +01:00
therealmogminer@gmail.com
7df8323c2d Fix -debug -cheat crash, nw 2016-08-27 18:03:12 +02:00
Nathan Woods
c38b753f01 The 'trace' and 'traceover' commands were registered as having three arguments. This fixes it so there are four arguments
This seems to have been broken a long time.  My guess is that when the ability to disable loop detection was added, the argument count was not changed to continue allowing the existing command argument.
2016-08-23 09:58:23 -04:00
Vas Crabb
15e7be7ac8 Turn image init/validate into scoped enums to avoid accidental casts to/from integer and boolean types
The image error should also be turned into a scoped enum - the menus were assuming it was the same thing as an init result
2016-08-01 18:47:22 +10:00
Miodrag Milanovic
6f5e223853 for bool type use true and false (nw) 2016-07-31 20:02:56 +02:00
Miodrag Milanovic
eaa70ae031 cleanup of some conversions (nw) 2016-07-31 16:41:26 +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
Miodrag Milanovic
4887ce1844 Cleanups and version bump 2016-07-27 09:26:22 +02:00
AJR
566c12db31 debugcpu: prevent nullptr exceptions when devices named in expressions lack memory interfaces 2016-07-25 23:20:52 -04:00
therealmogminer@gmail.com
c643372753 Make loop collation optional for debugger trace and traceover commands 2016-07-14 16:13:52 +02:00
Vas Crabb
5020bb162e fix item hilighting in debugger state view when scrolling [Vas Crabb]
better encapsulate debug_view_state::state_item

also check for debugger access for reads with side effects in osborne1 and s2636
2016-07-13 15:02:48 +10:00
Vas Crabb
7f3ced8c96 Fix scroll in debugger state view 2016-07-11 19:21:39 +10:00
AJR
20427d78b4 Don't need debugcpu to translate (nw) 2016-07-03 17:23:47 -04:00
AJR
90b08e2995 Consolidate disassemble functions (nw) 2016-07-03 13:46:21 -04:00
AJR
421b8b28c0 Fix undefined symbols error in clang compile (nw) 2016-07-01 17:23:55 -04:00
Miodrag Milanovic
6e1adc4386 simplified memory management for save states and states (nw) 2016-07-01 19:51:07 +02:00
Miodrag Milanović
5886ed531e Merge pull request #994 from ajrhacker/dasm_override
Move disasm overrides into interface, reducing driver-debugger depend…
2016-07-01 13:55:12 +02:00
Miodrag Milanovic
63f9a01f8c Cleanup and version bump 2016-06-29 08:34:30 +02:00
AJR
38c4b762f0 Move disasm overrides into interface, reducing driver-debugger dependencies (nw) 2016-06-24 22:34:13 -04:00
AJR
d6f9e3bc1c Eliminate some unnecessary pass-through methods from debugcpu (nw) 2016-06-22 16:52:55 -04:00
Sergey Svishchev
0c04a3c893 debugger: parse octal expressions (prefixed by '0') 2016-06-21 00:23:16 +03:00
R. Belmont
321e593923 Merge pull request #965 from ajrhacker/debugspace
Suppress 'no matching space' debugger error when disassembling CPUs w…
2016-06-18 17:10:26 -04:00
AJR
1702c3fc97 Suppress 'no matching space' debugger error when disassembling CPUs without decrypted opcodes 2016-06-18 10:51:06 -04:00
Miodrag Milanovic
78c3929217 tagged_list to unordered_map in emumem (nw) 2016-06-18 15:32:15 +02:00
Miodrag Milanovic
fc8e18d893 tagged_list to unordered_map for debugger (nw) 2016-06-18 15:32:15 +02:00
Miodrag Milanovic
402ad8ef85 small debugger cleanup (nw) 2016-06-17 13:39:42 +02:00
Miodrag Milanovic
3969f6e749 Fixed debugger regression (nw) 2016-06-17 12:04:28 +02:00
therealmogminer@gmail.com
56bd36c5ef Major refactoring of debugger core [Ryan Holtz]
* Eliminate globals/file statics
* Remove lots of stuff from global scope
* Use std::function for custom command registration
* Eliminate some trampolines
* Build fixes from Vas Crabb and balr0g
2016-06-08 08:10:55 +10:00
angelosa
62b82f2937 TODO note, nw 2016-06-05 16:11:28 +02:00
angelosa
ea46245a9a Added commit command to debugger. [Angelo Salese] 2016-06-05 16:11:27 +02:00
angelosa
6aa1d4d66c Update help file, the whole help string parser is so 90s, nw 2016-06-04 19:43:26 +02:00
angelosa
a9a5cceb72 Added comlist comment to debugger [Angelo Salese]
Added notes wrt dangarj protection, nw
2016-06-04 19:43:25 +02:00
Vas Crabb
bbb2e917b5 MT6225 MT6226 MT6227 debugger may crash when validating expression with non-existent memory space name 2016-05-30 14:17:01 +10:00
Miodrag Milanovic
89c5e1f681 Various cleanups suggested by static analyzer (nw) 2016-04-24 12:58:31 +02:00
Miodrag Milanovic
1c726824f2 Split UI and frontend part from core [Miodrag Milanovic] 2016-04-23 11:26:47 +02:00
AJR
084d3654ca Iterate over devices C++11 style
Replace the old device_iterator and its specialized versions with functionally equivalent classes that use standard operators to yield references to devices/interfaces rather than pointers. With range-based for loops, they no longer have to be stored in named variables, though they can also be reused concurrently since the iteration state is now maintained by a subclass.

Add a few more typical getters to device_t::subdevice_list.
2016-04-18 18:53:28 -04:00
R. Belmont
3ed3b7e7fc Merge pull request #776 from jmallach/typos
Fix typos throughout the codebase
2016-04-12 08:48:35 -04:00
couriersud
7b3d46dea7 Add includes for dependency documentation. (nw) 2016-04-09 12:17:51 +02:00
Jordi Mallach
3d5c53d11e Typo fix: threshhold → threshold 2016-04-01 02:28:16 +02:00
AJR
b0e033146a Avoid auto return types; silence some unused variable warnings (nw) 2016-03-31 13:50:31 -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
Miodrag Milanovic
913ab1e140 Cleanups and version bump 2016-03-30 08:35:21 +02:00
Vas Crabb
100fa28671 * Remove confusing method from vectorstreams that hide base_ios method (fixes disassembly view)
* Allow std::string to pass through core_file unmolested (reduces temporary allocations)
* Make zip/7z instances of same class with uniform interface
* zippath browsing is broken at the moment

This is another step towards transparent archive support.  It's now
possible to access zip and 7z archives with the same code.  Nothing is
taking advantage of it yet.  There's now some very similar code in
fileio.cpp and clifront.cpp that could be folded at some point.
2016-03-18 19:32:10 +11:00
Lord-Nightmare
acb27808d4 temporary fix for debugger disassembly view on windows (nw) 2016-03-18 03:43:06 -04:00
Vas Crabb
f0e580e40a Clear error status on persistent streams 2016-03-17 13:30:09 +11:00
Vas Crabb
42fbb9c396 Make osd_file a polymorphic class that's held with smart pointers
Make avi_file a class that's held with smart pointers, encapsulate various AVI I/O structures
Make zip_file and _7z_file classes rather than having free functions everywhere
Hide zip/7z class implementation behind an interface, no longer need to call close() to send back to the cache
Don't dump as much crap in global namespace
Add solaris PTY implementation
Improve variable expansion for SDL OSD - supports ~/$FOO/${BAR} syntax
Rearrange stuff so the same things are in file module for all OSDs
Move file stuff into its own module

7z/zip open and destruct are still not thread-safe due to lack of interlocks around cache access
Directory functions still need to be moved to file module
SDL OSD may not initialise WinSock on Windows
2016-03-14 18:55:00 +11:00
Vas Crabb
ed88fd30a1 More stream enhancement 2016-03-03 03:53:43 +11:00
Vas Crabb
d50614c8bd Use stream with contiguous backing store for the disasmview's buffer 2016-03-03 03:53:43 +11:00
Vas Crabb
66d0ef8ed4 Fix some oversights in previous changes, sorry guys'n'gals 2016-03-03 01:25:48 +11:00
Happy
8aa07c72e7 Change field format to show leading zeros for debugger 'dasm' command as well 2016-03-01 13:46:33 -07:00
Happy
5257bf21cd Change field format to show leading zeros for debugger 'dump' command 2016-03-01 13:16:38 -07:00
Vas Crabb
599570bf7f Fix stupid reversed subtraction 2016-03-01 22:33:19 +11:00
Vas Crabb
fee5fb55f9 Get rid of most uses of core_i64_hex_format, all remaining uses are in memory.cpp 2016-03-01 21:40:14 +11:00
Vas Crabb
9224c862b2 Move more things to type-safe printf 2016-03-01 18:57:06 +11:00
Vas Crabb
aec01e7407 Replace strformat, strprintf and strcatprintf with type-safe steam_format 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
2016-02-28 13:36:19 +11:00
Miodrag Milanovic
3abcaee63f Cleanups and version bump 2016-02-24 07:46:57 +01:00
Miodrag Milanovic
ccae0382bb Added plugins and boot.lua as startup script [Miodrag Milanovic] 2016-02-14 10:58:18 +01:00
AJR
7750a10135 Make octal flag part of address_space/address_space_config, not (illogically) device_execute_interface (nw) 2016-02-04 17:10:53 -05:00
Miodrag Milanovic
42622cfe8e replace osd_lock with std::mutex [Miodrag Milanovic] 2016-01-30 20:43:50 +01:00
AJR
83e6738a0a Add macros for alignment checking (nw) 2016-01-30 13:25:32 -05:00
dankan1890
361d32d37f Small code cleanup:
- corealloc.h: added macro definition for global_alloc (nothrow) memory allocation.
- textbuf.cpp / wavwrite.cpp: removed pointless cast.
- debugcmd.cpp / luaengine.cpp / render.cpp: avoid strlen calls in a loop.
- diimage.cpp: simplified "device_image_interface::set_image_filename" function.
- miscmenu.cpp / selgame.h / video.cpp(h): replaced int with bool where applicable.
- ui.cpp: removed unused code.
2016-01-29 00:43:18 +01:00
Miodrag Milanovic
1991ad3e66 Fixed bug debugging drivers with es5510 core, possibly some others that do not have AS_PROGRAM at all (nw) 2016-01-25 15:00:35 +01:00
Miodrag Milanovic
4e8e3066f8 reverting:
SHA-1: 1f90ceab07

* tags are now strings (nw)
fix start project for custom builds in Visual Studio (nw)
2016-01-20 21:42:13 +01:00
Miodrag Milanovic
7c9cd3feea Revert "rest of device parameters to std::string (nw)"
This reverts commit caba131d84.
2016-01-20 21:35:11 +01:00
Miodrag Milanovic
abb7f223b3 Revert "Fix for hang, emu_options::add_slot_options was changed, other things are just cleanup (nw)"
This reverts commit 841a55985e.
2016-01-20 21:32:11 +01:00
Miodrag Milanovic
684132719f Revert "Memory region to use std::string (nw)"
This reverts commit 14d0bff4d0.
2016-01-20 21:31:21 +01:00
Miodrag Milanovic
14d0bff4d0 Memory region to use std::string (nw) 2016-01-20 16:04:07 +01:00
Miodrag Milanovic
841a55985e Fix for hang, emu_options::add_slot_options was changed, other things are just cleanup (nw) 2016-01-18 14:39:13 +01:00
Miodrag Milanovic
caba131d84 rest of device parameters to std::string (nw) 2016-01-16 20:05:32 +01:00
Miodrag Milanovic
1f90ceab07 tags are now strings (nw)
fix start project for custom builds in Visual Studio (nw)
2016-01-16 14:54:42 +01:00
Miodrag Milanovic
807265ed21 put debug_view back in machine due to issues with QT (nw) 2016-01-12 12:00:56 +01:00
Miodrag Milanovic
f9a9eafba0 created debugger_manager, now this one owns debug_view_manager (nw) 2016-01-12 09:50:59 +01:00
Miodrag Milanović
36195292e3 Merge pull request #561 from ajrhacker/strings
Return std::string objects by value rather than pass by reference [ajrhacker]
2016-01-11 09:18:43 +01:00
AJR
115db95642 Return std::string objects by value rather than pass by reference
- strprintf is unaltered, but strformat now takes one fewer argument
- state_string_export still fills a buffer, but has been made const
- get_default_card_software now takes no arguments but returns a string
2016-01-10 16:36:18 -05:00
Miodrag Milanovic
30c10f6f79 modernized ui_input_manager (nw) 2016-01-10 20:32:30 +01:00
Miodrag Milanovic
ce75a5d682 removed memory tracking (nw) 2016-01-08 12:41:13 +01:00
Con Huevos Guey
d940950b85 Update debugcon.h
Increased MAX_COMMAND PARAMS and MAX_COMMAND_LENGTH to quadruple their previous size.  The previous values did not have the capacity to allow trace logging of all registers at the same time in some CPUS.  Setting the maximum to 128 should allow for capturing of systems with large symbolic lists (such as Playstation) if needed. 

For example, the following command would throw an error when trace logging a 68000 CPU because the maximum parameters (16) would be reached when attempting to capture all registers:

trace 68K.log,0,{tracelog "A0=%08X, A1=%08X, A2=%08X, A3=%08X, A4=%08X, A5=%08X, A6=%08X, A7=%08X, D0=%08X, D1=%08X, D2=%08X, D3=%08X, D4=%08X, D5=%08X, D6=%08X, D7=%08X ",a0,a1,a2,a3,a4,a5,a6,a7,d0,d1,d2,d3,d4,d5,d6,d7}
2015-12-31 13:42:55 -06:00
Miodrag Milanovic
4afd75e2fd Cleanups and version bump 2015-12-30 08:18:51 +01:00
Miodrag Milanovic
94bc7eed38 cleanup (nw) 2015-12-25 12:09:50 +01:00
Miodrag Milanovic
a55ab6d615 some handmade changes (nw) 2015-12-21 16:01:14 +01:00
Miodrag Milanovic
379581fb36 macro removal INLINE -> static inline (nw) 2015-12-12 08:58:57 +01:00
Miodrag Milanovic
c98724d841 Fixed uninitialized variables, detected by VS2015 x64 build (nw) 2015-12-07 19:20:42 +01:00
yz70s
83f758cbeb Show more digits in fp values (issue #476) 2015-12-06 23:33:03 +01:00
yz70s
e76dc64868 Show 64 and 80 bit floats in windows and qt debugger (issue #476) 2015-12-06 23:33:03 +01:00
Miodrag Milanovic
91605d3f4d clang-modernize part 1 (nw) 2015-12-03 18:17:25 +01:00
yz70s
b052dcb402 First commit for issue #476
"byte per chunk" is sostituted by "data format"
  data formats lesser than 9 work as before, data format 9 is 32 but floating point
  in the debug_view_memory class method bytes_per_chunk is substituted by get_data_format, set_bytes_per_chunk is substituted by set_data_format
  floating point values cannot be edited
  currently floating point values are available only in the windows debugger, next commit will add them to the qt debugger, osx i won't be able to do it
  afterwards 64 and 80 bit formats will be added
2015-11-30 10:15:25 +01:00
Miodrag Milanovic
61d05aacb8 Fixed some suggestions by ReSharper C++ (nw) 2015-11-14 19:05:18 +01:00
Miodrag Milanovic
19ff46c113 More cleanups (nw) 2015-11-11 18:07:13 +01:00
Miodrag Milanovic
d1dc775f9b Some cleanups and init fixes with help of ReSharper C++ (nw) 2015-11-11 16:31:18 +01:00
Miodrag Milanovic
7c19aac60e Rename *.c -> *.cpp in our source (nw) 2015-11-08 12:56:12 +01:00
Miodrag Milanovic
b6707c3bb5 Removed mongoose due to restricted license and webserver wip till code is restructured (nw) 2015-11-04 18:55:36 +01:00
Miodrag Milanovic
18188cb13b making logerror part of machine and device classes [Miodrag Milanovic]
display tag of device that logged message
2015-11-01 14:34:45 +01:00
yz70s
28919d81a6 Give message if debugger comments are not saved (nw) 2015-10-07 07:12:33 +02:00
Miodrag Milanovic
05c7edb199 Remove direct zlib dependency in code (nw) 2015-09-13 12:27:46 +02:00
Olivier Galibert
1662e179be *duh* 2015-06-24 09:11:05 +02:00
Olivier Galibert
88949a5b47 memory: Remove support for decrypted bases, use an address space instead [O. Galibert] 2015-06-24 08:43:34 +02:00
Aaron Giles
1763f18b96 License self-service.
License self-service. Mostly adding attribution where I made significant
contributions. In a few cases files I previously missed were
default-attributed to Nicola.
2015-05-25 10:24:34 -07:00
Miodrag Milanovic
e4b919213e lot more updated (nw) 2015-05-11 15:09:24 +02:00
Miodrag Milanovic
6d902a08bd Added dummy license headers for EMU section (nw) 2015-05-07 10:45:57 +02:00
Miodrag Milanovic
76b978d039 Cleanups and version bump 2015-04-29 08:18:54 +02:00
Miodrag Milanovic
54f8b3ae5d moved all to std::string (nw) 2015-04-22 11:30:45 +02:00
Miodrag Milanovic
71c4d9f304 removed bool conversion and implicit empty check (nw) 2015-04-19 12:08:52 +02:00
Miodrag Milanovic
3c3ee1d177 more conversions to std::string (nw) 2015-04-19 08:08:34 +02:00
Olivier Galibert
278cf84e55 Replace dynamic_array with std::vector [O. Galibert] 2015-04-14 19:58:17 +02:00
Miodrag Milanovic
7faba31b1b There is no implicit conversion to char* in std::string (nw) 2015-04-12 08:05:43 +02:00
Miodrag Milanovic
c375452b53 Merge branch 'master' of https://github.com/mamedev/mame 2015-04-11 15:27:27 +02:00
Miodrag Milanovic
6b36c7ab22 cstr() - > c_str() as preparation for move to std::string (nw) 2015-04-11 15:26:58 +02:00
Vas Crabb
38c6213665 Replace simple_set with std::set 2015-04-11 22:30:44 +10:00
hap
f1419f6a95 for raw opcode view, don't crop under minbytes 2015-03-12 14:54:25 +01:00
Vas Crabb
0853e5f3b6 Fix assert on opening empty watchpoints/breakpoints windows 2015-02-26 01:28:03 +11:00
Miodrag Milanovic
6ae44e46f9 Cleanups and version bump 2015-02-25 08:09:13 +01:00
Vas Crabb
2c4d4a7837 Many fixes for breakpoints/watchpoints views
* Fix sorting - qsort needs a ternary -1/0/1 comparator
* Get rid of the redundant enums - using a funciton pointer is far more concise
* Reduce number of allocations and use less expensive functions when updating
* Fix off-by-one error that could cause a crash when clicking the views
* Get rid of double iteration
2015-02-23 04:23:13 +11:00
Vas Crabb
01ec6458ff Make opening a break/watchpoints window work better if there are already ten or more of them 2015-02-23 04:23:12 +11:00
Vas Crabb
0edcf59a50 Use uppercase ID in break/watchpoints windows to match how it's printed on the console; notify disassembly views on changing breakpoints to prevent Qt debugger menus becoming stale 2015-02-22 01:19:10 +11:00
Vas Crabb
2bb9137fdf Make the (watch|break)points notify correctly in response to clicks 2015-02-21 06:44:12 +11:00
Vas Crabb
2b30744752 Make return type match value being returned 2015-02-20 20:16:29 +11:00
Vas Crabb
58960a48c1 Fix debugger crash when setting bytes per chunk to more than current bytes per line 2015-02-19 04:42:49 +11:00
Robert
d90f5edfe5 debug: reverted dasm window change. (nw) 2014-12-24 09:32:51 +11:00
Fabrice Bellet
de398d972e debug: fix wrong initial m_topleft.x value in memory view 2014-12-18 08:27:14 +01:00
Fabrice Bellet
d77c58794b debug: better handling of duplicate memory access
Don't remove and reinsert nodes that correspond to a duplicate memory
access, because tree rebalancing kills performances. Update the node's
element content instead.
2014-12-18 08:27:14 +01:00
Fabrice Bellet
195e3de0f2 debug: dont update asm view in the start_hook()
The curpc can be in the middle of an instruction being decoded, so
it is not pertinent to recompute the disassembly starting from
this address.
2014-12-18 08:27:14 +01:00
Fabrice Bellet
146393cf11 debug: fix a string overflow in comments 2014-12-18 08:27:14 +01:00
Alex W. Jackson
adfefa9f34 Fix debugger memory display of little-endian memory regions [Alex Jackson] 2014-12-09 21:18:05 -05:00
Zoë Blade
44322992e5 Fix various typos
Squashed commit of the following:

commit 040fd169bfd6845b33d3f86fd66afb4a632605c6
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sun Nov 30 22:24:30 2014 +0000

    Fix more typos in comments

commit 6121ae593008a574735427e047fdb7a16f4fa47f
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sun Nov 30 22:20:37 2014 +0000

    Fix more typos

    Not all are in comments this time, but the vast majority are, and
    the rest are in printed text.  None are variable or constant names.

commit 84bc72573009bb46f5601f7257a7f7538f25cfc2
Author: Zoë Blade <zoe@bytenoise.co.uk>
Date:   Sun Nov 30 22:01:46 2014 +0000

    Fix some typos
2014-11-30 22:29:32 +00:00
Alex W. Jackson
d68a3a45b3 Touching all the candy again: [Alex Jackson]
Fixed an annoying inconsistency between memory_share and memory_region:
the width() method of the former returned the width in bits (8, 16, 32 or 64)
while the width() method of the latter returned the width in bytes
(1, 2, 4 or 8). Now both classes have a bitwidth() method and a bytewidth()
method. Updated all callers to use whichever one was more appropriate.

Removed the implicit-cast-to-any-integer-pointer ability of memory_regions,
which was rather unsafe (if you weren't careful with your * operators and
casts it was easy to accidentally get a pointer to the memory_region object
itself instead of to the data, with no warning from the compiler... or at
least I kept doing it) Updated all devices and drivers that were accessing
regions that way to use a region_ptr_finder when possible, and otherwise to
call base() explicitly.
2014-11-17 17:03:54 -05:00
Andrew Gardner
846d034c3a Fixed strange display of long strings in Qt debugger (nw). 2014-10-19 12:44:24 +00:00
Miodrag Milanovic
c93ed344fb Cleanups and version bump 2014-10-15 07:19:47 +00:00
Scott Stone
3b23f9c85e Make cheat initialization debugger message more verbose. [Pugsy] 2014-10-08 23:57:17 +00:00
Alex W. Jackson
ace8c59d1a Memory system and Namco improvements: [Alex Jackson]
Explicit regions in address maps (AM_REGION) are now looked up relative to the
device rather than as siblings when in an internal address map (similar to
devices and shared pointers)  Besides being more orthogonal than before, this
allows internal ROMs of MCUs and similar devices to be hooked up in a nicer
and more foolproof way. Updated the m37710 and m5074x (m6502 derivative)
to take advantage of this.

Divided the M37702/M37710 into specific models, with each model having its own
internal address map containing the correct amounts of internal RAM and ROM.

M37702 MCUs found on various Namco PCBs are now all unique devices and have
their respective internal ROMs loaded as device ROMs.

(nw)
Also did some spring (fall) cleaning in addrmap.c/memory.c/dimemory.c

m_devbase (the base device used for tagmap lookup when late-binding handlers and
finding memory regions and shares) is now a reference rather than a pointer,
since we know what it is when the address_map_entry is constructed and it
doesn't change (it depends solely on whether it's an entry in an MCFG-provided
address map or an internal one) And for the same reason, there's now only one
m_devbase per address_map_entry rather than individual copies for
read/write/setoffset/sharedptr.

Removed mysterious unused address_map_entry member "m_region_string", along
with a silly assert probably left over from when Aaron was replacing AM_BASE
with AM_SHARE years ago.

Added a comment noting that "make sure all devices exist" in
device_memory_interface::interface_validity_check() actually does nothing,
like the proverbial goggles. The reason there's just a comment and not a fix
is I haven't figured out how to fix it yet
(is it possible to extract the original device tag that was given to a
proto-delegate? Sorry, the template hell in devdelegate.h and
lib/util/delegate.h makes me want to run screaming like a little girl)
2014-09-18 01:07:22 +00:00
Oliver Stöneberg
3568cf772f fixed most of the -Wunreachable-code-break and -Wunreachable-code-return warnings of clang 3.5 when compiling MESS (nw) 2014-09-08 12:00:45 +00:00
Miodrag Milanovic
d14d6a8099 Do web serving in main thread (nw) 2014-09-08 07:51:14 +00:00
Scott Stone
f5d2eb5c6c Fix uninitialized auto; should fix instances where a game with cheats active using multiple expressions in one action crashes at start. [m4st4] 2014-07-21 23:58:30 +00:00
Oliver Stöneberg
f59638c2a1 more passing of attotime as const references (nw) 2014-07-04 07:17:48 +00:00
Alex W. Jackson
b025f698a1 m68000: Do what the real M68K does on byte writes. Fix the debugger so watchpoints continue to work as expected [Alex Jackson] 2014-05-30 04:05:49 +00:00
Sandro Ronco
64f307a27b Fixed cheatnext command. (nw) 2014-05-19 20:05:10 +00:00
Miodrag Milanovic
69faaf3aeb -Reorganized OSD, handling more sound output systems and debuggers, defaults left same as before [Miodrag Milanovic]
-Created osd_options as base option class for non-system specific options
2014-05-08 07:39:04 +00:00
Miodrag Milanovic
67663501d7 Moved eminline and related files into /src/osd since it's system related (nw)
Moved delegates into /src/lib/util to enable usage of delegates in other project parts

Moved mame_printf_* calls into /src/osd/osdcore.c and renamed them to osd_printf_* 

Changed mess.mak to display compilation of ymmu100.ppm nicely
2014-04-16 08:04:20 +00:00
Alex W. Jackson
6513c5b67e device_gfx_interface and memory system improvements: [Alex Jackson]
Added macros to facilitate declaring gfxdecode info arrays as members
of a device class.

AM_SHAREs in a device's internal address map or its default address map are
now tagmapped as children of that device rather than siblings (analogous
to how handlers in internal/default address maps are scoped).

Converted the Namco C45 to device_gfx_interface.
2014-04-08 15:41:46 +00:00
Oliver Stöneberg
f2de945ef9 use ARRAY_LENGTH (nw) 2014-04-03 22:48:35 +00:00
Miodrag Milanovic
de513a0f98 reverting, sorry for this vconv needs to be updated (nw) 2014-03-31 10:23:22 +00:00
Miodrag Milanovic
2cc9ca4c5e VS2013 x64 is little bit more anal about signed/unsigned comparison (nw) 2014-03-31 10:06:05 +00:00
Miodrag Milanovic
b297c61ebd made MAME and MESS compile under VS2013, 32bit only for now (nw)
OG: please check things in H8 core, thing in timer16 can caused some issues in past
2014-03-31 08:29:30 +00:00
Oliver Stöneberg
6bd1f0b658 osd_* -> global_* compilation fixes (nw) 2014-03-24 22:16:44 +00:00
Oliver Stöneberg
2e5ea37f65 removed mame_* aliases and just use core_* functions (nw) 2014-03-24 22:05:08 +00:00
Oliver Stöneberg
7a135e058a do not use osd_malloc/osd_free in non-OSD code (nw) 2014-03-24 21:56:16 +00:00
Aaron Giles
19bd5c8117 Nuke some more auto_allocs. 2014-03-16 05:41:28 +00:00
Miodrag Milanovic
a66aff27d6 primary_screen -> first_screen() (nw) 2014-03-15 13:00:23 +00:00
Aaron Giles
4ea9df02a1 Moved core template container classes up from emutempl.h to coretmpl.h:
[Aaron Giles]
 * these classes now no longer take a resource_pool; everything is
    managed globally -- this means that objects added to lists must be
    allocated with global_alloc
 * added new auto_pointer<> template which wraps a pointer and auto-frees
    it upon destruction; it also defaults to NULL so it doesn't need to
    be explicitly initialized
 * moved tagged_list template to tagmap.h

Redo of the low-level memory tracking system: [Aaron Giles]
 * moved low-level tracking out of emu\emualloc into lib\util\corealloc
    so it can be shared among all components and used by core libraries
 * global_alloc and friends no longer use a resource pool to track
    allocations; turns out this was a wholly redundant system that wasted
    a lot of memory
 * removed global_resource_pool entirely
 * added global_free_array to delete arrays allocated with 
    global_alloc_array
 * added tracking of object versus array allocation; we will now error
    if you use global_free on an array, or global_free_array on an object

Added new utility helper const_string_pool which can be used to 
efficiently accumulate strings that are not intended to be modified.
Used by updated makelist and software list code. [Aaron Giles]

Updated png2bdc and makelist tools to not leak memory and use more modern
techniques (no more MAX_DRIVERS in makelist, for example). [Aaron Giles]

Deprecated auto_strdup and removed all uses by way of caller-managed 
astrings and the software list rewrite. [Aaron Giles]

Rewrote software list management: [Aaron Giles]
 * removed the notion of a software_list that is separate from a
    software_list_device; they are one and the same now
 * moved several functions into device_image_interface since they really
    didn't belong in the core software list class
 * lots of simplification as a result of the above changes

Additional notes (no whatsnew):

Moved definition of FPTR to osdcomm.h.

Some changes happened in the OSD code to fix issues, especially regarding
freeing arrays. SDL folks may need to fix up some of these.

The following devices still are using tokens and should be modernized
(I found them because they kept their token as void * and tried to
delete it, which you can't):

namco_52xx_device (mame/audio/namco52.c)
namco_54xx_device (mame/audio/namco54.c)
namco_06xx_device (mame/machine/namco06.c)
namco_50xx_device (mame/machine/namco50.c)
namco_51xx_device (mame/machine/namco51.c)
namco_53xx_device (mame/machine/namco53.c)
voodoo_device (emu/video/voodoo.c)
mos6581_device (emu/sound/mos6581.c)
aica_device (emu/sound/aica.c)
scsp_device (emu/sound/scsp.c)
dmadac_sound_device (emu/sound/dmadac.c)
s3c2440_device (emu/machine/s3c2440.c)
wd1770_device (emu/machine/wd17xx.c)
latch8_device (emu/machine/latch8.c)
duart68681_device (emu/machine/68681.c)
s3c2400_device (emu/machine/s3c2400.c)
s3c2410_device (emu/machine/s3c2410.c)
strataflash_device (mess/machine/strata.c)
hd63450_device (mess/machine/hd63450.c)
tap_990_device (mess/machine/ti99/990_tap.c)
omti8621_device (mess/machine/omti8621.c)
vdt911_device (mess/video/911_vdt.c)
apollo_graphics_15i (mess/video/apollo.c)
asr733_device (mess/video/733_asr.c)
2014-03-11 15:54:58 +00:00
Oliver Stöneberg
5278254236 rest of ATTR_PRINTF review (nw) 2014-02-25 12:25:33 +00:00
Aaron Giles
dd15b719a3 Another round of auto_alloc_array conversions.
Some minor enhancements to dynamic_array, including clearing to specific values
and expanding and clearing newly allocated values.
2014-02-20 18:11:00 +00:00
Couriersud
00391468b0 Fixed a bug preventing memory display of INT8/UINT8 in debugger [Couriersud] 2013-12-24 13:53:11 +00:00
Aaron Giles
5d0ce54f9e Bulk convert files that already had standard BSD license in my name
to new license tagged form.
2013-10-16 08:14:49 +00:00
Miodrag Milanovic
96aa5e1c08 Cleanups and version bump 2013-09-17 06:47:03 +00:00
Dirk Best
273fe7960e added support to display dividers in the debugger state view
i8089: improved debugger view
2013-08-25 12:23:20 +00:00
Andrew Gardner
6ab38a50ef Fixed the build. 2013-07-26 03:40:55 +00:00
Andrew Gardner
a53b68ddb6 Adds a watchpoint debug view. [Andrew Gardner] 2013-07-26 00:48:19 +00:00
Miodrag Milanovic
14629cbcb4 Cleanups and version bump 2013-07-23 07:18:56 +00:00
smf-
2e9622ecdb Fixes for building MAME with Visual Studio 2013 preview [smf] 2013-07-05 00:45:14 +00:00
Andrew Gardner
e74983f6f8 QT Debugger: Finished up the breakpoints window. [Andrew Gardner]
It now shows breakpoints for all CPUs and lets you sort by
each field.
2013-06-12 06:22:35 +00:00
Miodrag Milanovic
16f5234d43 Cleanups and version bump 2013-06-11 07:16:42 +00:00
Andrew Gardner
32861d94f5 QT Debugger: WIP for a new breakpoints window. [Andrew Gardner]
--out of whatsnew.txt--
You can't click to enable/disable breakpoints yet, and the number of rows 
doesn't resize yet, but that stuff will come.
2013-06-06 17:58:16 +00:00
Miodrag Milanovic
1c05ccc93b Cleanups and version bump 2013-05-20 06:51:25 +00:00
Andrew Gardner
9007f91982 Adds statesave (ss) & stateload (sl) commands to the debugger. [Andrew Gardner] 2013-05-14 04:24:31 +00:00