Commit Graph

433 Commits

Author SHA1 Message Date
Nathan Woods
baae7b926d Made imgtool_image (now imgtool::image) a "real" C++ class 2016-09-27 05:13:32 -04:00
Vas Crabb
33b2c73395 srcclean (nw) 2016-09-26 04:51:59 +10:00
Vas Crabb
7867c0ed7d Merge pull request #1444 from npwoods/imgtool_readsector_uses_stdvector
Imgtool:  Changed the read_sector apparatus to use std::vector
2016-09-26 03:34:26 +10:00
Nathan Woods
c87e7953fa Changing bad_alloc catch declarations 2016-09-25 13:31:46 -04:00
Nathan Woods
f83fce0c28 Putting try { ... } catch(std::bad_alloc &) { ... } around recently introduced resize() calls
At the very least, I suppose this doesn't hurt; I'd just like to discuss how this should work in the long run.

Also, this blog entry sums up my opinion perfectly:  http://christiangarbin.blogspot.com/2013/05/the-futility-of-catching-stdbadalloc.html
2016-09-25 07:30:03 -04:00
Nathan Woods
89512850bc Retired imgtool_basename(), in favor of core_filename_extract_base() 2016-09-24 18:50:43 -04:00
Nathan Woods
5f3bb35b12 Imgtool: Changed the read_sector apparatus to use std::vector
This also eliminated the need for get_sector_size

The asute reviewer will note that a side effect of this change is that in scenarios where we once returned IMGTOOLERR_OUTOFMEMORY, we now throw std::bad_alloc.  This is deliberate.  Having an error code for out of memory conditions no longer makes sense with MAME's embrace of the C++ way of doing things.  It is highly likely that I will follow up this change with one that eliminates IMGTOOLERR_OUTOFMEMORY in favor of throwing std::bad_alloc.

This commit also fixes a recent regression in which we passed nullptr to an std::string ctor
2016-09-24 09:56:47 -04:00
fulivi
dedc07dc75 imgtool, hp9845_tape format: implemented read & write ops in 9845data filter 2016-09-23 15:57:56 +02:00
fulivi
d7ca7f0cf5 imgtool, hp9845_tape format: implemented read filter for text-only DATA
files (write op. still missing)
2016-09-22 15:27:50 +02:00
R. Belmont
0ecea843d0 Merge pull request #1398 from fulivi/hp9845_tools
Imgtool now supports HP9845B tape image
2016-09-16 14:05:35 -04:00
Nathan Woods
ab20ce4228 Vas Crabb feedback 2016-09-14 23:42:52 -04:00
fulivi
e25e1b84b0 imgtool, hp9845_tape format: write&del done, brief info added at the
start of file.
2016-09-13 16:44:37 +02:00
Nathan Woods
9a3ac8f6b8 Imgtool: Changed the Imgtool module list to be std::list 2016-09-10 12:17:36 -04:00
Nathan Woods
3534b0090a Imgtool: C++-ized the imgtool_library object (now class imgtool::library) 2016-09-10 12:14:12 -04:00
fulivi
e39c05c165 imgtool: WIP on hp9845 tape: read done, write & del to be done 2016-09-10 15:52:06 +02:00
fulivi
0474948833 imgtool: WIP for hp9845 tape support 2016-09-10 15:52:06 +02:00
fulivi
68509a3191 hp_hybrid: added hp_hybrid & hp_5061_3001 to unidasm 2016-09-10 15:52:05 +02: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
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
9c06ec0b6a Incorporating Vas Crabb feedback 2016-09-01 06:49:54 -04:00
Vas Crabb
234e91f9fb Add Lua-cleaning ability to srcclean 2016-08-30 14:57:38 +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
Nathan Woods
0931cbafb0 castool fix 2016-08-21 12:47:37 -04:00
Vas Crabb
3c47e78419 clang didn't like that... 2016-08-04 13:30:57 +10:00
Vas Crabb
938371b64f remove leftover crud (nw) 2016-08-03 13:56:52 +10:00
Vas Crabb
996935a7cc fix overlong code detection in srcclean 2016-08-02 17:50:39 +10:00
Vas Crabb
d7f9370892 Make srcclean a bit more forgiving 2016-08-02 17:12:06 +10:00
Vas Crabb
889ecdfd4f Let's give the new srcclean a spin... 2016-08-02 16:59:02 +10:00
Vas Crabb
a26a40445b Re-write srcclean to be cool with UTF-8 and C++14 [Vas Crabb] 2016-08-02 16:46:46 +10:00
Vas Crabb
0ceae26bb4 patch up on OSX 2016-08-01 01:37:39 +10: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
Vas Crabb
05444e3c00 unbreak large files in chdman after refactor 2016-08-01 00:17:52 +10:00
Miodrag Milanovic
8594237ba6 imgtool fix (nw) 2016-07-31 15:49:22 +02:00
Miodrag Milanovic
185f5059fb algorithm-> utility where appropriate, fix imgtool (nw) 2016-07-31 15:37:37 +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
MetalliC
2cf35d78d8 chdman: fix remaining createcd 64bit issues 2016-07-24 17:01:18 +03:00
Miodrag Milanovic
0a95a35f0d compile fix (nw) 2016-07-23 19:14:45 +02:00
Miodrag Milanovic
38e8953add try one old good fix (nw) 2016-07-23 18:48:41 +02:00
Miodrag Milanovic
17080e6959 Revert "fix building with gcc 6.1.0 by making it consistent with other source files. (nw)"
This reverts commit 4423c242a6.
2016-07-23 18:47:39 +02:00
smf-
4423c242a6 fix building with gcc 6.1.0 by making it consistent with other source files. (nw) 2016-07-23 16:18:34 +01:00
Nathan Woods
130e05cc4e Fixed stupid compilation error 2016-07-11 08:26:49 -04:00
Nathan Woods
96066caca0 Removed some c_str() calls that are no longer necessary 2016-07-11 07:24:02 -04:00
Vas Crabb
6a67de94f9 Fix up imgtool as well 2016-07-08 15:29:50 +10:00
Vas Crabb
d3b553728d Add support for showing will branch/will fall through comment on SPARC branches under the cursor
Disabled until we can get a hook to refress the instructions under PC when stepping
2016-06-27 16:59:42 +10: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
Vas Crabb
64f9a674d1 SPARC VIS 2+, VIS 3 and VIS 3B disassembler support [Vas Crabb]
* Note that this omits non-VIS OSA 2007/2011 features
* VIS 2+ ldtxa/ldtwa/sttwa still uses ldda/stda, using new mnemonics requires special-casing this instruction and checking ASI
2016-06-24 03:00:01 +10:00
Vas Crabb
32a75e7ae4 VIS I (UltraSPARC) and II (UltraSPARC III) for SPARC disassembler [Vas Crabb]
* Supports %gsr, all ops with exception of SIAM, and all ASI constants
* Use -arch sparcv9vis1 or -arch sparcv9vis2 with unidasm
2016-06-23 01:13:52 +10:00
Vas Crabb
af406e316a Add SPARC to unidasm [Vas Crabb] 2016-06-22 13:35:20 +10:00
Miodrag Milanovic
1d0e0ac12a remove all usages of tagmap 2016-06-18 15:32:15 +02:00