//debug
int fetch_history[16];
int fetch_history_index;


if (debug_arg && data == 0x12000000 && loc_ctr_reg < 0x200) {
  logmsgf("nubus_io_request() acces %x, address %x, data %x, loc_ctr_reg %d, cycle %lld\n",
         access, address, data, loc_ctr_reg, cycle_count);
//  disassemble_history();
//  disassemble_range(0,500);
//  exit(0);
}


#if 1 /*BRADFIX*/
    fetch_history[fetch_history_index++] = loc_ctr_reg;
    if (fetch_history_index == 16) fetch_history_index = 0;
#endif


void
disassemble_history(void)
{
  int i, loc, last;
  uint64 inst;
  char line[256];

  for (i = 0; i < 16; i++) {
    loc = fetch_history[i];
    if((MCregister & MCR_PROM_Disable) || loc > 2048)
      inst = WCS[loc];
    else
      inst = PCS[loc];
    disassemble(loc, inst, line);
    last = fetch_history_index > 0 ? fetch_history_index-1 : 15;
    printf("%2d:%c[%4d] %21llo %s\n",
           i, 
           i == last ? '*' : ' ',
           loc, inst, line);
  }
}

