mirror of
https://github.com/holub/mame
synced 2025-06-06 21:03:47 +03:00
Change debugger command handler parameter vector element type from std::string to std::string_view
This commit is contained in:
parent
786016ae25
commit
9d0076ab91
@ -862,17 +862,17 @@ bool arm7_cpu_device::translate_vaddr_to_paddr(offs_t &vaddr, const int flags)
|
||||
}
|
||||
}
|
||||
|
||||
void arm7_cpu_device::translate_insn_command(const std::vector<std::string> ¶ms)
|
||||
void arm7_cpu_device::translate_insn_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
translate_command(params, TRANSLATE_FETCH);
|
||||
}
|
||||
|
||||
void arm7_cpu_device::translate_data_command(const std::vector<std::string> ¶ms)
|
||||
void arm7_cpu_device::translate_data_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
translate_command(params, TRANSLATE_READ);
|
||||
}
|
||||
|
||||
void arm7_cpu_device::translate_command(const std::vector<std::string> ¶ms, int intention)
|
||||
void arm7_cpu_device::translate_command(const std::vector<std::string_view> ¶ms, int intention)
|
||||
{
|
||||
uint64_t vaddr;
|
||||
|
||||
|
@ -146,9 +146,9 @@ protected:
|
||||
|
||||
uint32_t m_r[/*NUM_REGS*/37];
|
||||
|
||||
void translate_insn_command(const std::vector<std::string> ¶ms);
|
||||
void translate_data_command(const std::vector<std::string> ¶ms);
|
||||
void translate_command(const std::vector<std::string> ¶ms, int intention);
|
||||
void translate_insn_command(const std::vector<std::string_view> ¶ms);
|
||||
void translate_data_command(const std::vector<std::string_view> ¶ms);
|
||||
void translate_command(const std::vector<std::string_view> ¶ms, int intention);
|
||||
|
||||
void update_insn_prefetch(uint32_t curr_pc);
|
||||
bool insn_fetch_thumb(uint32_t pc, uint32_t &out_insn);
|
||||
|
@ -51,7 +51,7 @@ device_memory_interface::space_config_vector acorn_memc_device::memory_space_con
|
||||
};
|
||||
}
|
||||
|
||||
void acorn_memc_device::memc_map_debug_commands(const std::vector<std::string> ¶ms)
|
||||
void acorn_memc_device::memc_map_debug_commands(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
uint64_t offset;
|
||||
if (params.size() != 1 || !machine().debugger().commands().validate_number_parameter(params[0], offset))
|
||||
|
@ -60,7 +60,7 @@ protected:
|
||||
virtual space_config_vector memory_space_config() const override;
|
||||
|
||||
private:
|
||||
void memc_map_debug_commands(const std::vector<std::string> ¶ms);
|
||||
void memc_map_debug_commands(const std::vector<std::string_view> ¶ms);
|
||||
uint32_t dram_address(uint32_t address);
|
||||
bool is_valid_access(int page, bool write);
|
||||
uint32_t invalid_access(bool is_write, offs_t offset, uint32_t data, uint32_t mem_mask = ~0);
|
||||
|
@ -982,7 +982,7 @@ bool sun4_mmu_base_device::translate(uint32_t &addr)
|
||||
return entry.valid;
|
||||
}
|
||||
|
||||
void sun4_mmu_base_device::l2p_command(const std::vector<std::string> ¶ms)
|
||||
void sun4_mmu_base_device::l2p_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
uint64_t addr, offset;
|
||||
|
||||
|
@ -137,7 +137,7 @@ protected:
|
||||
void type0_timeout_r(const uint32_t offset);
|
||||
void type0_timeout_w(const uint32_t offset);
|
||||
bool translate(uint32_t &addr);
|
||||
void l2p_command(const std::vector<std::string> ¶ms);
|
||||
void l2p_command(const std::vector<std::string_view> ¶ms);
|
||||
uint32_t vaddr_to_cache_line(uint32_t vaddr);
|
||||
|
||||
enum
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -25,7 +25,7 @@ public:
|
||||
debugger_commands(running_machine &machine, debugger_cpu &cpu, debugger_console &console);
|
||||
|
||||
// validates a parameter as a boolean value
|
||||
bool validate_boolean_parameter(const std::string ¶m, bool &result);
|
||||
bool validate_boolean_parameter(std::string_view param, bool &result);
|
||||
|
||||
// validates a parameter as a numeric value
|
||||
bool validate_number_parameter(std::string_view param, u64 &result);
|
||||
@ -90,7 +90,7 @@ private:
|
||||
device_t &get_device_search_base(std::string_view ¶m);
|
||||
device_t *get_cpu_by_index(u64 cpunum);
|
||||
bool debug_command_parameter_expression(std::string_view param, parsed_expression &result);
|
||||
bool debug_command_parameter_command(const char *param);
|
||||
bool debug_command_parameter_command(std::string_view param);
|
||||
|
||||
bool cheat_address_is_valid(address_space &space, offs_t address);
|
||||
|
||||
@ -101,87 +101,87 @@ private:
|
||||
|
||||
bool mini_printf(std::ostream &stream, std::string_view format, int params, u64 *param);
|
||||
template <typename T>
|
||||
void execute_index_command(std::vector<std::string> const ¶ms, T &&apply, char const *unused_message);
|
||||
void execute_index_command(std::vector<std::string_view> const ¶ms, T &&apply, char const *unused_message);
|
||||
|
||||
void execute_help(const std::vector<std::string> ¶ms);
|
||||
void execute_print(const std::vector<std::string> ¶ms);
|
||||
void execute_printf(const std::vector<std::string> ¶ms);
|
||||
void execute_logerror(const std::vector<std::string> ¶ms);
|
||||
void execute_tracelog(const std::vector<std::string> ¶ms);
|
||||
void execute_tracesym(const std::vector<std::string> ¶ms);
|
||||
void execute_cls(const std::vector<std::string> ¶ms);
|
||||
void execute_quit(const std::vector<std::string> ¶ms);
|
||||
void execute_do(const std::vector<std::string> ¶ms);
|
||||
void execute_step(const std::vector<std::string> ¶ms);
|
||||
void execute_over(const std::vector<std::string> ¶ms);
|
||||
void execute_out(const std::vector<std::string> ¶ms);
|
||||
void execute_go(const std::vector<std::string> ¶ms);
|
||||
void execute_go_vblank(const std::vector<std::string> ¶ms);
|
||||
void execute_go_interrupt(const std::vector<std::string> ¶ms);
|
||||
void execute_go_exception(const std::vector<std::string> ¶ms);
|
||||
void execute_go_time(const std::vector<std::string> ¶ms);
|
||||
void execute_go_privilege(const std::vector<std::string> ¶ms);
|
||||
void execute_go_branch(bool sense, const std::vector<std::string> ¶ms);
|
||||
void execute_go_next_instruction(const std::vector<std::string> ¶ms);
|
||||
void execute_focus(const std::vector<std::string> ¶ms);
|
||||
void execute_ignore(const std::vector<std::string> ¶ms);
|
||||
void execute_observe(const std::vector<std::string> ¶ms);
|
||||
void execute_suspend(const std::vector<std::string> ¶ms);
|
||||
void execute_resume(const std::vector<std::string> ¶ms);
|
||||
void execute_next(const std::vector<std::string> ¶ms);
|
||||
void execute_cpulist(const std::vector<std::string> ¶ms);
|
||||
void execute_time(const std::vector<std::string> ¶ms);
|
||||
void execute_comment_add(const std::vector<std::string> ¶ms);
|
||||
void execute_comment_del(const std::vector<std::string> ¶ms);
|
||||
void execute_comment_save(const std::vector<std::string> ¶ms);
|
||||
void execute_comment_list(const std::vector<std::string> ¶ms);
|
||||
void execute_comment_commit(const std::vector<std::string> ¶ms);
|
||||
void execute_bpset(const std::vector<std::string> ¶ms);
|
||||
void execute_bpclear(const std::vector<std::string> ¶ms);
|
||||
void execute_bpdisenable(bool enable, const std::vector<std::string> ¶ms);
|
||||
void execute_bplist(const std::vector<std::string> ¶ms);
|
||||
void execute_wpset(int spacenum, const std::vector<std::string> ¶ms);
|
||||
void execute_wpclear(const std::vector<std::string> ¶ms);
|
||||
void execute_wpdisenable(bool enable, const std::vector<std::string> ¶ms);
|
||||
void execute_wplist(const std::vector<std::string> ¶ms);
|
||||
void execute_rpset(const std::vector<std::string> ¶ms);
|
||||
void execute_rpclear(const std::vector<std::string> ¶ms);
|
||||
void execute_rpdisenable(bool enable, const std::vector<std::string> ¶ms);
|
||||
void execute_rplist(const std::vector<std::string> ¶ms);
|
||||
void execute_statesave(const std::vector<std::string> ¶ms);
|
||||
void execute_stateload(const std::vector<std::string> ¶ms);
|
||||
void execute_rewind(const std::vector<std::string> ¶ms);
|
||||
void execute_save(int spacenum, const std::vector<std::string> ¶ms);
|
||||
void execute_saveregion(const std::vector<std::string> ¶ms);
|
||||
void execute_load(int spacenum, const std::vector<std::string> ¶ms);
|
||||
void execute_loadregion(const std::vector<std::string> ¶ms);
|
||||
void execute_dump(int spacenum, const std::vector<std::string> ¶ms);
|
||||
void execute_strdump(int spacenum, const std::vector<std::string> ¶ms);
|
||||
void execute_cheatrange(bool init, const std::vector<std::string> ¶ms);
|
||||
void execute_cheatnext(bool initial, const std::vector<std::string> ¶ms);
|
||||
void execute_cheatlist(const std::vector<std::string> ¶ms);
|
||||
void execute_cheatundo(const std::vector<std::string> ¶ms);
|
||||
void execute_dasm(const std::vector<std::string> ¶ms);
|
||||
void execute_find(int spacenum, const std::vector<std::string> ¶ms);
|
||||
void execute_fill(int spacenum, const std::vector<std::string> ¶ms);
|
||||
void execute_trace(const std::vector<std::string> ¶ms, bool trace_over);
|
||||
void execute_traceflush(const std::vector<std::string> ¶ms);
|
||||
void execute_history(const std::vector<std::string> ¶ms);
|
||||
void execute_trackpc(const std::vector<std::string> ¶ms);
|
||||
void execute_trackmem(const std::vector<std::string> ¶ms);
|
||||
void execute_pcatmem(int spacenum, const std::vector<std::string> ¶ms);
|
||||
void execute_snap(const std::vector<std::string> ¶ms);
|
||||
void execute_source(const std::vector<std::string> ¶ms);
|
||||
void execute_map(int spacenum, const std::vector<std::string> ¶ms);
|
||||
void execute_memdump(const std::vector<std::string> ¶ms);
|
||||
void execute_symlist(const std::vector<std::string> ¶ms);
|
||||
void execute_softreset(const std::vector<std::string> ¶ms);
|
||||
void execute_hardreset(const std::vector<std::string> ¶ms);
|
||||
void execute_images(const std::vector<std::string> ¶ms);
|
||||
void execute_mount(const std::vector<std::string> ¶ms);
|
||||
void execute_unmount(const std::vector<std::string> ¶ms);
|
||||
void execute_input(const std::vector<std::string> ¶ms);
|
||||
void execute_dumpkbd(const std::vector<std::string> ¶ms);
|
||||
void execute_help(const std::vector<std::string_view> ¶ms);
|
||||
void execute_print(const std::vector<std::string_view> ¶ms);
|
||||
void execute_printf(const std::vector<std::string_view> ¶ms);
|
||||
void execute_logerror(const std::vector<std::string_view> ¶ms);
|
||||
void execute_tracelog(const std::vector<std::string_view> ¶ms);
|
||||
void execute_tracesym(const std::vector<std::string_view> ¶ms);
|
||||
void execute_cls(const std::vector<std::string_view> ¶ms);
|
||||
void execute_quit(const std::vector<std::string_view> ¶ms);
|
||||
void execute_do(const std::vector<std::string_view> ¶ms);
|
||||
void execute_step(const std::vector<std::string_view> ¶ms);
|
||||
void execute_over(const std::vector<std::string_view> ¶ms);
|
||||
void execute_out(const std::vector<std::string_view> ¶ms);
|
||||
void execute_go(const std::vector<std::string_view> ¶ms);
|
||||
void execute_go_vblank(const std::vector<std::string_view> ¶ms);
|
||||
void execute_go_interrupt(const std::vector<std::string_view> ¶ms);
|
||||
void execute_go_exception(const std::vector<std::string_view> ¶ms);
|
||||
void execute_go_time(const std::vector<std::string_view> ¶ms);
|
||||
void execute_go_privilege(const std::vector<std::string_view> ¶ms);
|
||||
void execute_go_branch(bool sense, const std::vector<std::string_view> ¶ms);
|
||||
void execute_go_next_instruction(const std::vector<std::string_view> ¶ms);
|
||||
void execute_focus(const std::vector<std::string_view> ¶ms);
|
||||
void execute_ignore(const std::vector<std::string_view> ¶ms);
|
||||
void execute_observe(const std::vector<std::string_view> ¶ms);
|
||||
void execute_suspend(const std::vector<std::string_view> ¶ms);
|
||||
void execute_resume(const std::vector<std::string_view> ¶ms);
|
||||
void execute_next(const std::vector<std::string_view> ¶ms);
|
||||
void execute_cpulist(const std::vector<std::string_view> ¶ms);
|
||||
void execute_time(const std::vector<std::string_view> ¶ms);
|
||||
void execute_comment_add(const std::vector<std::string_view> ¶ms);
|
||||
void execute_comment_del(const std::vector<std::string_view> ¶ms);
|
||||
void execute_comment_save(const std::vector<std::string_view> ¶ms);
|
||||
void execute_comment_list(const std::vector<std::string_view> ¶ms);
|
||||
void execute_comment_commit(const std::vector<std::string_view> ¶ms);
|
||||
void execute_bpset(const std::vector<std::string_view> ¶ms);
|
||||
void execute_bpclear(const std::vector<std::string_view> ¶ms);
|
||||
void execute_bpdisenable(bool enable, const std::vector<std::string_view> ¶ms);
|
||||
void execute_bplist(const std::vector<std::string_view> ¶ms);
|
||||
void execute_wpset(int spacenum, const std::vector<std::string_view> ¶ms);
|
||||
void execute_wpclear(const std::vector<std::string_view> ¶ms);
|
||||
void execute_wpdisenable(bool enable, const std::vector<std::string_view> ¶ms);
|
||||
void execute_wplist(const std::vector<std::string_view> ¶ms);
|
||||
void execute_rpset(const std::vector<std::string_view> ¶ms);
|
||||
void execute_rpclear(const std::vector<std::string_view> ¶ms);
|
||||
void execute_rpdisenable(bool enable, const std::vector<std::string_view> ¶ms);
|
||||
void execute_rplist(const std::vector<std::string_view> ¶ms);
|
||||
void execute_statesave(const std::vector<std::string_view> ¶ms);
|
||||
void execute_stateload(const std::vector<std::string_view> ¶ms);
|
||||
void execute_rewind(const std::vector<std::string_view> ¶ms);
|
||||
void execute_save(int spacenum, const std::vector<std::string_view> ¶ms);
|
||||
void execute_saveregion(const std::vector<std::string_view> ¶ms);
|
||||
void execute_load(int spacenum, const std::vector<std::string_view> ¶ms);
|
||||
void execute_loadregion(const std::vector<std::string_view> ¶ms);
|
||||
void execute_dump(int spacenum, const std::vector<std::string_view> ¶ms);
|
||||
void execute_strdump(int spacenum, const std::vector<std::string_view> ¶ms);
|
||||
void execute_cheatrange(bool init, const std::vector<std::string_view> ¶ms);
|
||||
void execute_cheatnext(bool initial, const std::vector<std::string_view> ¶ms);
|
||||
void execute_cheatlist(const std::vector<std::string_view> ¶ms);
|
||||
void execute_cheatundo(const std::vector<std::string_view> ¶ms);
|
||||
void execute_dasm(const std::vector<std::string_view> ¶ms);
|
||||
void execute_find(int spacenum, const std::vector<std::string_view> ¶ms);
|
||||
void execute_fill(int spacenum, const std::vector<std::string_view> ¶ms);
|
||||
void execute_trace(const std::vector<std::string_view> ¶ms, bool trace_over);
|
||||
void execute_traceflush(const std::vector<std::string_view> ¶ms);
|
||||
void execute_history(const std::vector<std::string_view> ¶ms);
|
||||
void execute_trackpc(const std::vector<std::string_view> ¶ms);
|
||||
void execute_trackmem(const std::vector<std::string_view> ¶ms);
|
||||
void execute_pcatmem(int spacenum, const std::vector<std::string_view> ¶ms);
|
||||
void execute_snap(const std::vector<std::string_view> ¶ms);
|
||||
void execute_source(const std::vector<std::string_view> ¶ms);
|
||||
void execute_map(int spacenum, const std::vector<std::string_view> ¶ms);
|
||||
void execute_memdump(const std::vector<std::string_view> ¶ms);
|
||||
void execute_symlist(const std::vector<std::string_view> ¶ms);
|
||||
void execute_softreset(const std::vector<std::string_view> ¶ms);
|
||||
void execute_hardreset(const std::vector<std::string_view> ¶ms);
|
||||
void execute_images(const std::vector<std::string_view> ¶ms);
|
||||
void execute_mount(const std::vector<std::string_view> ¶ms);
|
||||
void execute_unmount(const std::vector<std::string_view> ¶ms);
|
||||
void execute_input(const std::vector<std::string_view> ¶ms);
|
||||
void execute_dumpkbd(const std::vector<std::string_view> ¶ms);
|
||||
|
||||
running_machine& m_machine;
|
||||
debugger_console& m_console;
|
||||
|
@ -133,7 +133,7 @@ inline bool debugger_console::debug_command::compare::operator()(const debug_com
|
||||
}
|
||||
|
||||
|
||||
debugger_console::debug_command::debug_command(std::string_view _command, u32 _flags, int _minparams, int _maxparams, std::function<void (const std::vector<std::string> &)> &&_handler)
|
||||
debugger_console::debug_command::debug_command(std::string_view _command, u32 _flags, int _minparams, int _maxparams, std::function<void (const std::vector<std::string_view> &)> &&_handler)
|
||||
: command(_command), params(nullptr), help(nullptr), handler(std::move(_handler)), flags(_flags), minparams(_minparams), maxparams(_maxparams)
|
||||
{
|
||||
}
|
||||
@ -143,7 +143,7 @@ debugger_console::debug_command::debug_command(std::string_view _command, u32 _f
|
||||
// execute_help_custom - execute the helpcustom command
|
||||
//------------------------------------------------------------
|
||||
|
||||
void debugger_console::execute_help_custom(const std::vector<std::string> ¶ms)
|
||||
void debugger_console::execute_help_custom(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
for (const debug_command &cmd : m_commandlist)
|
||||
{
|
||||
@ -160,9 +160,9 @@ void debugger_console::execute_help_custom(const std::vector<std::string> ¶m
|
||||
execute_condump - execute the condump command
|
||||
------------------------------------------------------------*/
|
||||
|
||||
void debugger_console::execute_condump(const std::vector<std::string>& params)
|
||||
void debugger_console::execute_condump(const std::vector<std::string_view>& params)
|
||||
{
|
||||
std::string filename = params[0];
|
||||
std::string filename(params[0]);
|
||||
const char* mode;
|
||||
|
||||
/* replace macros */
|
||||
@ -308,10 +308,7 @@ CMDERR debugger_console::internal_execute_command(bool execute, std::vector<std:
|
||||
|
||||
// execute the handler
|
||||
if (execute)
|
||||
{
|
||||
std::vector<std::string> params_vec(params.begin(), params.end());
|
||||
found->handler(params_vec);
|
||||
}
|
||||
found->handler(params);
|
||||
return CMDERR::none();
|
||||
}
|
||||
|
||||
@ -454,7 +451,7 @@ CMDERR debugger_console::validate_command(std::string_view command)
|
||||
register_command - register a command handler
|
||||
-------------------------------------------------*/
|
||||
|
||||
void debugger_console::register_command(std::string_view command, u32 flags, int minparams, int maxparams, std::function<void (const std::vector<std::string> &)> &&handler)
|
||||
void debugger_console::register_command(std::string_view command, u32 flags, int minparams, int maxparams, std::function<void (const std::vector<std::string_view> &)> &&handler)
|
||||
{
|
||||
if (m_machine.phase() != machine_phase::INIT)
|
||||
throw emu_fatalerror("Can only call debugger_console::register_command() at init time!");
|
||||
|
@ -83,7 +83,7 @@ public:
|
||||
// command handling
|
||||
CMDERR execute_command(std::string_view command, bool echo);
|
||||
CMDERR validate_command(std::string_view command);
|
||||
void register_command(std::string_view command, u32 flags, int minparams, int maxparams, std::function<void (const std::vector<std::string> &)> &&handler);
|
||||
void register_command(std::string_view command, u32 flags, int minparams, int maxparams, std::function<void (const std::vector<std::string_view> &)> &&handler);
|
||||
void source_script(const char *file);
|
||||
void process_source_file();
|
||||
|
||||
@ -119,8 +119,8 @@ public:
|
||||
private:
|
||||
void exit();
|
||||
|
||||
void execute_help_custom(const std::vector<std::string> ¶ms);
|
||||
void execute_condump(const std::vector<std::string>& params);
|
||||
void execute_help_custom(const std::vector<std::string_view> ¶ms);
|
||||
void execute_condump(const std::vector<std::string_view>& params);
|
||||
|
||||
[[nodiscard]] static std::string_view trim_parameter(std::string_view param, bool keep_quotes);
|
||||
CMDERR internal_execute_command(bool execute, std::vector<std::string_view> ¶ms);
|
||||
@ -131,7 +131,7 @@ private:
|
||||
|
||||
struct debug_command
|
||||
{
|
||||
debug_command(std::string_view _command, u32 _flags, int _minparams, int _maxparams, std::function<void (const std::vector<std::string> &)> &&_handler);
|
||||
debug_command(std::string_view _command, u32 _flags, int _minparams, int _maxparams, std::function<void (const std::vector<std::string_view> &)> &&_handler);
|
||||
|
||||
struct compare
|
||||
{
|
||||
@ -144,7 +144,7 @@ private:
|
||||
std::string command;
|
||||
const char * params;
|
||||
const char * help;
|
||||
std::function<void (const std::vector<std::string> &)> handler;
|
||||
std::function<void (const std::vector<std::string_view> &)> handler;
|
||||
u32 flags;
|
||||
int minparams;
|
||||
int maxparams;
|
||||
|
@ -505,10 +505,10 @@ void natural_keyboard::post_utf8(const char *text, size_t length, const attotime
|
||||
}
|
||||
|
||||
|
||||
void natural_keyboard::post_utf8(const std::string &text, const attotime &rate)
|
||||
void natural_keyboard::post_utf8(std::string_view text, const attotime &rate)
|
||||
{
|
||||
if (!text.empty())
|
||||
post_utf8(text.c_str(), text.size(), rate);
|
||||
post_utf8(text.data(), text.size(), rate);
|
||||
}
|
||||
|
||||
|
||||
@ -590,10 +590,10 @@ void natural_keyboard::post_coded(const char *text, size_t length, const attotim
|
||||
}
|
||||
|
||||
|
||||
void natural_keyboard::post_coded(const std::string &text, const attotime &rate)
|
||||
void natural_keyboard::post_coded(std::string_view text, const attotime &rate)
|
||||
{
|
||||
if (!text.empty())
|
||||
post_coded(text.c_str(), text.size(), rate);
|
||||
post_coded(text.data(), text.size(), rate);
|
||||
}
|
||||
|
||||
|
||||
|
@ -16,6 +16,7 @@
|
||||
#include <functional>
|
||||
#include <iosfwd>
|
||||
#include <string>
|
||||
#include <string_view>
|
||||
#include <unordered_map>
|
||||
#include <vector>
|
||||
|
||||
@ -63,9 +64,9 @@ public:
|
||||
void post_char(char32_t ch, bool normalize_crlf = false);
|
||||
void post(const char32_t *text, size_t length = 0, const attotime &rate = attotime::zero);
|
||||
void post_utf8(const char *text, size_t length = 0, const attotime &rate = attotime::zero);
|
||||
void post_utf8(const std::string &text, const attotime &rate = attotime::zero);
|
||||
void post_utf8(std::string_view text, const attotime &rate = attotime::zero);
|
||||
void post_coded(const char *text, size_t length = 0, const attotime &rate = attotime::zero);
|
||||
void post_coded(const std::string &text, const attotime &rate = attotime::zero);
|
||||
void post_coded(std::string_view text, const attotime &rate = attotime::zero);
|
||||
void paste();
|
||||
|
||||
// debugging
|
||||
|
@ -165,11 +165,11 @@ std::string strmakeupper(std::string_view str)
|
||||
}
|
||||
|
||||
/**
|
||||
* @fn std::string &strmakelower(std::string_view str)
|
||||
* @fn std::string strmakelower(std::string_view str)
|
||||
*
|
||||
* @brief Returns a lower case version of the given string.
|
||||
*
|
||||
* @param [in,out] str The string to make lower case
|
||||
* @param [in] str The string to make lower case
|
||||
*
|
||||
* @return A new std::string having been changed to lower case
|
||||
*/
|
||||
@ -209,6 +209,40 @@ int strreplace(std::string &str, const std::string& search, const std::string& r
|
||||
|
||||
namespace util {
|
||||
|
||||
/**
|
||||
* @fn bool streqlower(std::string_view str, std::string_view lcstr)
|
||||
*
|
||||
* @brief Tests whether a mixed-case string matches a lowercase string.
|
||||
*
|
||||
* @param [in] str First string to compare (may be mixed-case).
|
||||
* @param [in] lcstr Second string to compare (must be all lowercase).
|
||||
*
|
||||
* @return True if the strings match regardless of case.
|
||||
*/
|
||||
|
||||
bool streqlower(std::string_view str, std::string_view lcstr)
|
||||
{
|
||||
return std::equal(str.begin(), str.end(), lcstr.begin(), lcstr.end(),
|
||||
[] (unsigned char c1, unsigned char c2) { return std::tolower(c1) == c2; });
|
||||
}
|
||||
|
||||
/**
|
||||
* @fn bool strequpper(std::string_view str, std::string_view ucstr)
|
||||
*
|
||||
* @brief Tests whether a mixed-case string matches an uppercase string.
|
||||
*
|
||||
* @param [in] str First string to compare (may be mixed-case).
|
||||
* @param [in] ucstr Second string to compare (must be all uppercase).
|
||||
*
|
||||
* @return True if the strings match regardless of case.
|
||||
*/
|
||||
|
||||
bool strequpper(std::string_view str, std::string_view ucstr)
|
||||
{
|
||||
return std::equal(str.begin(), str.end(), ucstr.begin(), ucstr.end(),
|
||||
[] (unsigned char c1, unsigned char c2) { return std::toupper(c1) == c2; });
|
||||
}
|
||||
|
||||
/**
|
||||
* @fn double edit_distance(std::u32string_view lhs, std::u32string_view rhs)
|
||||
*
|
||||
|
@ -77,6 +77,9 @@ int strreplace(std::string &str, const std::string& search, const std::string& r
|
||||
|
||||
namespace util {
|
||||
|
||||
bool strequpper(std::string_view str, std::string_view ucstr);
|
||||
bool streqlower(std::string_view str, std::string_view lcstr);
|
||||
|
||||
// based on Jaro-Winkler distance - returns value from 0.0 (totally dissimilar) to 1.0 (identical)
|
||||
double edit_distance(std::u32string_view lhs, std::u32string_view rhs);
|
||||
|
||||
|
@ -371,10 +371,10 @@ private:
|
||||
m_ata_int = param;
|
||||
}
|
||||
|
||||
void debug_help_command(const std::vector<std::string> ¶ms);
|
||||
void debug_commands(const std::vector<std::string> ¶ms);
|
||||
void debug_help_command(const std::vector<std::string_view> ¶ms);
|
||||
void debug_commands(const std::vector<std::string_view> ¶ms);
|
||||
|
||||
void dump_task_command(const std::vector<std::string> ¶ms);
|
||||
void dump_task_command(const std::vector<std::string_view> ¶ms);
|
||||
};
|
||||
|
||||
|
||||
@ -1485,7 +1485,7 @@ void konamim2_state::init_hellngt()
|
||||
*
|
||||
*************************************/
|
||||
|
||||
void konamim2_state::debug_help_command(const std::vector<std::string> ¶ms)
|
||||
void konamim2_state::debug_help_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
|
||||
@ -1494,7 +1494,7 @@ void konamim2_state::debug_help_command(const std::vector<std::string> ¶ms)
|
||||
con.printf(" konm2 dump_dspp,<address> -- Dump DSPP object at <address>\n");
|
||||
}
|
||||
|
||||
void konamim2_state::debug_commands(const std::vector<std::string> ¶ms)
|
||||
void konamim2_state::debug_commands(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
if (params.size() < 1)
|
||||
return;
|
||||
@ -1507,7 +1507,7 @@ void konamim2_state::debug_commands(const std::vector<std::string> ¶ms)
|
||||
subdevice<dspp_device>("bda:dspp")->dump_state();
|
||||
}
|
||||
|
||||
void konamim2_state::dump_task_command(const std::vector<std::string> ¶ms)
|
||||
void konamim2_state::dump_task_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
typedef uint32_t Item;
|
||||
typedef uint32_t m2ptr;
|
||||
|
@ -77,7 +77,7 @@ void midtunit_video_device::debug_init()
|
||||
}
|
||||
}
|
||||
|
||||
void midtunit_video_device::debug_commands(const std::vector<std::string> ¶ms)
|
||||
void midtunit_video_device::debug_commands(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
if (params.size() < 1)
|
||||
return;
|
||||
@ -88,7 +88,7 @@ void midtunit_video_device::debug_commands(const std::vector<std::string> ¶m
|
||||
debug_help_command(params);
|
||||
}
|
||||
|
||||
void midtunit_video_device::debug_help_command(const std::vector<std::string> ¶ms)
|
||||
void midtunit_video_device::debug_help_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
|
||||
@ -97,7 +97,7 @@ void midtunit_video_device::debug_help_command(const std::vector<std::string> &p
|
||||
con.printf(" midblit help -- this list\n");
|
||||
}
|
||||
|
||||
void midtunit_video_device::debug_png_dma_command(const std::vector<std::string> ¶ms)
|
||||
void midtunit_video_device::debug_png_dma_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
|
||||
@ -141,7 +141,7 @@ void midtunit_video_device::debug_png_dma_command(const std::vector<std::string>
|
||||
return;
|
||||
}
|
||||
|
||||
strncpy(m_log_path, params[2].c_str(), 2047);
|
||||
m_log_path = params[2];
|
||||
|
||||
if (params.size() == 4)
|
||||
{
|
||||
|
@ -165,16 +165,16 @@ protected:
|
||||
int32_t m_debug_dma_command;
|
||||
#endif
|
||||
|
||||
char m_log_path[2048];
|
||||
std::string m_log_path;
|
||||
bool m_log_png;
|
||||
bool m_log_json;
|
||||
std::unique_ptr<uint64_t[]> m_logged_rom;
|
||||
bitmap_argb32 m_log_bitmap;
|
||||
|
||||
void debug_init();
|
||||
void debug_commands(const std::vector<std::string> ¶ms);
|
||||
void debug_help_command(const std::vector<std::string> ¶ms);
|
||||
void debug_png_dma_command(const std::vector<std::string> ¶ms);
|
||||
void debug_commands(const std::vector<std::string_view> ¶ms);
|
||||
void debug_help_command(const std::vector<std::string_view> ¶ms);
|
||||
void debug_png_dma_command(const std::vector<std::string_view> ¶ms);
|
||||
void log_bitmap(int command, int bpp, bool skip);
|
||||
};
|
||||
|
||||
|
@ -261,8 +261,8 @@ private:
|
||||
void decode_dssi_f_plonk_char(uint16_t ds, uint16_t si);
|
||||
void decode_dssi_f_rw_sectors(uint16_t ds, uint16_t si);
|
||||
|
||||
void debug_command(const std::vector<std::string> ¶ms);
|
||||
void video_debug(const std::vector<std::string> ¶ms);
|
||||
void debug_command(const std::vector<std::string_view> ¶ms);
|
||||
void video_debug(const std::vector<std::string_view> ¶ms);
|
||||
offs_t dasm_override(std::ostream &stream, offs_t pc, const util::disasm_interface::data_buffer &opcodes, const util::disasm_interface::data_buffer ¶ms);
|
||||
|
||||
TIMER_CALLBACK_MEMBER(do_mouse);
|
||||
|
@ -64,6 +64,7 @@ chdman createhd -o ST125N.chd -chs 41921,1,1 -ss 512
|
||||
|
||||
#include "rmnimbus.h"
|
||||
#include "debugger.h"
|
||||
#include "debug/debugcmd.h"
|
||||
#include "debug/debugcon.h"
|
||||
#include "debug/debugcpu.h"
|
||||
#include "imagedev/floppy.h"
|
||||
@ -234,12 +235,13 @@ void rmnimbus_state::machine_start()
|
||||
//m_fdc->overide_delays(64,m_fdc->get_cmd_delay());
|
||||
}
|
||||
|
||||
void rmnimbus_state::debug_command(const std::vector<std::string> ¶ms)
|
||||
void rmnimbus_state::debug_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
if (params.size() > 0)
|
||||
{
|
||||
int temp;
|
||||
sscanf(params[0].c_str(), "%d", &temp);
|
||||
uint64_t temp;
|
||||
if (!machine().debugger().commands().validate_number_parameter(params[0], temp))
|
||||
return;
|
||||
m_debug_machine = temp;
|
||||
}
|
||||
else
|
||||
|
@ -32,6 +32,7 @@
|
||||
#include "rmnimbus.h"
|
||||
|
||||
#include "debugger.h"
|
||||
#include "debug/debugcmd.h"
|
||||
#include "debug/debugcon.h"
|
||||
|
||||
#include <functional>
|
||||
@ -623,12 +624,13 @@ void rmnimbus_state::change_palette(uint8_t bank, uint16_t colours)
|
||||
}
|
||||
}
|
||||
|
||||
void rmnimbus_state::video_debug(const std::vector<std::string> ¶ms)
|
||||
void rmnimbus_state::video_debug(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
if (params.size() > 0)
|
||||
{
|
||||
int temp;
|
||||
sscanf(params[0].c_str(), "%d", &temp);
|
||||
uint64_t temp;
|
||||
if (!machine().debugger().commands().validate_number_parameter(params[0], temp))
|
||||
return;
|
||||
m_debug_video = temp;
|
||||
}
|
||||
else
|
||||
|
@ -663,9 +663,9 @@ private:
|
||||
void chihiro_map_io(address_map &map);
|
||||
|
||||
void jamtable_disasm(address_space &space, uint32_t address, uint32_t size);
|
||||
void jamtable_disasm_command(const std::vector<std::string> ¶ms);
|
||||
void chihiro_help_command(const std::vector<std::string> ¶ms);
|
||||
void debug_commands(const std::vector<std::string> ¶ms);
|
||||
void jamtable_disasm_command(const std::vector<std::string_view> ¶ms);
|
||||
void chihiro_help_command(const std::vector<std::string_view> ¶ms);
|
||||
void debug_commands(const std::vector<std::string_view> ¶ms);
|
||||
};
|
||||
|
||||
/* jamtable instructions for Chihiro (different from Xbox console)
|
||||
@ -780,7 +780,7 @@ void chihiro_state::jamtable_disasm(address_space &space, uint32_t address, uint
|
||||
}
|
||||
}
|
||||
|
||||
void chihiro_state::jamtable_disasm_command(const std::vector<std::string> ¶ms)
|
||||
void chihiro_state::jamtable_disasm_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
address_space &space = m_maincpu->space();
|
||||
uint64_t addr, size;
|
||||
@ -794,7 +794,7 @@ void chihiro_state::jamtable_disasm_command(const std::vector<std::string> ¶
|
||||
jamtable_disasm(space, (uint32_t)addr, (uint32_t)size);
|
||||
}
|
||||
|
||||
void chihiro_state::chihiro_help_command(const std::vector<std::string> ¶ms)
|
||||
void chihiro_state::chihiro_help_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
|
||||
@ -803,7 +803,7 @@ void chihiro_state::chihiro_help_command(const std::vector<std::string> ¶ms)
|
||||
con.printf(" chihiro help -- this list\n");
|
||||
}
|
||||
|
||||
void chihiro_state::debug_commands(const std::vector<std::string> ¶ms)
|
||||
void chihiro_state::debug_commands(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
if (params.size() < 1)
|
||||
return;
|
||||
|
@ -249,10 +249,10 @@ protected:
|
||||
void scsp_map(address_map &map);
|
||||
|
||||
void debug_init();
|
||||
void debug_commands(const std::vector<std::string> ¶ms);
|
||||
void debug_geo_dasm_command(const std::vector<std::string> ¶ms);
|
||||
void debug_tri_dump_command(const std::vector<std::string> ¶ms);
|
||||
void debug_help_command(const std::vector<std::string> ¶ms);
|
||||
void debug_commands(const std::vector<std::string_view> ¶ms);
|
||||
void debug_geo_dasm_command(const std::vector<std::string_view> ¶ms);
|
||||
void debug_tri_dump_command(const std::vector<std::string_view> ¶ms);
|
||||
void debug_help_command(const std::vector<std::string_view> ¶ms);
|
||||
|
||||
virtual void video_start() override;
|
||||
|
||||
|
@ -25,7 +25,7 @@ void model2_state::debug_init()
|
||||
}
|
||||
}
|
||||
|
||||
void model2_state::debug_commands(const std::vector<std::string> ¶ms)
|
||||
void model2_state::debug_commands(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
if (params.size() < 1)
|
||||
return;
|
||||
@ -38,7 +38,7 @@ void model2_state::debug_commands(const std::vector<std::string> ¶ms)
|
||||
debug_help_command(params);
|
||||
}
|
||||
|
||||
void model2_state::debug_help_command(const std::vector<std::string> ¶ms)
|
||||
void model2_state::debug_help_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
|
||||
@ -54,7 +54,7 @@ void model2_state::debug_help_command(const std::vector<std::string> ¶ms)
|
||||
*
|
||||
****************************************/
|
||||
|
||||
void model2_state::debug_geo_dasm_command(const std::vector<std::string> ¶ms)
|
||||
void model2_state::debug_geo_dasm_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
|
||||
@ -70,10 +70,11 @@ void model2_state::debug_geo_dasm_command(const std::vector<std::string> ¶ms
|
||||
return;
|
||||
}
|
||||
|
||||
std::ofstream f(params[1]);
|
||||
std::string fname(params[1]);
|
||||
std::ofstream f(fname);
|
||||
if (!f)
|
||||
{
|
||||
con.printf("Error: while opening %s for writing\n",params[1].c_str());
|
||||
con.printf("Error: while opening %s for writing\n", params[1]);
|
||||
return;
|
||||
}
|
||||
|
||||
@ -264,7 +265,7 @@ void model2_state::debug_geo_dasm_command(const std::vector<std::string> ¶ms
|
||||
*
|
||||
****************************************/
|
||||
|
||||
void model2_state::debug_tri_dump_command(const std::vector<std::string> ¶ms)
|
||||
void model2_state::debug_tri_dump_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
FILE *f;
|
||||
@ -281,9 +282,10 @@ void model2_state::debug_tri_dump_command(const std::vector<std::string> ¶ms
|
||||
return;
|
||||
}
|
||||
|
||||
if((f = fopen( params[1].c_str(), "w" )) == nullptr)
|
||||
std::string filename(params[1]);
|
||||
if((f = fopen( filename.c_str(), "w" )) == nullptr)
|
||||
{
|
||||
con.printf("Error: while opening %s for writing\n",params[1].c_str());
|
||||
con.printf("Error: while opening %s for writing\n", params[1]);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -84,7 +84,7 @@ void xbox_base_state::find_debug_params()
|
||||
}
|
||||
}
|
||||
|
||||
void xbox_base_state::dump_string_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::dump_string_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
address_space &space = m_maincpu->space();
|
||||
@ -126,7 +126,7 @@ void xbox_base_state::dump_string_command(const std::vector<std::string> ¶ms
|
||||
con.printf("\n");
|
||||
}
|
||||
|
||||
void xbox_base_state::dump_process_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::dump_process_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
address_space &space = m_maincpu->space();
|
||||
@ -156,7 +156,7 @@ void xbox_base_state::dump_process_command(const std::vector<std::string> ¶m
|
||||
con.printf("_padding %d byte\n", space.read_byte(address + 27));
|
||||
}
|
||||
|
||||
void xbox_base_state::dump_list_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::dump_list_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
address_space &space = m_maincpu->space();
|
||||
@ -209,7 +209,7 @@ void xbox_base_state::dump_list_command(const std::vector<std::string> ¶ms)
|
||||
}
|
||||
}
|
||||
|
||||
void xbox_base_state::dump_dpc_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::dump_dpc_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
address_space &space = m_maincpu->space();
|
||||
@ -238,7 +238,7 @@ void xbox_base_state::dump_dpc_command(const std::vector<std::string> ¶ms)
|
||||
con.printf("SystemArgument2 %08X dword\n", space.read_dword_unaligned(address + 24));
|
||||
}
|
||||
|
||||
void xbox_base_state::dump_timer_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::dump_timer_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
address_space &space = m_maincpu->space();
|
||||
@ -269,7 +269,7 @@ void xbox_base_state::dump_timer_command(const std::vector<std::string> ¶ms)
|
||||
con.printf("Period %d dword\n", space.read_dword_unaligned(address + 36));
|
||||
}
|
||||
|
||||
void xbox_base_state::curthread_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::curthread_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
address_space &space = m_maincpu->space();
|
||||
@ -302,7 +302,7 @@ void xbox_base_state::curthread_command(const std::vector<std::string> ¶ms)
|
||||
con.printf("Current thread function is %08X\n", space.read_dword_unaligned(address));
|
||||
}
|
||||
|
||||
void xbox_base_state::threadlist_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::threadlist_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
address_space &space = m_maincpu->space();
|
||||
debugger_console &con = machine().debugger().console();
|
||||
@ -341,7 +341,7 @@ void xbox_base_state::threadlist_command(const std::vector<std::string> ¶ms)
|
||||
}
|
||||
}
|
||||
|
||||
void xbox_base_state::generate_irq_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::generate_irq_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
uint64_t irq;
|
||||
|
||||
@ -356,7 +356,7 @@ void xbox_base_state::generate_irq_command(const std::vector<std::string> ¶m
|
||||
debug_generate_irq((int)irq, true);
|
||||
}
|
||||
|
||||
void xbox_base_state::nv2a_combiners_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::nv2a_combiners_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
bool en = nvidia_nv2a->toggle_register_combiners_usage();
|
||||
@ -366,7 +366,7 @@ void xbox_base_state::nv2a_combiners_command(const std::vector<std::string> &par
|
||||
con.printf("Register combiners disabled\n");
|
||||
}
|
||||
|
||||
void xbox_base_state::nv2a_wclipping_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::nv2a_wclipping_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
bool en = nvidia_nv2a->toggle_clipping_w_support();
|
||||
@ -376,7 +376,7 @@ void xbox_base_state::nv2a_wclipping_command(const std::vector<std::string> &par
|
||||
con.printf("W clipping disabled\n");
|
||||
}
|
||||
|
||||
void xbox_base_state::waitvblank_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::waitvblank_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
bool en = nvidia_nv2a->toggle_wait_vblank_support();
|
||||
@ -386,7 +386,7 @@ void xbox_base_state::waitvblank_command(const std::vector<std::string> ¶ms)
|
||||
con.printf("Vblank method disabled\n");
|
||||
}
|
||||
|
||||
void xbox_base_state::grab_texture_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::grab_texture_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
uint64_t type;
|
||||
|
||||
@ -396,10 +396,11 @@ void xbox_base_state::grab_texture_command(const std::vector<std::string> ¶m
|
||||
return;
|
||||
if (params[2].empty() || params[2].length() > 127)
|
||||
return;
|
||||
nvidia_nv2a->debug_grab_texture((int)type, params[2].c_str());
|
||||
std::string filename(params[2]);
|
||||
nvidia_nv2a->debug_grab_texture((int)type, filename.c_str());
|
||||
}
|
||||
|
||||
void xbox_base_state::grab_vprog_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::grab_vprog_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
uint32_t instruction[4];
|
||||
FILE *fil;
|
||||
@ -408,7 +409,8 @@ void xbox_base_state::grab_vprog_command(const std::vector<std::string> ¶ms)
|
||||
return;
|
||||
if (params[1].empty() || params[1].length() > 127)
|
||||
return;
|
||||
if ((fil = fopen(params[1].c_str(), "wb")) == nullptr)
|
||||
std::string filename(params[1]);
|
||||
if ((fil = fopen(filename.c_str(), "wb")) == nullptr)
|
||||
return;
|
||||
for (int n = 0; n < 136; n++)
|
||||
{
|
||||
@ -418,7 +420,7 @@ void xbox_base_state::grab_vprog_command(const std::vector<std::string> ¶ms)
|
||||
fclose(fil);
|
||||
}
|
||||
|
||||
void xbox_base_state::vprogdis_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::vprogdis_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
address_space &space = m_maincpu->space();
|
||||
|
||||
@ -470,7 +472,7 @@ void xbox_base_state::vprogdis_command(const std::vector<std::string> ¶ms)
|
||||
}
|
||||
}
|
||||
|
||||
void xbox_base_state::vdeclaration_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::vdeclaration_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
address_space &space = m_maincpu->space();
|
||||
|
||||
@ -551,7 +553,7 @@ void xbox_base_state::vdeclaration_command(const std::vector<std::string> ¶m
|
||||
}
|
||||
}
|
||||
|
||||
void xbox_base_state::help_command(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::help_command(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
debugger_console &con = machine().debugger().console();
|
||||
|
||||
@ -574,7 +576,7 @@ void xbox_base_state::help_command(const std::vector<std::string> ¶ms)
|
||||
con.printf(" xbox help -- this list\n");
|
||||
}
|
||||
|
||||
void xbox_base_state::xbox_debug_commands(const std::vector<std::string> ¶ms)
|
||||
void xbox_base_state::xbox_debug_commands(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
if (params.size() < 1)
|
||||
return;
|
||||
|
@ -151,23 +151,23 @@ protected:
|
||||
const debugger_constants *debugc_bios;
|
||||
|
||||
private:
|
||||
void dump_string_command(const std::vector<std::string> ¶ms);
|
||||
void dump_process_command(const std::vector<std::string> ¶ms);
|
||||
void dump_list_command(const std::vector<std::string> ¶ms);
|
||||
void dump_dpc_command(const std::vector<std::string> ¶ms);
|
||||
void dump_timer_command(const std::vector<std::string> ¶ms);
|
||||
void curthread_command(const std::vector<std::string> ¶ms);
|
||||
void threadlist_command(const std::vector<std::string> ¶ms);
|
||||
void generate_irq_command(const std::vector<std::string> ¶ms);
|
||||
void nv2a_combiners_command(const std::vector<std::string> ¶ms);
|
||||
void nv2a_wclipping_command(const std::vector<std::string> ¶ms);
|
||||
void waitvblank_command(const std::vector<std::string> ¶ms);
|
||||
void grab_texture_command(const std::vector<std::string> ¶ms);
|
||||
void grab_vprog_command(const std::vector<std::string> ¶ms);
|
||||
void vprogdis_command(const std::vector<std::string> ¶ms);
|
||||
void vdeclaration_command(const std::vector<std::string> ¶ms);
|
||||
void help_command(const std::vector<std::string> ¶ms);
|
||||
void xbox_debug_commands(const std::vector<std::string> ¶ms);
|
||||
void dump_string_command(const std::vector<std::string_view> ¶ms);
|
||||
void dump_process_command(const std::vector<std::string_view> ¶ms);
|
||||
void dump_list_command(const std::vector<std::string_view> ¶ms);
|
||||
void dump_dpc_command(const std::vector<std::string_view> ¶ms);
|
||||
void dump_timer_command(const std::vector<std::string_view> ¶ms);
|
||||
void curthread_command(const std::vector<std::string_view> ¶ms);
|
||||
void threadlist_command(const std::vector<std::string_view> ¶ms);
|
||||
void generate_irq_command(const std::vector<std::string_view> ¶ms);
|
||||
void nv2a_combiners_command(const std::vector<std::string_view> ¶ms);
|
||||
void nv2a_wclipping_command(const std::vector<std::string_view> ¶ms);
|
||||
void waitvblank_command(const std::vector<std::string_view> ¶ms);
|
||||
void grab_texture_command(const std::vector<std::string_view> ¶ms);
|
||||
void grab_vprog_command(const std::vector<std::string_view> ¶ms);
|
||||
void vprogdis_command(const std::vector<std::string_view> ¶ms);
|
||||
void vdeclaration_command(const std::vector<std::string_view> ¶ms);
|
||||
void help_command(const std::vector<std::string_view> ¶ms);
|
||||
void xbox_debug_commands(const std::vector<std::string_view> ¶ms);
|
||||
int find_bios_index();
|
||||
bool find_bios_hash(int bios, uint32_t &crc32);
|
||||
void find_debug_params();
|
||||
|
@ -632,7 +632,7 @@ protected:
|
||||
void dma_transfer_write();
|
||||
void dma_transfer_read();
|
||||
|
||||
void fcodes_command(int ref, const std::vector<std::string> ¶ms);
|
||||
void fcodes_command(int ref, const std::vector<std::string_view> ¶ms);
|
||||
};
|
||||
|
||||
class sun4_state : public sun4_base_state
|
||||
@ -690,10 +690,10 @@ void sun4_base_state::debugger_w(offs_t offset, uint32_t data, uint32_t mem_mask
|
||||
m_mmu->insn_data_w<sun4_mmu_base_device::SUPER_INSN>(offset, data, mem_mask);
|
||||
}
|
||||
|
||||
void sun4_base_state::fcodes_command(int ref, const std::vector<std::string> ¶ms)
|
||||
void sun4_base_state::fcodes_command(int ref, const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
#if SUN4_LOG_FCODES
|
||||
if (params < 1)
|
||||
if (params.length() < 1)
|
||||
return;
|
||||
|
||||
bool is_on = (params[0] == "on");
|
||||
|
@ -228,8 +228,8 @@ private:
|
||||
|
||||
void dgnbeta_map(address_map &map);
|
||||
|
||||
void execute_beta_key_dump(const std::vector<std::string> ¶ms);
|
||||
void execute_beta_dat_log(const std::vector<std::string> ¶ms);
|
||||
void execute_beta_key_dump(const std::vector<std::string_view> ¶ms);
|
||||
void execute_beta_dat_log(const std::vector<std::string_view> ¶ms);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_DGN_BETA_H
|
||||
|
@ -822,14 +822,14 @@ offs_t dgn_beta_state::dgnbeta_dasm_override(std::ostream &stream, offs_t pc, co
|
||||
return coco_state::os9_dasm_override(stream, pc, opcodes, params);
|
||||
}
|
||||
|
||||
void dgn_beta_state::execute_beta_dat_log(const std::vector<std::string> ¶ms)
|
||||
void dgn_beta_state::execute_beta_dat_log(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
m_LogDatWrites = !m_LogDatWrites;
|
||||
|
||||
machine().debugger().console().printf("DAT register write info set : %d\n", m_LogDatWrites);
|
||||
}
|
||||
|
||||
void dgn_beta_state::execute_beta_key_dump(const std::vector<std::string> ¶ms)
|
||||
void dgn_beta_state::execute_beta_key_dump(const std::vector<std::string_view> ¶ms)
|
||||
{
|
||||
for (int idx = 0; idx < NoKeyrows; idx++)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user