MCPcopy Create free account
hub / github.com/BlitterStudio/amiberry / find_ea

Function find_ea

src/debug.cpp:7000–7051  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6998}
6999
7000static void find_ea (TCHAR **inptr)
7001{
7002 uae_u32 ea, sea, dea;
7003 uaecptr addr, end, end2;
7004 int hits = 0;
7005 bool err;
7006
7007 addr = 0xffffffff;
7008 end = lastaddr(addr);
7009 ea = readhex(inptr, &err);
7010 if (err) {
7011 return;
7012 }
7013 if (more_params(inptr)) {
7014 addr = readhex(inptr, &err);
7015 if (err) {
7016 return;
7017 }
7018 addr--;
7019 end = lastaddr(addr);
7020 if (more_params(inptr)) {
7021 end = readhex(inptr, &err);
7022 if (err) {
7023 return;
7024 }
7025 }
7026 }
7027 console_out_f (_T("Searching from %08X to %08X\n"), addr + 1, end - 1);
7028 end2 = 0;
7029 nextaddr_init(addr);
7030 bool out = false;
7031 while((addr = nextaddr(addr, end, &end2, true, &out)) != 0xffffffff) {
7032 if ((addr & 1) == 0 && addr + 6 <= end2) {
7033 sea = 0xffffffff;
7034 dea = 0xffffffff;
7035 m68k_disasm_ea (addr, NULL, 1, &sea, &dea, 0xffffffff);
7036 if (ea == sea || ea == dea) {
7037 m68k_disasm (addr, NULL, 0xffffffff, 1);
7038 out = true;
7039 hits++;
7040 if (hits > 100) {
7041 console_out_f (_T("Too many hits. End addr = %08X\n"), addr - 1);
7042 break;
7043 }
7044 }
7045 if (iscancel (65536)) {
7046 console_out_f (_T("Aborted at %08X\n"), addr);
7047 break;
7048 }
7049 }
7050 }
7051}
7052
7053static void debug_do_mmu_translate(uaecptr addrl)
7054{

Callers 1

debug_lineFunction · 0.85

Calls 9

lastaddrFunction · 0.85
readhexFunction · 0.85
more_paramsFunction · 0.85
nextaddr_initFunction · 0.85
nextaddrFunction · 0.85
m68k_disasm_eaFunction · 0.85
m68k_disasmFunction · 0.85
iscancelFunction · 0.85
console_out_fFunction · 0.50

Tested by

no test coverage detected