Remove remaining firstcpu usage from devices (nw)

- isa8_cga_pc1512: Probably needs a rewrite to make this sort of kludge unnecessary
- scnxx562.cpp: There must be a better way to log timing than this...
This commit is contained in:
AJR 2018-01-04 21:34:48 -05:00
parent dacae4aa1b
commit fc4092b22b
4 changed files with 12 additions and 11 deletions

View File

@ -1356,7 +1356,7 @@ void isa8_cga_pc1512_device::device_start()
m_isa->install_device(0x3d0, 0x3df, read8_delegate( FUNC(isa8_cga_pc1512_device::io_read), this ), write8_delegate( FUNC(isa8_cga_pc1512_device::io_write), this ) );
m_isa->install_bank(0xb8000, 0xbbfff, "bank1", &m_vram[0]);
address_space &space = machine().firstcpu->space( AS_PROGRAM );
address_space &space = m_isa->memspace();
space.install_write_handler( 0xb8000, 0xbbfff, write8_delegate( FUNC(isa8_cga_pc1512_device::vram_w), this ) );
space.install_write_handler( 0xbc000, 0xbffff, write8_delegate( FUNC(isa8_cga_pc1512_device::vram_w), this ) );

View File

@ -231,6 +231,9 @@ public:
void unmap_rom(offs_t start, offs_t end);
bool is_option_rom_space_available(offs_t start, int size);
// FIXME: shouldn't need to expose this
address_space &memspace() const { return m_maincpu->space(AS_PROGRAM); }
DECLARE_WRITE_LINE_MEMBER( irq2_w );
DECLARE_WRITE_LINE_MEMBER( irq3_w );
DECLARE_WRITE_LINE_MEMBER( irq4_w );

View File

@ -765,7 +765,7 @@ WRITE8_MEMBER (pit68230_device::write)
if (ow_cnt > 1)
{
logerror ("\npit68230_device::write: previous identical operation performed %02x times\n", ow_cnt);
logerror ("pit68230_device::write: offset=%02x data=%02x %lld\n", offset, data, machine ().firstcpu->total_cycles ());
logerror ("pit68230_device::write: offset=%02x data=%02x %s\n", offset, data, machine().describe_context());
}
ow_cnt = 0;
ow_data = data;
@ -1015,7 +1015,7 @@ READ8_MEMBER (pit68230_device::read){
if (or_cnt > 1)
{
logerror ("\npit68230_device::read: previous identical operation performed %02x times\n", or_cnt);
logerror (" - pit68230_device::read: offset=%02x data=%02x %lld\n", offset, data, machine ().firstcpu->total_cycles ());
logerror (" - pit68230_device::read: offset=%02x data=%02x %s\n", offset, data, machine().describe_context());
}
or_cnt = 0;
or_data = data;

View File

@ -84,7 +84,7 @@ DONE (x) (p=partly) NMOS CMOS
// MACROS / CONSTANTS
//**************************************************************************
/* Useful temporary debug printout format */
// printf("TAG %lld %s%s Data:%d\n", machine().firstcpu->total_cycles(), __PRETTY_FUNCTION__, owner()->tag(), data);
// printf("TAG %s%s Data:%d\n", __PRETTY_FUNCTION__, owner()->tag(), data);
#define LOG_GENERAL (1U << 0)
#define LOG_R (1U << 1)
@ -105,10 +105,8 @@ DONE (x) (p=partly) NMOS CMOS
#ifdef _MSC_VER
#define FUNCNAME __func__
#define LLFORMAT "%I64%"
#else
#define FUNCNAME __PRETTY_FUNCTION__
#define LLFORMAT "%lld"
#endif
#define CHANA_TAG "cha"
@ -944,7 +942,7 @@ void duscc_channel::tra_callback()
{
int db = transmit_register_get_data_bit();
LOGR(LLFORMAT " %s() \"%s \"Channel %c transmit data bit %d\n", machine().firstcpu->total_cycles(), FUNCNAME, owner()->tag(), 'A' + m_index, db);
LOGR("%s() \"%s \"Channel %c transmit data bit %d\n", FUNCNAME, owner()->tag(), 'A' + m_index, db);
// transmit data
if (m_index == duscc_device::CHANNEL_A)
@ -954,7 +952,7 @@ void duscc_channel::tra_callback()
}
else
{
LOG(LLFORMAT " %s() \"%s \"Channel %c Failed to transmit \n", machine().firstcpu->total_cycles(), FUNCNAME, owner()->tag(), 'A' + m_index);
LOG("%s() \"%s \"Channel %c Failed to transmit \n", FUNCNAME, owner()->tag(), 'A' + m_index);
logerror("%s Channel %c Failed to transmit\n", FUNCNAME, 'A' + m_index);
}
}
@ -994,7 +992,7 @@ void duscc_channel::rcv_callback()
{
if (m_rcv == 1)
{
LOG(LLFORMAT " %s() \"%s \"Channel %c received data bit %d\n", machine().firstcpu->total_cycles(), FUNCNAME, owner()->tag(), 'A' + m_index, m_rxd);
LOG("%s() \"%s \"Channel %c received data bit %d\n", FUNCNAME, owner()->tag(), 'A' + m_index, m_rxd);
receive_register_update_bit(m_rxd);
}
}
@ -1010,7 +1008,7 @@ void duscc_channel::rcv_complete()
receive_register_extract();
data = get_received_char();
LOGINT(LLFORMAT " %s() \"%s \"Channel %c Received Data %c\n", machine().firstcpu->total_cycles(), FUNCNAME, owner()->tag(), 'A' + m_index, data);
LOGINT("%s() \"%s \"Channel %c Received Data %c\n", FUNCNAME, owner()->tag(), 'A' + m_index, data);
receive_data(data);
}
@ -2505,7 +2503,7 @@ void duscc_channel::update_serial()
else
parity = PARITY_NONE;
LOG(LLFORMAT " %s() \"%s \"Channel %c setting data frame %d+%d%c%d\n", machine().firstcpu->total_cycles(), FUNCNAME, owner()->tag(), 'A' + m_index, 1,
LOG("%s() \"%s \"Channel %c setting data frame %d+%d%c%d\n", FUNCNAME, owner()->tag(), 'A' + m_index, 1,
data_bit_count, parity == PARITY_NONE ? 'N' : parity == PARITY_EVEN ? 'E' : 'O', (stop_bits + 1) / 2);
set_data_frame(1, data_bit_count, parity, stop_bits);