switch(c) {
case 0xf0: case 0xf1: case 0xf2:
case '!':
+ case '~':
return 4;
case '*': case '/': case '\\': case '%':
case '|': case '&': case '^':
switch(c) {
// left to right
case '*': case '/': case '%': case '+': case '-':
- case '|': case '&': case '^':
+ case '|': case '&': case '^': case '~':
case 0xf0: case 0xf1: case 0xf2:
return true;
// right to left
return 2;
case '!':
case ':':
+ case '~':
case 0xf0: case 0xf1: case 0xf2:
return 1;
default:
return 0;
}
-#define is_operator(c) (c == '+' || c == '-' || c == '/' || c == '*' || c == '!' || c == '%' || c == '=' || \
+#define is_operator(c) (c == '+' || c == '-' || c == '/' || c == '*' || c == '!' || c == '%' || c == '=' || c == '~' || \
c == '|' || c == '&' || c == '^' || c == '@' || c == ('@' | 0x80) || c == '>' || c == '<' || c == ('>' | 0x80) || c == ('<' | 0x80) || \
c == '?' || c == ':' || c == 0xf0 || c == 0xf1 || c == 0xf2)
#define is_function(c) (c >= 'A' && c <= 'Z')
case ':':
v = v1;
break;
+ case '~':
+ v = ~(int)v1;
+ break;
#ifdef DEBUGGER
case 0xf0:
v = get_byte_debug((uaecptr)v1);
_T(" od Enable/disable Copper vpos/hpos tracing.\n")
_T(" ot Copper single step trace.\n")
_T(" ob <addr> Copper breakpoint.\n")
- _T(" H[H] <cnt> Show PC history (HH=full CPU info) <cnt> instructions.\n")
+ _T(" H[H][s] <cnt> Show PC history (HH=full CPU info, s=disable DMA info) <cnt> instructions.\n")
_T(" C <value> Search for values like energy or lifes in games.\n")
_T(" mmu <fc> Set current MMU translation function code for all debugging instructions.\n")
_T(" mmud Dump MMU tables.\n")
TCHAR c1 = c ? _totupper((*cp)[1]) : 0;
TCHAR c2 = c1 ? _totupper((*cp)[2]) : 0;
return c == '+' || c == '-' || c == '/' || c == '*' || c == '(' || c == ')' ||
- c == '|' || c == '&' || c == '^' || c == '=' || c == '>' || c == '<' ||
+ c == '|' || c == '&' || c == '^' || c == '~' || c == '=' || c == '>' || c == '<' ||
(c == 'R' && (c1 == 'L' || c1 == 'W' || c1 == 'B') && c2 == '(');
}
}
}
}
- console_out_f(_T("Searching from %08X to %08X..\n"), addr + 1, endaddr - 1);
+ console_out_f(_T("Searching from %08X to %08X\n"), addr + 1, endaddr - 1);
nextaddr_init(addr);
bool out = false;
int colcnt = 0;
ypos = ypos_ecs;
ypose = ypose_ecs;
}
-
+ int spritey = 0;
for (y = ypos; y < ypose; y++) {
int x;
addr += size * 4;
}
}
tmp[width] = 0;
- console_out_f (_T("%3d %06X %s\n"), y, addr, tmp);
+ console_out_f (_T("%3d %3d %06X %s\n"), y, spritey, addr, tmp);
+ spritey++;
}
console_out_f (_T("Sprite address %08X, Width=%d\n"), saddr, size * 16);
- console_out_f (_T("OCS: StartX=%d StartY=%d EndY=%d Height=%d\n"), xpos, ypos, ypose, ypose - ypos + 1);
- console_out_f (_T("ECS: StartX=%d (%d.%d) StartY=%d EndY=%d Height=%d %s\n"), xpos_ecs, xpos_ecs / 4, xpos_ecs & 3, ypos_ecs, ypose_ecs, ypose_ecs - ypos_ecs + 1, ecs ? _T(" (*)") : _T(""));
+ console_out_f (_T("OCS: StartX=%d StartY=%d EndY=%d Height=%d\n"), xpos, ypos, ypose - 1, ypose - ypos);
+ console_out_f (_T("ECS: StartX=%d (%d.%d) StartY=%d EndY=%d Height=%d %s\n"), xpos_ecs, xpos_ecs / 4, xpos_ecs & 3, ypos_ecs, ypose_ecs - 1, ypose_ecs - ypos_ecs + 1, ecs ? _T(" (*)") : _T(""));
console_out_f (_T("Attach: %d. AGA SSCAN/SH10 bit: %d\n"), attach, sh10);
addr += size * 4;
}
}
}
- console_out_f (_T("Searching from %08X to %08X\n"), addr + 1, end);
+ console_out_f (_T("Searching from %08X to %08X\n"), addr + 1, end - 1);
end2 = 0;
nextaddr_init(addr);
bool out = false;
out = true;
hits++;
if (hits > 100) {
- console_out_f (_T("Too many hits. End addr = %08X\n"), addr);
+ console_out_f (_T("Too many hits. End addr = %08X\n"), addr - 1);
break;
}
}
uae_u32 oldpc = m68k_getpc ();
int lastframes, lastvpos, lasthpos;
struct regstruct save_regs = regs;
+ bool dmadata = true;
badly = 0;
if (inptr[0] == 'H') {
dmadbg = 1;
inptr++;
}
-
+ if (inptr[0] == 's') {
+ dmadata = false;
+ inptr++;
+ }
if (more_params(&inptr))
count = readint(&inptr, NULL);
else
if (badly) {
m68k_dumpstate(NULL, 0xffffffff);
} else {
- if (dmadbg && lastvpos >= 0) {
+ if (dmadbg && lastvpos >= 0 && dmadata) {
dma_disasm(lastframes, lastvpos, lasthpos, history[temp].fp, history[temp].vpos, history[temp].hpos);
}
lastframes = history[temp].fp;
static bool check_breakpoint_count(struct breakpoint_node *bpn, uaecptr pc)
{
+ bpn->cnt--;
if (bpn->cnt <= 0) {
return true;
}
console_out_f(_T("Breakpoint %d hit: PC=%08x, count=%d.\n"), bpn - bpnodes, pc, bpn->cnt);
- bpn->cnt--;
return false;
}