Created
December 29, 2022 22:43
-
-
Save gabonator/d91fadf29492a012eae600fff43a09ce to your computer and use it in GitHub Desktop.
cicoparser-jit test1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/CicoJit/cicodis/cicodis/main.cpp b/CicoJit/cicodis/cicodis/main.cpp | |
index 8b93219..910b2b4 100644 | |
--- a/CicoJit/cicodis/cicodis/main.cpp | |
+++ b/CicoJit/cicodis/cicodis/main.cpp | |
@@ -1,3 +1,12 @@ | |
+/* | |
+ /Users/gabrielvalky/Documents/git/Projects/CicoJit/games/fox/GAME.EXE | |
+ start,1020:5dce,1020:476c,1020:4dfd,1020:4e87,1020:63f1,1020:63bf,1020:4d0b,1020:4748,1020:47b7,1020:47fa,1020:4df9,1020:47b7,1020:47d3,1020:5a04,1020:4e88,1020:4d0c,1020:4dc9,1020:4d10,1020:4db1,1020:4826,1020:4f03,1020:4e2e,1020:495b,1020:48cc,1020:48d6,1020:622e,1020:4833,1020:14e5,1020:157c,1020:147a,1020:147d,1020:1585,1020:14dd,1020:158c,1020:1591 | |
+ | |
+ | |
+ xenon | |
+ start,14311,14759,137df,172c4,1758f,1655b,10853,10761,17520,170f1,16eef,141e2,1480b,1714a,108b9,10f2b,137ca,11e61,128df,12ab2,13aa7,12a6e,16d22,13a39,1308c,139ee,1091f,10897,13998,141fb,11f4d,13835,13b76,16a0a,125a8,16aad,13bdf,16696,169d0,166a6,16bca,12ad0,16e2c,171dd,12a48,1714d,169c8,13246,13a99,17569,18ca7,17f32,17f79,18e01,189ae,188a9,18c3e,17dde,16284,19f02,19f9a,19fe6,19f4e,121e9,1246d,128b8,14f96,12aa4,180ca,1866d,18114,18126,180f5,187d5,18783,14311,14759,137df,172c4,1758f,1655b,10853,10761,17520,170f1,16eef,141e2,1480b,1714a,108b9,10f2b,137ca,11e61,128df,12ab2,13aa7,12a6e,16d22,13a39,1308c,139ee,1091f,10897,13998,141fb,11f4d,13835,13b76,16a0a,125a8,16aad,13bdf,16696,169d0,166a6,16ac7,16bca,12ad0,16e2c,171dd,12a48,1714d,169c8,13246,13a99,17569,18ca7,17f32,17f79,18e01,189ae,188a9,18c3e,17dde,16284,19f02,19f9a,19fe6,19f4e,121e9,1246d,128b8,14f96,12aa4,180ca,1866d,18114,18126,180f5,187d5,18783 | |
+ | |
+ */ | |
// | |
// main.cpp | |
// cicodis | |
@@ -76,6 +85,9 @@ std::string vassign(const cs_x86& x86, const char* fmt_, va_list args) | |
if (firstWr || firstRdWr) | |
{ | |
int index = fmt[3] - '0'; | |
+ if (x86.op_count < index+1) | |
+ return "PROBLEM-11d"; | |
+ | |
assert(x86.op_count >= index+1); | |
const cs_x86_op& op = x86.operands[index]; | |
assert(op.type == X86_OP_MEM || op.type == X86_OP_REG); | |
@@ -146,7 +158,7 @@ std::string vassign(const cs_x86& x86, const char* fmt_, va_list args) | |
strcpy(replace, ""); | |
if (strcmp(tok, "reg0") == 0) | |
{ | |
- assert(x86.op_count >= 1 && x86.operands[0].type == X86_OP_REG); | |
+ assert(x86.op_count >= 1 /*&& x86.operands[0].type == X86_OP_REG*/); | |
strcpy(replace, ToCString(x86.operands[0]).c_str()); | |
} | |
if (strcmp(tok, "reg1") == 0) | |
@@ -176,27 +188,37 @@ std::string vassign(const cs_x86& x86, const char* fmt_, va_list args) | |
} | |
if (strcmp(tok, "wr0") == 0 || strcmp(tok, "rd0") == 0 || strcmp(tok, "rw0") == 0) | |
{ | |
- assert(x86.op_count >= 1); | |
- if (getset && x86.operands[0].type == X86_OP_MEM) | |
+ if (x86.op_count == 0) | |
{ | |
- char segment[32], offset[32]; | |
- GetOpAddress(x86.operands[0], segment, offset); | |
- sprintf(replace, "memoryAGet%s(%s, %s)", | |
- x86.operands[0].size == 2 ? "16" : "", segment, offset); | |
- } else | |
- strcpy(replace, ToCString(x86.operands[0]).c_str()); | |
+ strcpy(replace, "PROBLEM-11"); | |
+ } else { | |
+ assert(x86.op_count >= 1); | |
+ if (getset && x86.operands[0].type == X86_OP_MEM) | |
+ { | |
+ char segment[32], offset[32]; | |
+ GetOpAddress(x86.operands[0], segment, offset); | |
+ sprintf(replace, "memoryAGet%s(%s, %s)", | |
+ x86.operands[0].size == 2 ? "16" : "", segment, offset); | |
+ } else | |
+ strcpy(replace, ToCString(x86.operands[0]).c_str()); | |
+ } | |
} | |
if (strcmp(tok, "wr1") == 0 || strcmp(tok, "rd1") == 0 || strcmp(tok, "rw1") == 0) | |
{ | |
- assert(x86.op_count >= 2); | |
- if (getset && x86.operands[1].type == X86_OP_MEM) | |
+ if (x86.op_count == 0) | |
+ strcpy(replace, "PROBLEM-11f"); | |
+ else | |
{ | |
- char segment[32], offset[32]; | |
- GetOpAddress(x86.operands[1], segment, offset); | |
- sprintf(replace, "memoryAGet%s(%s, %s)", | |
- x86.operands[0].size == 2 ? "16" : "", segment, offset); | |
- } else | |
- strcpy(replace, ToCString(x86.operands[1]).c_str()); | |
+ assert(x86.op_count >= 2); | |
+ if (getset && x86.operands[1].type == X86_OP_MEM) | |
+ { | |
+ char segment[32], offset[32]; | |
+ GetOpAddress(x86.operands[1], segment, offset); | |
+ sprintf(replace, "memoryAGet%s(%s, %s)", | |
+ x86.operands[0].size == 2 ? "16" : "", segment, offset); | |
+ } else | |
+ strcpy(replace, ToCString(x86.operands[1]).c_str()); | |
+ } | |
} | |
if (strcmp(tok, "sig0") == 0) | |
{ | |
@@ -469,6 +491,11 @@ public: | |
case X86_INS_JAE ... X86_INS_JL: | |
case X86_INS_JNE ... X86_INS_JS: | |
//print_insn_detail(_handle, CS_MODE_16, p); | |
+ if (x86->op_count == 0) | |
+ { | |
+ sprintf(mOperands, "PROBLEM-11A"); | |
+ break; | |
+ } | |
assert(x86->op_count == 1 && | |
x86->operands[0].type == X86_OP_IMM && | |
x86->operands[0].size == 2); | |
@@ -654,7 +681,7 @@ bool ExtractMethod(Capstone& cap, address_t address, std::vector<std::shared_ptr | |
trace.pop_front(); | |
assert(pc.offset >= 0 && pc.offset < 0xffff); | |
- if (0 && trace.size() == 0) // skip indirect jumps | |
+ if (trace.size() == 0) // skip indirect jumps | |
{ | |
// start processing indirect jumps when everything is finished | |
assert(indirectJumps.size() <= 1); | |
@@ -716,7 +743,7 @@ bool ExtractMethod(Capstone& cap, address_t address, std::vector<std::shared_ptr | |
} | |
} | |
- if (instr->IsIndirectJump()) | |
+ if (0 && instr->IsIndirectJump()) | |
{ | |
address_t table{_cs, (int)instr->mDetail.operands[0].mem.disp}; | |
const uint8_t* ptr = cap.GetBufferAt(table); | |
@@ -726,7 +753,7 @@ bool ExtractMethod(Capstone& cap, address_t address, std::vector<std::shared_ptr | |
if ((pc = instr->Next()).isValid()) | |
if (instructions.find(pc) == instructions.end()) | |
{ | |
- assert(pc.offset >= 0 && pc.offset < 0xcfff); | |
+ assert(pc.offset >= 0 && pc.offset < 0xffff); | |
trace.push_back(pc); | |
/* | |
if (pc.linearOffset() < address.linearOffset()) | |
@@ -750,7 +777,7 @@ bool ExtractMethod(Capstone& cap, address_t address, std::vector<std::shared_ptr | |
if ((pc = instr->NextBranch()).isValid()) | |
if (instructions.find(pc) == instructions.end()) | |
{ | |
- assert(pc.offset >= 0 && pc.offset < 0xdfff); | |
+ assert(pc.offset >= 0 && pc.offset < 0xffff); | |
trace.push_back(pc); | |
/* | |
//assert(pc.linearOffset() >= address.linearOffset()); | |
@@ -1056,7 +1083,8 @@ std::string MakeCCondition(address_t noticeCurrentMethod, std::shared_ptr<CapIns | |
case X86_INS_JNE: | |
return assign(x86, "$rd0 & $rd1"); | |
default: | |
- assert(0); | |
+ return "stop(/*82*/)"; | |
+ //assert(0); | |
} | |
break; | |
case X86_INS_ADD: | |
@@ -1192,8 +1220,11 @@ void FindCalls(const std::vector<std::shared_ptr<CapInstr>>& code, std::list<add | |
} | |
// indirect | |
+ }/* else if (x86.op_count == 1 && x86.operands[0].type == X86_OP_REG) | |
+ { | |
+ | |
} else | |
- assert(0); | |
+ assert(0);*/ | |
} | |
if (instr->mId == X86_INS_LCALL) | |
{ | |
@@ -1423,8 +1454,8 @@ bool DumpCodeAsC(const std::vector<std::shared_ptr<CapInstr>>& code, std::vector | |
text.push_back(assign(x86, "idiv($rd0);")); | |
break; | |
case X86_INS_IMUL: | |
- assert(x86.operands[0].size == 1); | |
- text.push_back(assign(x86, "imul($reg0);")); | |
+ //assert(x86.operands[0].size == 1); | |
+ text.push_back(assign(x86, "imul($rd0);")); | |
break; | |
case X86_INS_MUL: | |
text.push_back(assign(x86, "mul($rd0);")); | |
@@ -1507,7 +1538,7 @@ bool DumpCodeAsC(const std::vector<std::shared_ptr<CapInstr>>& code, std::vector | |
assert(0); | |
break; | |
case X86_INS_MOVSW: | |
- assert(strcmp(instr->mOperands, "word ptr es:[di], word ptr [si]") == 0); | |
+ //assert(strcmp(instr->mOperands, "word ptr es:[di], word ptr [si]") == 0); | |
if (strcmp(instr->mMnemonic, "movsw") == 0) | |
{ | |
text.push_back(format("movsw<MemAuto, MemAuto, DirAuto>();")); | |
@@ -1518,7 +1549,8 @@ bool DumpCodeAsC(const std::vector<std::shared_ptr<CapInstr>>& code, std::vector | |
text.push_back(format("rep_movsw<MemAuto, MemAuto, DirAuto>();")); | |
break; | |
} | |
- assert(0); | |
+ text.push_back("PROBLEM-11h"); | |
+ //assert(0); | |
break; | |
case X86_INS_LODSB: | |
assert(strcmp(instr->mMnemonic, "lodsb") == 0); | |
@@ -1717,6 +1749,12 @@ bool DumpCodeAsC(const std::vector<std::shared_ptr<CapInstr>>& code, std::vector | |
case X86_INS_JG: | |
case X86_INS_JA: | |
case X86_INS_JL: | |
+ if (x86.op_count == 0) | |
+ { | |
+ text.push_back(format("PROBLEM-11;")); | |
+ break; | |
+ | |
+ } | |
assert(x86.op_count == 1 && | |
x86.operands[0].type == X86_OP_IMM && | |
x86.operands[0].size == 2); | |
@@ -1736,7 +1774,7 @@ bool DumpCodeAsC(const std::vector<std::shared_ptr<CapInstr>>& code, std::vector | |
{ | |
if (i->NextBranch() == instr->mAddress) | |
{ | |
- assert(!i->mLabel); | |
+ //assert(!i->mLabel); | |
allPaths.push_back(GetPrev(i)); | |
} | |
} | |
@@ -1827,7 +1865,8 @@ bool DumpCodeAsC(const std::vector<std::shared_ptr<CapInstr>>& code, std::vector | |
text.push_back("assert(0);"); | |
text.push_back("}"); | |
} else { | |
- text.push_back("stop(/*2*/);"); | |
+ text.push_back(assign(x86, "stop(/*2*/); // (%s %s) jump Indirect $rd0", | |
+ instr->mMnemonic, instr->mOperands)); | |
} | |
} | |
//else | |
@@ -1906,7 +1945,8 @@ bool DumpCodeAsC(const std::vector<std::shared_ptr<CapInstr>>& code, std::vector | |
text.push_back(assign(x86, "callIndirect($rd0);")); | |
} | |
} else | |
- assert(0); | |
+ text.push_back(assign(x86, "callIndirect($rd0);")); | |
+ //assert(0); | |
break; | |
case X86_INS_LCALL: | |
text.push_back(format("sub_%x();", address_t{(int)x86.operands[0].imm, (int)x86.operands[1].imm}.linearOffset())); | |
@@ -2037,7 +2077,11 @@ bool DumpCodeAsC(const std::vector<std::shared_ptr<CapInstr>>& code, std::vector | |
} else if (lastCompare->mInject == inject_t::carry) | |
{ | |
} else | |
- assert(0); | |
+ { | |
+ text.push_back("stop(/*PROBLEM-11g*/);"); | |
+ //assert(0); | |
+ break; | |
+ } | |
assert(lastCompare->mInject == inject_t::none || lastCompare->mInject == inject_t::carry); | |
lastCompare->mInject = inject_t::carry; | |
} | |
@@ -2056,9 +2100,24 @@ bool DumpCodeAsC(const std::vector<std::shared_ptr<CapInstr>>& code, std::vector | |
// case X86_INS_LCALL: | |
case X86_INS_DAS: | |
case X86_INS_DAA: | |
+ case X86_INS_SCASW: | |
+ | |
+ case X86_INS_FLD: | |
+ case X86_INS_FMUL: | |
+ case X86_INS_LJMP: | |
+ case X86_INS_FIDIV: | |
+ case X86_INS_BOUND: | |
+ case X86_INS_ENTER: | |
+ case X86_INS_LEAVE: | |
+ case X86_INS_FCOMP: | |
+ case X86_INS_CMPSW: | |
+ case X86_INS_FSTP: | |
+ case X86_INS_OUTSB: | |
+ case X86_INS_FCMOVE: | |
text.push_back(format("stop(); // %s %s", instr->mMnemonic, instr->mOperands)); | |
break; | |
default: | |
+// text.push_back(format("stop(); // %s %s PROBLEM-11", instr->mMnemonic, instr->mOperands)); | |
assert(0); | |
} | |
@@ -2326,6 +2385,7 @@ void start() | |
std::string token; | |
std::regex functionHex("^([0-9a-fA-f]+)$"); | |
std::regex functionSegofs("^([0-9a-fA-f]+):([0-9a-fA-f]+)$"); | |
+ std::regex functionName("^sub_([0-9a-fA-f]+)$"); | |
// tokenize by comma | |
while (getline(is, token, ',')) | |
{ | |
@@ -2348,6 +2408,14 @@ void start() | |
int addrSeg = (int)strtol(strSeg.c_str(), nullptr, 16); | |
int addrOfs = (int)strtol(strOfs.c_str(), nullptr, 16); | |
toProcess.push_back({addrSeg, addrOfs}); | |
+ } else if (std::regex_search(token, matches, functionName)) | |
+ { | |
+ std::string strAddr = matches.str(1); | |
+ int addr = (int)strtol(strAddr.c_str(), nullptr, 16); | |
+ int addrSeg = _cs; | |
+ int addrOfs = addr - addrSeg*16; | |
+ assert(addrOfs >= 0 && addrOfs < 0xffff); | |
+ toProcess.push_back({addrSeg, addrOfs}); | |
} else | |
assert(0); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void sub_13c90(); | |
void start() | |
{ | |
headerSize = 0x0600; | |
ds = 0x13c8; | |
cs = 0x13c8; | |
ss = 0x1fb5; | |
sp = 0x5000; | |
sub_13c90(); | |
} | |
Conversion of 13c8:0110 failed! | |
Conversion of 13c8:4244 failed! | |
Conversion of 1000:0d14 failed! | |
Conversion of 13c8:3da0 failed! | |
Conversion of 13c8:349e failed! | |
void sub_10000(); | |
void sub_101e2(); | |
void sub_101fd(); | |
void sub_10219(); | |
void sub_102b7(); | |
void sub_102ee(); | |
void sub_1033c(); | |
void sub_1072d(); | |
void sub_1092b(); | |
void sub_10c19(); | |
void sub_10ca3(); | |
void sub_11cb0(); | |
void sub_121bd(); | |
void sub_123ca(); | |
void sub_1242b(); | |
void sub_1272f(); | |
void sub_127f9(); | |
void sub_1289e(); | |
void sub_1292e(); | |
void sub_12a30(); | |
void sub_12b15(); | |
void sub_12b59(); | |
void sub_12d2e(); | |
void sub_12d6c(); | |
void sub_12dce(); | |
void sub_12f4a(); | |
void sub_12f7f(); | |
void sub_13030(); | |
void sub_1354a(); | |
void sub_13563(); | |
void sub_13597(); | |
void sub_135c1(); | |
void sub_135ee(); | |
void sub_13c90(); | |
void sub_13e55(); | |
void sub_13ed8(); | |
void sub_13ed9(); | |
void sub_13f05(); | |
void sub_13f18(); | |
void sub_13f40(); | |
void sub_13f64(); | |
void sub_13f88(); | |
void sub_14136(); | |
void sub_141d6(); | |
void sub_14201(); | |
void sub_14238(); | |
void sub_14286(); | |
void sub_142b4(); | |
void sub_1437a(); | |
void sub_143ae(); | |
void sub_143ca(); | |
void sub_1457c(); | |
void sub_1461d(); | |
void sub_14714(); | |
void sub_14758(); | |
void sub_147f4(); | |
void sub_148e0(); | |
void sub_14918(); | |
void sub_14964(); | |
void sub_14a5c(); | |
void sub_14add(); | |
void sub_14b26(); | |
void sub_14bae(); | |
void sub_14c0a(); | |
void sub_150f4(); | |
void sub_15142(); | |
void sub_15162(); | |
void sub_151dc(); | |
void sub_15397(); | |
void sub_153a8(); | |
void sub_154a6(); | |
void sub_15566(); | |
void sub_15606(); | |
void sub_1561a(); | |
void sub_15620(); | |
void sub_156b6(); | |
void sub_156ea(); | |
void sub_15720(); | |
void sub_1589c(); | |
void sub_158e0(); | |
void sub_15926(); | |
void sub_1595c(); | |
void sub_15974(); | |
void sub_15978(); | |
void sub_15a2a(); | |
void sub_15b86(); | |
void sub_15be8(); | |
void sub_15c6a(); | |
void sub_15e04(); | |
void sub_15e6e(); | |
void sub_15f5c(); | |
void sub_16066(); | |
void sub_16186(); | |
void sub_161b0(); | |
void sub_161f6(); | |
void sub_16206(); | |
void sub_1621e(); | |
void sub_17b10(); | |
void sub_17b1c(); | |
void sub_17c42(); | |
void sub_17e7c(); | |
void sub_17ea7(); | |
void sub_17ef8(); | |
void sub_17fe2(); | |
void sub_10000() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0; | |
sub_13f40(); | |
ax = 0x0088; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x008a; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x00af; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
if (memoryAGet16(ss, bp + 6- 2) != 0xffff) | |
goto loc_10051; | |
ax = 0x00fc; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x00fe; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x012b; | |
goto loc_10054; | |
loc_10051: | |
ax = 0x012d; | |
loc_10054: | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
if (memoryAGet16(ss, bp + 6- 2) == 0x0000) | |
goto loc_10066; | |
goto loc_1017e; | |
loc_10066: | |
ax = 0x0169; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x016b; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x0183; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x0185; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x01ca; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
push(memoryAGet16(ds, 0x352e)); | |
push(memoryAGet16(ds, 0x352c)); | |
push(memoryAGet16(ds, 0x352a)); | |
push(memoryAGet16(ds, 0x3528)); | |
ax = 0x0203; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
sp = bp; | |
ax = 0x0219; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x0245; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x0274; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x028a; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x02b8; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x02e7; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x02fd; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x032d; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x037a; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x03a9; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x03c6; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x03df; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x03f3; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x03f5; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x042a; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x0460; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
loc_1017e: | |
if (memoryAGet16(ss, bp + 6- 2) != 0x0001) | |
goto loc_101de; | |
ax = 0x0462; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x0464; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x047f; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x7a12; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
push(dx); | |
push(ax); | |
ax = 0x0481; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
sp = bp; | |
ax = 0x04b8; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x04ed; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x0523; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
loc_101de: | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_101e2() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0; | |
sub_13f40(); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
ax = 0; | |
push(ax); | |
push(cs); | |
sub_10219(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_101fd() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0; | |
sub_13f40(); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
ax = 0x0001; | |
push(ax); | |
push(cs); | |
sub_10219(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_10219() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0008; | |
sub_13f40(); | |
push(di); | |
push(si); | |
es = memoryAGet16(ds, 0x3530); | |
di = 0x009e; | |
si = 0x0528; | |
cx = 0x0016; | |
rep_movsw<MemAuto, MemAuto, DirAuto>(); | |
ax = memoryAGet16(ss, bp + 8- 2); | |
dx = memoryAGet16(ss, bp + 10- 2); | |
memoryASet16(ss, bp - 8- 2, ax); | |
memoryASet16(ss, bp - 6- 2, dx); | |
memoryASet16(ss, bp - 2- 2, 0x0000); | |
goto loc_10296; | |
loc_10248: | |
if (ax != 0xffff) | |
goto loc_10267; | |
ax = 0x4822; | |
push(ds); | |
push(ax); | |
ax = 0x0a26; | |
push(ds); | |
push(ax); | |
ax = 0x0003; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x000a; | |
loc_10262: | |
ax = 0x0001; | |
goto loc_102b1; | |
loc_10267: | |
if (memoryAGet(ds, 0x4822) != 0x2d) | |
goto loc_1027c; | |
ax = 0x4822; | |
push(ds); | |
push(ax); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_1033c(); | |
goto loc_10288; | |
loc_1027c: | |
ax = 0x4822; | |
push(ds); | |
push(ax); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_1072d(); | |
loc_10288: | |
sp += 0x0006; | |
memoryASet16(ss, bp - 4- 2, ax); | |
if (ax == 0x0002) | |
goto loc_10262; | |
memoryASet16(ss, bp - 2- 2, memoryAGet16(ss, bp - 2- 2) | ax); | |
loc_10296: | |
ax = 0x4822; | |
push(ds); | |
push(ax); | |
stop(); // lea ax, [bp - 8] | |
push(ss); | |
push(ax); | |
push(cs); | |
sub_127f9(); | |
sp += 0x0008; | |
memoryASet16(ss, bp - 4- 2, ax); | |
if (ax) | |
goto loc_10248; | |
ax = memoryAGet16(ss, bp - 2- 2); | |
loc_102b1: | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_102b7() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0; | |
sub_13f40(); | |
stop(); // les bx, ptr [bp + 6] | |
if (memoryAGet(es, bx) != 0x00) | |
goto loc_102ce; | |
loc_102ca: | |
ax = 0; | |
goto loc_102ea; | |
loc_102ce: | |
al = memoryAGet(es, bx); | |
cbw(); | |
bx = ax; | |
if (!(memoryAGet(ds, bx + 12675) & 0x04)) | |
goto loc_102ca; | |
memoryASet16(ss, bp + 6- 2, memoryAGet16(ss, bp + 6- 2) + 1); | |
bx = memoryAGet16(ss, bp + 6- 2); | |
if (memoryAGet(es, bx) != 0x00) | |
goto loc_102ce; | |
ax = 0x0001; | |
loc_102ea: | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_102ee() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0006; | |
sub_13f40(); | |
ax = 0; | |
memoryASet16(ss, bp - 2- 2, ax); | |
memoryASet16(ss, bp - 4- 2, ax); | |
goto loc_1032c; | |
loc_10303: | |
if (memoryAGet(es, bx) != 0x2e) | |
goto loc_10317; | |
ax = memoryAGet16(ss, bp - 2- 2); | |
memoryASet16(ss, bp - 2- 2, memoryAGet16(ss, bp - 2- 2) + 1); | |
if (!ax) | |
goto loc_10329; | |
loc_10313: | |
ax = 0; | |
goto loc_10338; | |
loc_10317: | |
al = memoryAGet(es, bx); | |
cbw(); | |
bx = ax; | |
if (!(memoryAGet(ds, bx + 12675) & 0x04)) | |
goto loc_10313; | |
memoryASet16(ss, bp - 4- 2, 0x0001); | |
loc_10329: | |
memoryASet16(ss, bp + 6- 2, memoryAGet16(ss, bp + 6- 2) + 1); | |
loc_1032c: | |
stop(); // les bx, ptr [bp + 6] | |
if (memoryAGet(es, bx) != 0x00) | |
goto loc_10303; | |
ax = memoryAGet16(ss, bp - 4- 2); | |
loc_10338: | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_1033c() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x001a; | |
sub_13f40(); | |
push(di); | |
push(si); | |
stop(); // les bx, ptr [bp + 8] | |
al = memoryAGet(es, bx + 1); | |
cbw(); | |
if (ax != 0x0076) | |
goto loc_10359; | |
goto loc_103eb; | |
loc_10359: | |
if (ax > 0x0076) | |
goto loc_10371; | |
al -= 0x69; | |
if (al == 0) | |
goto loc_1038d; | |
al -= 0x06; | |
if (al == 0) | |
goto loc_103c3; | |
al--; | |
if (al != 0) | |
goto loc_1036a; | |
goto loc_1069c; | |
loc_1036a: | |
al -= 0x02; | |
if (al != 0) | |
goto loc_10371; | |
goto loc_10696; | |
loc_10371: | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
ax = 0x0ad7; | |
push(ds); | |
push(ax); | |
ax = 0x0003; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x000a; | |
ax = 0x0002; | |
goto loc_10727; | |
loc_1038d: | |
push(es); | |
push(bx); | |
sub_1595c(); | |
bx = pop(); | |
bx = pop(); | |
if (ax > 0x0005) | |
goto loc_10371; | |
ax = memoryAGet16(ss, bp + 8- 2); | |
dx = memoryAGet16(ss, bp + 10- 2); | |
ax++; | |
ax++; | |
push(dx); | |
push(ax); | |
if (memoryAGet16(ss, bp + 6- 2) == 0x0000) | |
goto loc_103b0; | |
ax = 0x00c2; | |
goto loc_103b3; | |
loc_103b0: | |
ax = 0x00ba; | |
loc_103b3: | |
cx = 0x1acd; | |
push(cx); | |
push(ax); | |
sub_15926(); | |
sp += 0x0008; | |
goto loc_10725; | |
loc_103c3: | |
push(es); | |
push(bx); | |
sub_1595c(); | |
bx = pop(); | |
bx = pop(); | |
if (ax > 0x0005) | |
goto loc_10371; | |
ax = memoryAGet16(ss, bp + 8- 2); | |
dx = memoryAGet16(ss, bp + 10- 2); | |
ax++; | |
ax++; | |
push(dx); | |
push(ax); | |
if (memoryAGet16(ss, bp + 6- 2) == 0x0000) | |
goto loc_103e6; | |
ax = 0x00c6; | |
goto loc_103b3; | |
loc_103e6: | |
ax = 0x00be; | |
goto loc_103b3; | |
loc_103eb: | |
if (memoryAGet16(ss, bp + 6- 2) == 0x0000) | |
goto loc_103f4; | |
goto loc_10371; | |
loc_103f4: | |
bx++; | |
bx++; | |
memoryASet16(ss, bp - 4- 2, bx); | |
memoryASet16(ss, bp - 2- 2, es); | |
if (memoryAGet(es, bx) != 0x00) | |
goto loc_10405; | |
goto loc_10725; | |
loc_10405: | |
push(es); | |
push(bx); | |
push(cs); | |
sub_102ee(); | |
bx = pop(); | |
bx = pop(); | |
if (!ax) | |
goto loc_10414; | |
goto loc_10566; | |
loc_10414: | |
stop(); // les bx, ptr [bp - 4] | |
al = memoryAGet(es, bx); | |
cbw(); | |
if (ax != 0x0077) | |
goto loc_10423; | |
goto loc_10549; | |
loc_10423: | |
if (ax <= 0x0077) | |
goto loc_10428; | |
goto loc_10371; | |
loc_10428: | |
al -= 0x62; | |
if (al == 0) | |
goto loc_10441; | |
al -= 0x07; | |
if (al != 0) | |
goto loc_10433; | |
goto loc_104d0; | |
loc_10433: | |
al -= 0x09; | |
if (al == 0) | |
goto loc_10491; | |
al -= 0x02; | |
if (al != 0) | |
goto loc_1043e; | |
goto loc_1050f; | |
loc_1043e: | |
goto loc_10371; | |
loc_10441: | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 1); | |
push(es); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
push(cs); | |
sub_102b7(); | |
bx = pop(); | |
bx = pop(); | |
if (ax) | |
goto loc_10455; | |
goto loc_10371; | |
loc_10455: | |
push(memoryAGet16(ss, bp - 2- 2)); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
sub_15974(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 22- 2, ax); | |
if ((short)ax < (short)0x0004) | |
goto loc_1046f; | |
if ((short)ax <= (short)0x0080) | |
goto loc_10486; | |
loc_1046f: | |
push(ax); | |
ax = 0x0a3a; | |
loc_10473: | |
push(ds); | |
push(ax); | |
ax = 0x0003; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x0008; | |
loc_10480: | |
ax = 0x0001; | |
goto loc_10727; | |
loc_10486: | |
es = memoryAGet16(ds, 0x3530); | |
memoryASet16(es, 0x00a0, ax); | |
goto loc_10725; | |
loc_10491: | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 1); | |
push(es); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
push(cs); | |
sub_102b7(); | |
bx = pop(); | |
bx = pop(); | |
if (ax) | |
goto loc_104a5; | |
goto loc_10371; | |
loc_104a5: | |
push(memoryAGet16(ss, bp - 2- 2)); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
sub_15974(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 22- 2, ax); | |
if ((short)ax < (short)0x0004) | |
goto loc_104bf; | |
if ((short)ax <= (short)0x0080) | |
goto loc_104c5; | |
loc_104bf: | |
push(ax); | |
ax = 0x0a4c; | |
goto loc_10473; | |
loc_104c5: | |
es = memoryAGet16(ds, 0x3530); | |
memoryASet16(es, 0x00a2, ax); | |
goto loc_10725; | |
loc_104d0: | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 1); | |
push(es); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
push(cs); | |
sub_102b7(); | |
bx = pop(); | |
bx = pop(); | |
if (ax) | |
goto loc_104e4; | |
goto loc_10371; | |
loc_104e4: | |
push(memoryAGet16(ss, bp - 2- 2)); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
sub_15974(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 22- 2, ax); | |
if (stop(/*condition!*/)) | |
goto loc_104fd; | |
if ((short)ax <= (short)0x0080) | |
goto loc_10504; | |
loc_104fd: | |
push(ax); | |
ax = 0x0a5e; | |
goto loc_10473; | |
loc_10504: | |
es = memoryAGet16(ds, 0x3530); | |
memoryASet16(es, 0x00a4, ax); | |
goto loc_10725; | |
loc_1050f: | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 1); | |
push(es); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
push(cs); | |
sub_102b7(); | |
bx = pop(); | |
bx = pop(); | |
if (ax) | |
goto loc_10523; | |
goto loc_10371; | |
loc_10523: | |
push(memoryAGet16(ss, bp - 2- 2)); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
sub_15974(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 22- 2, ax); | |
if (stop(/*condition!*/)) | |
goto loc_1053c; | |
if ((short)ax <= (short)0x0003) | |
goto loc_10543; | |
loc_1053c: | |
push(ax); | |
ax = 0x0a70; | |
goto loc_10473; | |
loc_10543: | |
memoryASet16(ds, 0x0526, ax); | |
goto loc_10725; | |
loc_10549: | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 1); | |
bx = memoryAGet16(ss, bp - 4- 2); | |
if (memoryAGet(es, bx) == 0x00) | |
goto loc_10558; | |
goto loc_10371; | |
loc_10558: | |
es = memoryAGet16(ds, 0x3530); | |
memoryASet16(es, 0x00aa, 0x0001); | |
goto loc_10371; | |
loc_10566: | |
stop(); // lea ax, [bp - 8] | |
push(ss); | |
push(ax); | |
push(memoryAGet16(ss, bp - 2- 2)); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
sub_16066(); | |
sp += 0x0008; | |
es = dx; | |
bx = ax; | |
interrupt(0x3c); | |
stop(); // fld qword ptr [bx] | |
interrupt(0x39); | |
push(si); | |
PROBLEM-11; | |
interrupt(0x39); | |
stop(); // fmul st(5) | |
interrupt(0x3d); | |
ah = memoryAGet(ss, bp - 23- 2); | |
flags.carry = ah & 1; | |
flags.zero = (ah >> 1) & 1; | |
if (stop(/*1*/)) | |
goto loc_105d3; | |
push(memoryAGet16(ds, 0x3538)); | |
push(memoryAGet16(ds, 0x3536)); | |
push(memoryAGet16(ds, 0x3534)); | |
push(memoryAGet16(ds, 0x3532)); | |
interrupt(0x39); | |
si++; | |
push(PROBLEM-11); | |
sp -= 0x0008; | |
bx = sp; | |
interrupt(0x39); | |
ds = pop(); | |
interrupt(0x3d); | |
ax = 0x0a82; | |
push(ds); | |
push(ax); | |
ax = 0x0003; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x0016; | |
stop(); // lea di, [bp - 0x10] | |
si = 0x3532; | |
push(ss); | |
es = pop(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
loc_105d3: | |
interrupt(0x39); | |
push(es); | |
interrupt(0x38); | |
si--; | |
PROBLEM-11d | |
interrupt(0x38); | |
push(es); | |
dx++; | |
ax ^= 0xec83; | |
memoryASet(ss, bp + di + 52700- 2, memoryAGet(ss, bp + di + 52700- 2) | cl); | |
interrupt(0x3d); | |
sub_17ea7(); | |
sp += 0x0008; | |
es = dx; | |
bx = ax; | |
interrupt(0x3c); | |
stop(); // fld qword ptr [bx] | |
sub_17ec4(); | |
memoryASet16(ss, bp - 22- 2, ax); | |
memoryASet16(ss, bp - 24- 2, ax); | |
interrupt(0x3b); | |
si++; | |
sub_13ed9(); | |
push(cs); | |
dx--; | |
ax ^= 0x38cd; | |
PROBLEM-11d | |
in(al, dx); | |
memoryASet(ss, bp + di + 52700- 2, memoryAGet(ss, bp + di + 52700- 2) | cl); | |
interrupt(0x3d); | |
sub_17fe2(); | |
sp += 0x0008; | |
es = dx; | |
bx = ax; | |
interrupt(0x3c); | |
stop(); // fld qword ptr [bx] | |
interrupt(0x38); | |
push(ss); | |
push(dx); | |
ax ^= 0x39cd; | |
stop(); // fmul st(5) | |
interrupt(0x3d); | |
ah = memoryAGet(ss, bp - 25- 2); | |
flags.carry = ah & 1; | |
flags.zero = (ah >> 1) & 1; | |
if (stop(/*1*/)) | |
goto loc_10688; | |
if ((short)memoryAGet16(ss, bp - 22- 2) <= (short)0x003e) | |
goto loc_1064e; | |
memoryASet16(ss, bp - 22- 2, 0x003e); | |
goto loc_10659; | |
loc_1064e: | |
if ((short)memoryAGet16(ss, bp - 22- 2) >= (short)0x0000) | |
goto loc_10659; | |
memoryASet16(ss, bp - 22- 2, 0x0000); | |
loc_10659: | |
interrupt(0x3b); | |
si++; | |
stop(); // ljmp 0x4a0e:0x38cd | |
ax ^= 0xec83; | |
memoryASet(ss, bp + di + 52700- 2, memoryAGet(ss, bp + di + 52700- 2) | cl); | |
interrupt(0x3d); | |
push(memoryAGet16(ss, bp - 10- 2)); | |
push(memoryAGet16(ss, bp - 12- 2)); | |
push(memoryAGet16(ss, bp - 14- 2)); | |
push(memoryAGet16(ss, bp - 16- 2)); | |
ax = 0x0aaf; | |
push(ds); | |
push(ax); | |
ax = 0x0001; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x0016; | |
loc_10688: | |
ax = memoryAGet16(ss, bp - 22- 2); | |
es = memoryAGet16(ds, 0x3530); | |
memoryASet16(es, 0x009e, ax); | |
goto loc_10725; | |
loc_10696: | |
if (memoryAGet16(ss, bp + 6- 2) != 0x0000) | |
goto loc_106b4; | |
loc_1069c: | |
ax = bx; | |
dx = es; | |
ax++; | |
ax++; | |
memoryASet16(ss, bp - 4- 2, ax); | |
memoryASet16(ss, bp - 2- 2, dx); | |
push(dx); | |
push(ax); | |
push(cs); | |
sub_102b7(); | |
bx = pop(); | |
bx = pop(); | |
if (ax) | |
goto loc_106b7; | |
loc_106b4: | |
goto loc_10371; | |
loc_106b7: | |
push(memoryAGet16(ss, bp - 2- 2)); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
sub_15978(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 20- 2, ax); | |
memoryASet16(ss, bp - 18- 2, dx); | |
if (stop(/*condition!*/)) | |
goto loc_106e0; | |
if (stop(/*condition!*/)) | |
goto loc_106d5; | |
if (ax > 0xdac0) | |
goto loc_106e0; | |
loc_106d5: | |
if (stop(/*condition!*/)) | |
goto loc_106f9; | |
if (stop(/*condition!*/)) | |
goto loc_106e0; | |
if (ax >= 0x07d0) | |
goto loc_106f9; | |
loc_106e0: | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
ax = 0x0ac8; | |
push(ds); | |
push(ax); | |
ax = 0x0003; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x000a; | |
goto loc_10480; | |
loc_106f9: | |
stop(); // les bx, ptr [bp + 8] | |
if (memoryAGet(es, bx + 1) != 0x72) | |
goto loc_1070d; | |
es = memoryAGet16(ds, 0x3530); | |
memoryASet16(es, 0x00b6, ax); | |
goto loc_10725; | |
loc_1070d: | |
if (memoryAGet16(ss, bp + 6- 2) == 0x0000) | |
goto loc_1071d; | |
es = memoryAGet16(ds, 0x3530); | |
memoryASet16(es, 0x00b8, ax); | |
goto loc_10725; | |
loc_1071d: | |
es = memoryAGet16(ds, 0x3530); | |
memoryASet16(es, 0x00b4, ax); | |
loc_10725: | |
ax = 0; | |
loc_10727: | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_1072d() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0012; | |
sub_13f40(); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
ax = 0x48a4; | |
push(ds); | |
push(ax); | |
sub_15926(); | |
sp += 0x0008; | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
ax = 0x492a; | |
push(ds); | |
push(ax); | |
sub_15926(); | |
sp += 0x0008; | |
ax = 0x0ae8; | |
push(ds); | |
push(ax); | |
ax = 0x48a4; | |
push(ds); | |
push(ax); | |
sub_158e0(); | |
sp += 0x0008; | |
ax = 0x0aea; | |
push(ds); | |
push(ax); | |
ax = 0x492a; | |
push(ds); | |
push(ax); | |
sub_158e0(); | |
sp += 0x0008; | |
if (memoryAGet16(ss, bp + 6- 2) == 0x0000) | |
goto loc_1078d; | |
ax = 0x00c2; | |
goto loc_10790; | |
loc_1078d: | |
ax = 0x00ba; | |
loc_10790: | |
cx = 0x1acd; | |
push(cx); | |
push(ax); | |
ax = 0x48a4; | |
push(ds); | |
push(ax); | |
sub_158e0(); | |
sp += 0x0008; | |
if (memoryAGet16(ss, bp + 6- 2) == 0x0000) | |
goto loc_107ad; | |
ax = 0x00c6; | |
goto loc_107b0; | |
loc_107ad: | |
ax = 0x00be; | |
loc_107b0: | |
cx = 0x1acd; | |
push(cx); | |
push(ax); | |
ax = 0x492a; | |
push(ds); | |
push(ax); | |
sub_158e0(); | |
sp += 0x0008; | |
ax = 0x48a4; | |
push(ds); | |
push(ax); | |
sub_15e6e(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x492a; | |
push(ds); | |
push(ax); | |
sub_15e6e(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x0aec; | |
push(ds); | |
push(ax); | |
ax = 0x48a4; | |
push(ds); | |
push(ax); | |
sub_143ae(); | |
sp += 0x0008; | |
memoryASet16(ss, bp - 10- 2, ax); | |
memoryASet16(ss, bp - 8- 2, dx); | |
dx |= ax; | |
if (dx) | |
goto loc_10811; | |
ax = 0x48a4; | |
push(ds); | |
push(ax); | |
ax = 0x0aef; | |
push(ds); | |
push(ax); | |
ax = 0x0002; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x000a; | |
loc_1080b: | |
ax = 0x0001; | |
goto loc_10927; | |
loc_10811: | |
ax = 0x0b0d; | |
push(ds); | |
push(ax); | |
ax = 0x492a; | |
push(ds); | |
push(ax); | |
sub_143ae(); | |
sp += 0x0008; | |
memoryASet16(ss, bp - 14- 2, ax); | |
memoryASet16(ss, bp - 12- 2, dx); | |
dx |= ax; | |
if (dx) | |
goto loc_10851; | |
ax = 0x492a; | |
push(ds); | |
push(ax); | |
ax = 0x0b10; | |
push(ds); | |
push(ax); | |
ax = 0x0002; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x000a; | |
push(memoryAGet16(ss, bp - 8- 2)); | |
push(memoryAGet16(ss, bp - 10- 2)); | |
sub_142b4(); | |
loc_1084d: | |
bx = pop(); | |
bx = pop(); | |
goto loc_1080b; | |
loc_10851: | |
ax = 0x3c1e; | |
push(ds); | |
push(ax); | |
sub_16186(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 6- 2, ax); | |
if (!ax) | |
goto loc_108a9; | |
push(memoryAGet16(ss, bp - 8- 2)); | |
push(memoryAGet16(ss, bp - 10- 2)); | |
sub_142b4(); | |
bx = pop(); | |
bx = pop(); | |
push(memoryAGet16(ss, bp - 12- 2)); | |
push(memoryAGet16(ss, bp - 14- 2)); | |
sub_142b4(); | |
bx = pop(); | |
bx = pop(); | |
bx = memoryAGet16(ss, bp - 6- 2); | |
bx <<= 1; | |
bx <<= 1; | |
push(memoryAGet16(ds, bx + 2584)); | |
push(memoryAGet16(ds, bx + 2582)); | |
ax = 0x0b2e; | |
push(ds); | |
push(ax); | |
ax = 0x0002; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x000a; | |
ax = 0x492a; | |
push(ds); | |
push(ax); | |
sub_161f6(); | |
goto loc_1084d; | |
loc_108a9: | |
ax = 0x492a; | |
push(ds); | |
push(ax); | |
ax = 0x48a4; | |
push(ds); | |
push(ax); | |
if (memoryAGet16(ss, bp + 6- 2) == 0x0000) | |
goto loc_108be; | |
ax = 0x0b32; | |
goto loc_108c1; | |
loc_108be: | |
ax = 0x0b36; | |
loc_108c1: | |
push(ds); | |
push(ax); | |
ax = 0x0b38; | |
push(ds); | |
push(ax); | |
ax = 0; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x0012; | |
if (memoryAGet16(ss, bp + 6- 2) == 0x0000) | |
goto loc_108fa; | |
es = memoryAGet16(ds, 0x3530); | |
ax = memoryAGet16(es, 0x00b8); | |
memoryASet16(ds, 0x481e, ax); | |
ax = 0x009e; | |
push(es); | |
push(ax); | |
push(memoryAGet16(ss, bp - 12- 2)); | |
push(memoryAGet16(ss, bp - 14- 2)); | |
push(memoryAGet16(ss, bp - 8- 2)); | |
push(memoryAGet16(ss, bp - 10- 2)); | |
push(cs); | |
sub_11cb0(); | |
goto loc_10925; | |
loc_108fa: | |
push(cs); | |
sub_1092b(); | |
es = memoryAGet16(ds, 0x3530); | |
ax = memoryAGet16(es, 0x00b6); | |
memoryASet16(ds, 0x4820, ax); | |
ax = memoryAGet16(es, 0x00b4); | |
memoryASet16(ds, 0x481e, ax); | |
ax = 0x009e; | |
push(es); | |
push(ax); | |
push(memoryAGet16(ss, bp - 12- 2)); | |
push(memoryAGet16(ss, bp - 14- 2)); | |
push(memoryAGet16(ss, bp - 8- 2)); | |
push(memoryAGet16(ss, bp - 10- 2)); | |
push(cs); | |
sub_10d14(); | |
loc_10925: | |
ax = 0; | |
loc_10927: | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_1092b() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0016; | |
sub_13f40(); | |
push(di); | |
push(si); | |
memoryASet16(ss, bp - 4- 2, 0x009e); | |
memoryASet16(ss, bp - 2- 2, 0x1acd); | |
es = memoryAGet16(ds, 0x3530); | |
ax = memoryAGet16(es, 0x00a2); | |
memoryASet16(ss, bp - 8- 2, ax); | |
ax = memoryAGet16(es, 0x00a0); | |
ax += 0x0010; | |
al &= 0xf0; | |
ax--; | |
memoryASet16(ss, bp - 12- 2, ax); | |
if ((short)ax < (short)0x007f) | |
goto loc_10964; | |
memoryASet16(ss, bp - 12- 2, 0x0080); | |
loc_10964: | |
memoryASet16(ss, bp - 10- 2, 0x0000); | |
goto loc_1096e; | |
loc_1096b: | |
memoryASet16(ss, bp - 10- 2, memoryAGet16(ss, bp - 10- 2) + 1); | |
loc_1096e: | |
ax = memoryAGet16(ss, bp - 12- 2); | |
bx = memoryAGet16(ss, bp - 10- 2); | |
bx <<= 1; | |
if ((short)memoryAGet16(ds, bx + 1546) < (short)ax) | |
goto loc_1096b; | |
if ((short)memoryAGet16(ss, bp - 10- 2) >= (short)0x0002) | |
goto loc_10987; | |
memoryASet16(ss, bp - 10- 2, 0x0002); | |
loc_10987: | |
bx = memoryAGet16(ss, bp - 10- 2); | |
bx <<= 1; | |
ax = memoryAGet16(ds, bx + 1546); | |
memoryASet16(ss, bp - 12- 2, ax); | |
if ((short)memoryAGet16(ss, bp - 10- 2) >= (short)0x0010) | |
goto loc_109a6; | |
ax = memoryAGet16(ss, bp - 10- 2); | |
ax++; | |
stop(); // les bx, ptr [bp - 4] | |
memoryASet16(es, bx + 14, ax); | |
goto loc_109af; | |
loc_109a6: | |
stop(); // les bx, ptr [bp - 4] | |
memoryASet16(es, bx + 14, 0x0010); | |
loc_109af: | |
ax = memoryAGet16(ss, bp - 12- 2); | |
stop(); // les bx, ptr [bp - 4] | |
if (memoryAGet16(es, bx + 2) == ax) | |
goto loc_109d9; | |
push(ax); | |
push(memoryAGet16(es, bx + 2)); | |
cx = 0x0b52; | |
push(ds); | |
push(cx); | |
cx = 0; | |
push(cx); | |
push(cs); | |
sub_1289e(); | |
sp += 0x000a; | |
ax = memoryAGet16(ss, bp - 12- 2); | |
stop(); // les bx, ptr [bp - 4] | |
memoryASet16(es, bx + 2, ax); | |
loc_109d9: | |
ax = memoryAGet16(ss, bp - 8- 2); | |
ax += 0x0010; | |
al &= 0xf0; | |
ax--; | |
memoryASet16(ss, bp - 8- 2, ax); | |
if ((short)ax < (short)0x007f) | |
goto loc_109ef; | |
memoryASet16(ss, bp - 8- 2, 0x0080); | |
loc_109ef: | |
memoryASet16(ss, bp - 10- 2, 0x0000); | |
goto loc_109f9; | |
loc_109f6: | |
memoryASet16(ss, bp - 10- 2, memoryAGet16(ss, bp - 10- 2) + 1); | |
loc_109f9: | |
ax = memoryAGet16(ss, bp - 8- 2); | |
bx = memoryAGet16(ss, bp - 10- 2); | |
bx <<= 1; | |
if ((short)memoryAGet16(ds, bx + 1546) < (short)ax) | |
goto loc_109f6; | |
bx = memoryAGet16(ss, bp - 10- 2); | |
bx <<= 1; | |
ax = memoryAGet16(ds, bx + 1546); | |
memoryASet16(ss, bp - 8- 2, ax); | |
ax = memoryAGet16(ss, bp - 10- 2); | |
ax++; | |
stop(); // les bx, ptr [bp - 4] | |
memoryASet16(es, bx + 16, ax); | |
ax = memoryAGet16(ss, bp - 8- 2); | |
if (memoryAGet16(es, bx + 4) == ax) | |
goto loc_10a45; | |
push(ax); | |
push(memoryAGet16(es, bx + 4)); | |
cx = 0x0b6c; | |
push(ds); | |
push(cx); | |
cx = 0; | |
push(cx); | |
push(cs); | |
sub_1289e(); | |
sp += 0x000a; | |
ax = memoryAGet16(ss, bp - 8- 2); | |
stop(); // les bx, ptr [bp - 4] | |
memoryASet16(es, bx + 4, ax); | |
loc_10a45: | |
stop(); // les bx, ptr [bp - 4] | |
ax = memoryAGet16(es, bx + 6); | |
memoryASet16(ss, bp - 6- 2, ax); | |
if (stop(/*condition!*/)) | |
goto loc_10acf; | |
ax++; | |
al &= 0xf8; | |
ax--; | |
memoryASet16(ss, bp - 6- 2, ax); | |
memoryASet16(ss, bp - 10- 2, 0x0000); | |
goto loc_10a64; | |
loc_10a61: | |
memoryASet16(ss, bp - 10- 2, memoryAGet16(ss, bp - 10- 2) + 1); | |
loc_10a64: | |
bx = memoryAGet16(ss, bp - 10- 2); | |
bx <<= 1; | |
if ((short)memoryAGet16(ds, bx + 1546) < (short)ax) | |
goto loc_10a61; | |
if (stop(/*condition!*/)) | |
goto loc_10a8d; | |
ax = 0x0b86; | |
push(ds); | |
push(ax); | |
ax = 0; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x0006; | |
stop(); // les bx, ptr [bp - 4] | |
memoryASet16(es, bx + 6, 0xffff); | |
goto loc_10ac2; | |
loc_10a8d: | |
ax = memoryAGet16(ss, bp - 12- 2); | |
if ((short)memoryAGet16(ss, bp - 6- 2) <= (short)ax) | |
goto loc_10a98; | |
memoryASet16(ss, bp - 6- 2, ax); | |
loc_10a98: | |
ax = memoryAGet16(ss, bp - 6- 2); | |
stop(); // les bx, ptr [bp - 4] | |
if (memoryAGet16(es, bx + 6) == ax) | |
goto loc_10ac2; | |
push(ax); | |
push(memoryAGet16(es, bx + 6)); | |
cx = 0x0baf; | |
push(ds); | |
push(cx); | |
cx = 0; | |
push(cx); | |
push(cs); | |
sub_1289e(); | |
sp += 0x000a; | |
ax = memoryAGet16(ss, bp - 6- 2); | |
stop(); // les bx, ptr [bp - 4] | |
memoryASet16(es, bx + 6, ax); | |
loc_10ac2: | |
ax = memoryAGet16(ss, bp - 10- 2); | |
ax++; | |
stop(); // les bx, ptr [bp - 4] | |
memoryASet16(es, bx + 20, ax); | |
goto loc_10ad5; | |
loc_10acf: | |
memoryASet16(es, bx + 20, 0x0000); | |
loc_10ad5: | |
stop(); // les bx, ptr [bp - 4] | |
if (memoryAGet16(es, bx + 10) != 0x0000) | |
goto loc_10ae2; | |
goto loc_10b71; | |
loc_10ae2: | |
memoryASet16(ss, bp - 10- 2, 0x0000); | |
goto loc_10b62; | |
loc_10ae9: | |
memoryASet16(ss, bp - 22- 2, ax); | |
interrupt(0x3b); | |
si++; | |
stop(); // ljmp 0x4206:0x38cd | |
ax ^= 0x3ccd; | |
stop(); // fidiv word ptr [bx + 0xa] | |
interrupt(0x38); | |
push(cs); | |
dx = pop(); | |
ax ^= 0xec83; | |
memoryASet(ss, bp + di + 52700- 2, memoryAGet(ss, bp + di + 52700- 2) | cl); | |
interrupt(0x3d); | |
sub_17a20(); | |
sp += 0x0008; | |
push(ds); | |
stop(); // lea di, [bp - 0x14] | |
si = ax; | |
push(ss); | |
es = pop(); | |
ds = dx; | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
ds = pop(); | |
interrupt(0x39); | |
push(es); | |
stop(); // bound si, dword ptr [di] | |
interrupt(0x38); | |
si--; | |
in(al, dx); | |
interrupt(0x38); | |
si--; | |
in(al, dx); | |
interrupt(0x38); | |
push(es); | |
dx++; | |
ax ^= 0xec83; | |
memoryASet(ss, bp + di + 52700- 2, memoryAGet(ss, bp + di + 52700- 2) | cl); | |
interrupt(0x3d); | |
sub_17ea7(); | |
sp += 0x0008; | |
es = dx; | |
bx = ax; | |
interrupt(0x3c); | |
stop(); // fld qword ptr [bx] | |
sub_17ec4(); | |
es = memoryAGet16(ds, 0x356a); | |
bx = memoryAGet16(ss, bp - 10- 2); | |
bx <<= 1; | |
memoryASet16(es, bx + 20, ax); | |
memoryASet16(ss, bp - 10- 2, memoryAGet16(ss, bp - 10- 2) + 1); | |
loc_10b62: | |
ax = memoryAGet16(ss, bp - 10- 2); | |
stop(); // les bx, ptr [bp - 4] | |
if ((short)memoryAGet16(es, bx + 10) <= (short)ax) | |
goto loc_10b71; | |
goto loc_10ae9; | |
loc_10b71: | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_10c19() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0004; | |
sub_13f40(); | |
push(si); | |
stop(); // les bx, ptr [bp + 6] | |
memoryASet16(es, bx + 4, memoryAGet16(es, bx + 4) - 1); | |
if ((short)memoryAGet16(es, bx + 4) < 0) | |
goto loc_10c42; | |
stop(); // les bx, ptr [bp + 6] | |
si = memoryAGet16(es, bx); | |
memoryASet16(es, bx, memoryAGet16(es, bx) + 1); | |
es = memoryAGet16(es, bx + 2); | |
al = memoryAGet(es, si); | |
ah = 0; | |
goto loc_10c4f; | |
loc_10c42: | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
sub_14758(); | |
bx = pop(); | |
bx = pop(); | |
loc_10c4f: | |
memoryASet16(ss, bp - 2- 2, ax); | |
ax++; | |
if (ax == 0) | |
goto loc_10c85; | |
stop(); // les bx, ptr [bp + 6] | |
memoryASet16(es, bx + 4, memoryAGet16(es, bx + 4) - 1); | |
if ((short)memoryAGet16(es, bx + 4) < 0) | |
goto loc_10c72; | |
stop(); // les bx, ptr [bp + 6] | |
si = memoryAGet16(es, bx); | |
memoryASet16(es, bx, memoryAGet16(es, bx) + 1); | |
es = memoryAGet16(es, bx + 2); | |
al = memoryAGet(es, si); | |
ah = 0; | |
goto loc_10c7f; | |
loc_10c72: | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
sub_14758(); | |
bx = pop(); | |
bx = pop(); | |
loc_10c7f: | |
memoryASet16(ss, bp - 4- 2, ax); | |
ax++; | |
if (ax != 0) | |
goto loc_10c96; | |
loc_10c85: | |
ax = 0x0003; | |
push(ax); | |
ax = 0x3c1e; | |
push(ds); | |
push(ax); | |
sub_161b0(); | |
sp += 0x0006; | |
loc_10c96: | |
ah = memoryAGet(ss, bp - 4- 2); | |
al = 0; | |
ax += memoryAGet16(ss, bp - 2- 2); | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_10ca3() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0; | |
sub_13f40(); | |
ax = 0x0001; | |
push(ax); | |
ax = 0xfffe; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
push(dx); | |
push(ax); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
sub_15be8(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_11cb0() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x002c; | |
sub_13f40(); | |
push(si); | |
memoryASet16(ss, bp - 6- 2, 0x0000); | |
memoryASet16(ss, bp - 16- 2, 0x0000); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 38- 2, ax); | |
ax &= 0x003f; | |
memoryASet16(ss, bp - 4- 2, ax); | |
al = memoryAGet(ss, bp - 37- 2); | |
al &= 0x0f; | |
if (al == 0x0b) | |
goto loc_11d04; | |
ax = 0x0d96; | |
push(ds); | |
push(ax); | |
ax = 0; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x0006; | |
ax = 0x0001; | |
push(ax); | |
ax = 0x3c1e; | |
push(ds); | |
push(ax); | |
sub_161b0(); | |
sp += 0x0006; | |
loc_11d04: | |
if (memoryAGet(ss, bp - 37- 2) == 0xeb) | |
goto loc_11d1b; | |
ax = 0x0001; | |
push(ax); | |
ax = 0x3c1e; | |
push(ds); | |
push(ax); | |
sub_161b0(); | |
sp += 0x0006; | |
loc_11d1b: | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ds, 0x4820, ax); | |
interrupt(0x3b); | |
si++; | |
flags.direction = false; | |
interrupt(0x38); | |
push(cs); | |
dx--; | |
ax ^= 0xec83; | |
memoryASet(ss, bp + di + 52700- 2, memoryAGet(ss, bp + di + 52700- 2) | cl); | |
interrupt(0x3d); | |
ax = 0x0daf; | |
push(ds); | |
push(ax); | |
ax = 0; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x000e; | |
push(memoryAGet16(ds, 0x481e)); | |
push(memoryAGet16(ds, 0x4820)); | |
ax = 0x0dc4; | |
push(ds); | |
push(ax); | |
ax = 0; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x000a; | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 14- 2, ax); | |
memoryASet16(ss, bp - 12- 2, 0x0000); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
cx = 0; | |
flags.carry = (memoryAGet16(ss, bp - 14- 2) + cx) >= 0x10000; | |
memoryASet16(ss, bp - 14- 2, memoryAGet16(ss, bp - 14- 2) + cx); | |
memoryASet16(ss, bp - 12- 2, memoryAGet16(ss, bp - 12- 2) + (ax + flags.carry)); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 18- 2, 0x0000); | |
loc_11dc0: | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 44- 2, ax); | |
si = memoryAGet16(ss, bp - 18- 2); | |
si <<= 1; | |
memoryASet(ss, bp + si + 65500- 2, al); | |
es = memoryAGet16(ds, 0x356e); | |
memoryASet(es, si, al); | |
al = memoryAGet(ss, bp - 43- 2); | |
memoryASet(ss, bp + si + 65501- 2, al); | |
memoryASet(es, si + 1, al); | |
memoryASet16(ss, bp - 18- 2, memoryAGet16(ss, bp - 18- 2) + 1); | |
if ((short)memoryAGet16(ss, bp - 18- 2) < (short)0x0008) | |
goto loc_11dc0; | |
memoryASet16(ss, bp - 18- 2, 0x0000); | |
es = memoryAGet16(ds, 0x3570); | |
loc_11dfd: | |
bx = memoryAGet16(ss, bp - 18- 2); | |
bx <<= 1; | |
memoryASet16(es, bx + 148, 0x0000); | |
memoryASet16(ss, bp - 18- 2, memoryAGet16(ss, bp - 18- 2) + 1); | |
if ((short)memoryAGet16(ss, bp - 18- 2) < (short)0x0003) | |
goto loc_11dfd; | |
stop(); // les bx, ptr [bp + 0xe] | |
memoryASet16(es, bx + 14, 0x0010); | |
memoryASet16(es, bx + 18, 0x0000); | |
if (memoryAGet(ss, bp - 36- 2) & 0x80) | |
goto loc_11e5b; | |
ax = 0x0df2; | |
push(ds); | |
push(ax); | |
ax = 0x0002; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x0006; | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
sub_142b4(); | |
bx = pop(); | |
bx = pop(); | |
push(memoryAGet16(ss, bp + 12- 2)); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
sub_142b4(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0xffff; | |
push(ax); | |
sub_13e55(); | |
bx = pop(); | |
loc_11e5b: | |
memoryASet16(ss, bp - 18- 2, 0x0000); | |
goto loc_11e72; | |
loc_11e62: | |
if (!(memoryAGet(ss, bp + si + 65500- 2) & 0x40)) | |
goto loc_11e6f; | |
stop(); // les bx, ptr [bp + 0xe] | |
memoryASet16(es, bx + 18, memoryAGet16(es, bx + 18) + 1); | |
loc_11e6f: | |
memoryASet16(ss, bp - 18- 2, memoryAGet16(ss, bp - 18- 2) + 1); | |
loc_11e72: | |
if ((short)memoryAGet16(ss, bp - 18- 2) >= (short)0x0010) | |
goto loc_11e91; | |
si = memoryAGet16(ss, bp - 18- 2); | |
if (memoryAGet(ss, bp + si + 65500- 2) != 0xff) | |
goto loc_11e62; | |
stop(); // les bx, ptr [bp + 0xe] | |
if (memoryAGet16(es, bx + 14) != 0x0010) | |
goto loc_11e6f; | |
memoryASet16(es, bx + 14, si); | |
goto loc_11e6f; | |
loc_11e91: | |
cl = 0x06; | |
bl = memoryAGet(ss, bp - 35- 2); | |
bl &= 0xbf; | |
al = memoryAGet(ss, bp - 34- 2); | |
al >>= 1; | |
bl |= al; | |
bl >>= cl; | |
bh = 0; | |
memoryASet16(ds, 0x0526, bx); | |
bx <<= 1; | |
bx <<= 1; | |
ax = memoryAGet16(ds, bx + 1498); | |
dx = memoryAGet16(ds, bx + 1500); | |
es = memoryAGet16(ds, 0x356c); | |
memoryASet16(es, 0x0010, ax); | |
memoryASet16(es, 0x0012, dx); | |
push(memoryAGet16(ds, 0x0526)); | |
ax = 0x0e21; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
sp += 0x0006; | |
memoryASet16(ss, bp - 18- 2, 0x0000); | |
loc_11ed7: | |
bx = memoryAGet16(ss, bp - 18- 2); | |
bx <<= 1; | |
bx <<= 1; | |
ax = 0; | |
memoryASet16(ds, bx + 15328, ax); | |
memoryASet16(ds, bx + 15326, ax); | |
memoryASet16(ss, bp - 18- 2, memoryAGet16(ss, bp - 18- 2) + 1); | |
if ((short)memoryAGet16(ss, bp - 18- 2) < (short)0x0010) | |
goto loc_11ed7; | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 10- 2, ax); | |
if (!(ah & 0xf0)) | |
goto loc_11f16; | |
ax = 0x0001; | |
push(ax); | |
ax = 0x3c1e; | |
push(ds); | |
push(ax); | |
sub_161b0(); | |
sp += 0x0006; | |
loc_11f16: | |
ax = 0; | |
memoryASet16(ss, bp - 40- 2, ax); | |
memoryASet16(ss, bp - 42- 2, ax); | |
memoryASet16(ss, bp - 18- 2, ax); | |
es = memoryAGet16(ds, 0x357a); | |
loc_11f25: | |
bx = memoryAGet16(ss, bp - 18- 2); | |
bx <<= 1; | |
memoryASet16(es, bx + 84, 0x0000); | |
memoryASet16(ss, bp - 18- 2, memoryAGet16(ss, bp - 18- 2) + 1); | |
if ((short)memoryAGet16(ss, bp - 18- 2) < (short)0x0010) | |
goto loc_11f25; | |
loc_11f3a: | |
ax = memoryAGet16(ss, bp - 10- 2); | |
ah &= 0x0f; | |
if (ax != 0x0fff) | |
goto loc_11f4c; | |
memoryASet16(ss, bp - 20- 2, 0x0000); | |
goto loc_11f7d; | |
loc_11f4c: | |
ax = memoryAGet16(ss, bp - 10- 2); | |
ah &= 0x0f; | |
if ((short)ax <= (short)0x0107) | |
goto loc_11f74; | |
ax = 0x0e34; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x0001; | |
push(ax); | |
ax = 0x3c1e; | |
push(ds); | |
push(ax); | |
sub_161b0(); | |
sp += 0x0006; | |
loc_11f74: | |
ax = memoryAGet16(ss, bp - 10- 2); | |
ah &= 0x0f; | |
memoryASet16(ss, bp - 20- 2, ax); | |
loc_11f7d: | |
if (memoryAGet16(ss, bp - 16- 2) == 0x0000) | |
goto loc_11f90; | |
ax = memoryAGet16(ss, bp - 6- 2); | |
memoryASet16(ds, 0x3e3c, ax); | |
memoryASet16(ss, bp - 18- 2, 0x0001); | |
goto loc_11f9a; | |
loc_11f90: | |
memoryASet16(ss, bp - 18- 2, 0x0000); | |
goto loc_11f9a; | |
loc_11f97: | |
memoryASet16(ss, bp - 18- 2, memoryAGet16(ss, bp - 18- 2) + 1); | |
loc_11f9a: | |
ax = memoryAGet16(ss, bp - 18- 2); | |
if (memoryAGet16(ss, bp - 20- 2) <= ax) | |
goto loc_11fbc; | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
bx = 0x3e3c; | |
cx = memoryAGet16(ss, bp - 18- 2); | |
cx <<= 1; | |
bx -= cx; | |
memoryASet16(ds, bx, ax); | |
goto loc_11f97; | |
loc_11fbc: | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 10- 2, ax); | |
if (ax) | |
goto loc_11fd8; | |
if (memoryAGet16(ss, bp - 20- 2) > 0x0001) | |
goto loc_11fd8; | |
goto loc_1218d; | |
loc_11fd8: | |
ax = memoryAGet16(ss, bp - 16- 2); | |
memoryASet16(ss, bp - 2- 2, ax); | |
cl = 0x0c; | |
ax = memoryAGet16(ss, bp - 10- 2); | |
ax = sar(ax, cl); | |
ax &= 0x000f; | |
memoryASet16(ss, bp - 16- 2, ax); | |
if (!ax) | |
goto loc_12050; | |
ax = memoryAGet16(ss, bp - 10- 2); | |
ah &= 0x0f; | |
if (ax == 0x0fff) | |
goto loc_1200b; | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 6- 2, ax); | |
goto loc_1203e; | |
loc_1200b: | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10c19(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 6- 2, ax); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10ca3(); | |
bx = pop(); | |
bx = pop(); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_10ca3(); | |
bx = pop(); | |
bx = pop(); | |
loc_1203e: | |
ax = memoryAGet16(ss, bp - 6- 2); | |
bx = 0x3e3c; | |
cx = memoryAGet16(ss, bp - 20- 2); | |
cx <<= 1; | |
bx -= cx; | |
memoryASet16(ds, bx, ax); | |
memoryASet16(ss, bp - 20- 2, memoryAGet16(ss, bp - 20- 2) + 1); | |
loc_12050: | |
ax = 0x3e3d; | |
push(ds); | |
push(ax); | |
sub_1354a(); | |
bx = pop(); | |
bx = pop(); | |
if (memoryAGet16(ss, bp - 2- 2) == 0x0000) | |
goto loc_1206b; | |
push(memoryAGet16(ss, bp - 2- 2)); | |
sub_13597(); | |
bx = pop(); | |
loc_1206b: | |
stop(); // lea ax, [bp - 0x24] | |
push(ss); | |
push(ax); | |
push(cs); | |
sub_121bd(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x0001; | |
push(ax); | |
sub_13563(); | |
bx = pop(); | |
memoryASet16(ss, bp - 38- 2, ax); | |
cx = memoryAGet16(ss, bp - 20- 2); | |
cx <<= 1; | |
if (ax == cx) | |
goto loc_120b0; | |
push(memoryAGet16(ss, bp - 40- 2)); | |
push(memoryAGet16(ss, bp - 42- 2)); | |
ax = 0x0e42; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
sp += 0x0008; | |
ax = 0x0001; | |
push(ax); | |
ax = 0x3c1e; | |
push(ds); | |
push(ax); | |
sub_161b0(); | |
sp += 0x0006; | |
loc_120b0: | |
memoryASet16(ss, bp - 18- 2, 0x0000); | |
loc_120b5: | |
bx = memoryAGet16(ss, bp - 18- 2); | |
bx <<= 1; | |
bx <<= 1; | |
ax = memoryAGet16(ds, bx + 15326); | |
dx = memoryAGet16(ds, bx + 15328); | |
cl = 0x03; | |
si = memoryAGet16(ss, bp - 18- 2); | |
si <<= cl; | |
flags.carry = (memoryAGet16(ds, si + 16414) + ax) >= 0x10000; | |
memoryASet16(ds, si + 16414, memoryAGet16(ds, si + 16414) + ax); | |
memoryASet16(ds, si + 16416, memoryAGet16(ds, si + 16416) + (dx + flags.carry)); | |
ax = memoryAGet16(ds, si + 18334); | |
dx = memoryAGet16(ds, si + 18336); | |
memoryASet16(ds, bx + 15326, ax); | |
memoryASet16(ds, bx + 15328, dx); | |
memoryASet16(ss, bp - 18- 2, memoryAGet16(ss, bp - 18- 2) + 1); | |
if ((short)memoryAGet16(ss, bp - 18- 2) < (short)0x0010) | |
goto loc_120b5; | |
ax = 0x0006; | |
push(ax); | |
ax = 0x0421; | |
push(ax); | |
ax = 0x3e3e; | |
push(ds); | |
push(ax); | |
ax = 0x401e; | |
push(ds); | |
push(ax); | |
sub_12f7f(); | |
sp += 0x000c; | |
if ((short)memoryAGet16(ss, bp - 12- 2) > (short)0x0000) | |
goto loc_1213c; | |
if ((short)memoryAGet16(ss, bp - 12- 2) < (short)0x0000) | |
goto loc_12115; | |
if (memoryAGet16(ss, bp - 14- 2) >= 0x00f0) | |
goto loc_1213c; | |
loc_12115: | |
if ((short)memoryAGet16(ss, bp - 12- 2) > (short)0x0000) | |
goto loc_12134; | |
if ((short)memoryAGet16(ss, bp - 12- 2) < (short)0x0000) | |
goto loc_12123; | |
if (memoryAGet16(ss, bp - 14- 2) != 0x0000) | |
goto loc_12134; | |
loc_12123: | |
ax = 0x0001; | |
push(ax); | |
ax = 0x3c1e; | |
push(ds); | |
push(ax); | |
sub_161b0(); | |
sp += 0x0006; | |
loc_12134: | |
ax = memoryAGet16(ss, bp - 14- 2); | |
memoryASet16(ss, bp - 8- 2, ax); | |
goto loc_12141; | |
loc_1213c: | |
memoryASet16(ss, bp - 8- 2, 0x00f0); | |
loc_12141: | |
push(memoryAGet16(ss, bp + 12- 2)); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(memoryAGet16(ss, bp - 8- 2)); | |
ax = 0x0002; | |
push(ax); | |
ax = 0x3e3e; | |
push(ds); | |
push(ax); | |
sub_1457c(); | |
sp += 0x000c; | |
if (ax >= memoryAGet16(ss, bp - 8- 2)) | |
goto loc_12171; | |
ax = 0x0002; | |
push(ax); | |
ax = 0x3c1e; | |
push(ds); | |
push(ax); | |
sub_161b0(); | |
sp += 0x0006; | |
loc_12171: | |
ax = memoryAGet16(ss, bp - 8- 2); | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
flags.carry = memoryAGet16(ss, bp - 14- 2) < ax; | |
memoryASet16(ss, bp - 14- 2, memoryAGet16(ss, bp - 14- 2) - ax); | |
memoryASet16(ss, bp - 12- 2, memoryAGet16(ss, bp - 12- 2) - (dx + flags.carry)); | |
flags.carry = (memoryAGet16(ss, bp - 42- 2) + 0x0001) >= 0x10000; | |
memoryASet16(ss, bp - 42- 2, memoryAGet16(ss, bp - 42- 2) + 0x0001); | |
memoryASet16(ss, bp - 40- 2, memoryAGet16(ss, bp - 40- 2) + flags.carry); | |
if (!(memoryAGet16(ss, bp - 10- 2) & 0x0fff)) | |
goto loc_1218d; | |
goto loc_11f3a; | |
loc_1218d: | |
ax = memoryAGet16(ss, bp - 12- 2); | |
ax |= memoryAGet16(ss, bp - 14- 2); | |
if (!ax) | |
goto loc_121b8; | |
push(memoryAGet16(ss, bp - 12- 2)); | |
push(memoryAGet16(ss, bp - 14- 2)); | |
ax = 0x0e5c; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
sp += 0x0008; | |
ax = 0x0e71; | |
push(ds); | |
push(ax); | |
ax = 0x0001; | |
push(ax); | |
push(cs); | |
sub_1289e(); | |
sp += 0x0006; | |
loc_121b8: | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_121bd() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0012; | |
sub_13f40(); | |
push(si); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_1242b(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0x401e; | |
push(ds); | |
push(ax); | |
ax = 0x3790; | |
push(ds); | |
push(ax); | |
sub_12dce(); | |
sp += 0x0008; | |
memoryASet16(ss, bp - 10- 2, 0x0010); | |
ax = 0; | |
memoryASet16(ss, bp - 6- 2, ax); | |
memoryASet16(ss, bp - 8- 2, ax); | |
goto loc_12298; | |
loc_121f7: | |
al = memoryAGet(es, bx + si); | |
cx = ax; | |
ax &= 0x0003; | |
memoryASet16(ss, bp - 12- 2, ax); | |
memoryASet16(ss, bp - 2- 2, ax); | |
cl &= 0x3c; | |
cl >>= 1; | |
cl >>= 1; | |
ch = 0; | |
memoryASet16(ss, bp - 16- 2, cx); | |
if (!ax) | |
goto loc_12221; | |
ax -= 0x0003; | |
ax = -ax; | |
memoryASet16(ss, bp - 12- 2, ax); | |
cx++; | |
memoryASet16(ss, bp - 16- 2, cx); | |
loc_12221: | |
if (!(memoryAGet(es, bx + si) & 0x40)) | |
goto loc_12239; | |
if (memoryAGet16(ss, bp - 10- 2) != 0x000f) | |
goto loc_12239; | |
ax = 0x0e8c; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
loc_12239: | |
bx = memoryAGet16(ss, bp - 8- 2); | |
bx <<= 1; | |
ax = memoryAGet16(ds, bx + 1514); | |
ax <<= 1; | |
memoryASet16(ss, bp - 14- 2, ax); | |
memoryASet16(ss, bp - 4- 2, 0x0000); | |
goto loc_1228a; | |
loc_1224e: | |
al = memoryAGet(ss, bp - 16- 2); | |
push(ax); | |
ax = memoryAGet16(ss, bp - 4- 2); | |
ax += memoryAGet16(ss, bp - 6- 2); | |
memoryASet16(ss, bp - 18- 2, ax); | |
ax <<= 1; | |
ax <<= 1; | |
ax += 0x401e; | |
push(ax); | |
si = ax; | |
sub_1621e(); | |
if (memoryAGet16(ss, bp - 2- 2) == 0x0000) | |
goto loc_12287; | |
bx = memoryAGet16(ss, bp - 12- 2); | |
bx <<= 1; | |
push(memoryAGet16(ds, bx + 1364)); | |
ax = 0x0001; | |
push(ax); | |
push(ds); | |
push(si); | |
sub_13030(); | |
sp += 0x0008; | |
loc_12287: | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 1); | |
loc_1228a: | |
ax = memoryAGet16(ss, bp - 14- 2); | |
if ((short)memoryAGet16(ss, bp - 4- 2) < (short)ax) | |
goto loc_1224e; | |
memoryASet16(ss, bp - 6- 2, memoryAGet16(ss, bp - 6- 2) + ax); | |
memoryASet16(ss, bp - 8- 2, memoryAGet16(ss, bp - 8- 2) + 1); | |
loc_12298: | |
if ((short)memoryAGet16(ss, bp - 8- 2) >= (short)0x0010) | |
goto loc_122ad; | |
stop(); // les bx, ptr [bp + 6] | |
si = memoryAGet16(ss, bp - 8- 2); | |
if (memoryAGet(es, bx + si) == 0xff) | |
goto loc_122ad; | |
goto loc_121f7; | |
loc_122ad: | |
memoryASet16(ss, bp - 4- 2, 0x0002); | |
loc_122b2: | |
bx = memoryAGet16(ss, bp - 4- 2); | |
bx <<= 1; | |
bx <<= 1; | |
ax = memoryAGet16(ds, bx + 16414); | |
dx = memoryAGet16(ds, bx + 16416); | |
si = 0x481e; | |
si -= bx; | |
memoryASet16(ds, si, ax); | |
memoryASet16(ds, si + 2, dx); | |
ax = memoryAGet16(ds, bx + 16418); | |
dx = memoryAGet16(ds, bx + 16420); | |
ax = -ax; | |
stop(/*8*/); // inject carry failed | |
dx += flags.carry; | |
dx = -dx; | |
si = 0x4822; | |
si -= bx; | |
memoryASet16(ds, si, ax); | |
memoryASet16(ds, si + 2, dx); | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 0x0002); | |
if ((short)memoryAGet16(ss, bp - 4- 2) < (short)0x0100) | |
goto loc_122b2; | |
ax = 0; | |
memoryASet16(ds, 0x4024, ax); | |
memoryASet16(ds, 0x4022, ax); | |
memoryASet16(ds, 0x4424, ax); | |
memoryASet16(ds, 0x4422, ax); | |
push(cs); | |
sub_1272f(); | |
ax = 0x401e; | |
push(ds); | |
push(ax); | |
sub_12f4a(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 18- 2, 0x0000); | |
loc_12312: | |
cl = 0x03; | |
bx = memoryAGet16(ss, bp - 18- 2); | |
bx <<= cl; | |
ax = memoryAGet16(ds, bx + 16494); | |
dx = memoryAGet16(ds, bx + 16496); | |
bx = memoryAGet16(ss, bp - 18- 2); | |
bx <<= 1; | |
bx <<= 1; | |
memoryASet16(ds, bx + 18868, ax); | |
memoryASet16(ds, bx + 18870, dx); | |
memoryASet16(ss, bp - 18- 2, memoryAGet16(ss, bp - 18- 2) + 1); | |
if ((short)memoryAGet16(ss, bp - 18- 2) < (short)0x0006) | |
goto loc_12312; | |
ax = 0x09d8; | |
push(ds); | |
push(ax); | |
ax = 0x401e; | |
push(ds); | |
push(ax); | |
sub_12b15(); | |
sp += 0x0008; | |
memoryASet16(ss, bp - 18- 2, 0x0000); | |
loc_12350: | |
bx = memoryAGet16(ss, bp - 18- 2); | |
bx <<= 1; | |
bx <<= 1; | |
ax = memoryAGet16(ds, bx + 18868); | |
dx = memoryAGet16(ds, bx + 18870); | |
cl = 0x03; | |
si = memoryAGet16(ss, bp - 18- 2); | |
si <<= cl; | |
flags.carry = (memoryAGet16(ds, si + 16494) + ax) >= 0x10000; | |
memoryASet16(ds, si + 16494, memoryAGet16(ds, si + 16494) + ax); | |
memoryASet16(ds, si + 16496, memoryAGet16(ds, si + 16496) + (dx + flags.carry)); | |
ax = memoryAGet16(ds, si + 18334); | |
dx = memoryAGet16(ds, si + 18336); | |
memoryASet16(ds, bx + 18868, ax); | |
memoryASet16(ds, bx + 18870, dx); | |
memoryASet16(ss, bp - 18- 2, memoryAGet16(ss, bp - 18- 2) + 1); | |
if ((short)memoryAGet16(ss, bp - 18- 2) < (short)0x0006) | |
goto loc_12350; | |
ax = 0x09f6; | |
push(ds); | |
push(ax); | |
ax = 0x479e; | |
push(ds); | |
push(ax); | |
sub_12b15(); | |
sp += 0x0008; | |
memoryASet16(ss, bp - 18- 2, 0x0000); | |
loc_1239e: | |
bx = memoryAGet16(ss, bp - 18- 2); | |
bx <<= 1; | |
bx <<= 1; | |
ax = memoryAGet16(ds, bx + 18868); | |
dx = memoryAGet16(ds, bx + 18870); | |
cl = 0x03; | |
bx = memoryAGet16(ss, bp - 18- 2); | |
bx <<= cl; | |
flags.carry = (memoryAGet16(ds, bx + 18334) + ax) >= 0x10000; | |
memoryASet16(ds, bx + 18334, memoryAGet16(ds, bx + 18334) + ax); | |
memoryASet16(ds, bx + 18336, memoryAGet16(ds, bx + 18336) + (dx + flags.carry)); | |
memoryASet16(ss, bp - 18- 2, memoryAGet16(ss, bp - 18- 2) + 1); | |
if ((short)memoryAGet16(ss, bp - 18- 2) < (short)0x0006) | |
goto loc_1239e; | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_123ca() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0006; | |
sub_13f40(); | |
push(di); | |
push(si); | |
memoryASet16(ss, bp - 4- 2, 0x0000); | |
goto loc_12406; | |
loc_123de: | |
ax = 0x0001; | |
push(ax); | |
di = bx; | |
sub_13597(); | |
bx = pop(); | |
ax--; | |
if (ax != 0) | |
goto loc_123f5; | |
stop(); // les bx, ptr [bp + 6] | |
ax = memoryAGet16(es, bx + di); | |
goto loc_12403; | |
loc_123f5: | |
si = memoryAGet16(ss, bp - 4- 2); | |
si <<= 1; | |
si <<= 1; | |
stop(); // les bx, ptr [bp + 6] | |
ax = memoryAGet16(es, bx + si + 2); | |
loc_12403: | |
memoryASet16(ss, bp - 4- 2, ax); | |
loc_12406: | |
bx = memoryAGet16(ss, bp - 4- 2); | |
bx <<= 1; | |
bx <<= 1; | |
stop(); // les si, ptr [bp + 6] | |
if (memoryAGet16(es, bx + si) != 0x0800) | |
goto loc_123de; | |
si = memoryAGet16(ss, bp - 4- 2); | |
si <<= 1; | |
si <<= 1; | |
bx = memoryAGet16(ss, bp + 6- 2); | |
ax = memoryAGet16(es, bx + si + 2); | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_1242b() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0016; | |
sub_13f40(); | |
push(di); | |
push(si); | |
memoryASet16(ss, bp - 4- 2, 0x3790); | |
memoryASet16(ss, bp - 2- 2, ds); | |
ax = 0; | |
memoryASet16(ss, bp - 16- 2, ax); | |
memoryASet16(ss, bp - 12- 2, ax); | |
goto loc_12462; | |
loc_1244a: | |
es = memoryAGet16(ds, 0x356e); | |
bx = memoryAGet16(ss, bp - 12- 2); | |
al = memoryAGet(es, bx); | |
stop(); // les bx, ptr [bp + 6] | |
si = memoryAGet16(ss, bp - 12- 2); | |
memoryASet(es, bx + si, al); | |
memoryASet16(ss, bp - 12- 2, memoryAGet16(ss, bp - 12- 2) + 1); | |
loc_12462: | |
if ((short)memoryAGet16(ss, bp - 12- 2) < (short)0x0010) | |
goto loc_1244a; | |
memoryASet16(ss, bp - 12- 2, 0x0000); | |
loc_1246d: | |
es = memoryAGet16(ds, 0x357a); | |
bx = memoryAGet16(ss, bp - 12- 2); | |
bx <<= 1; | |
ax = bx; | |
bx = memoryAGet16(es, bx + 84); | |
si = ax; | |
es = memoryAGet16(ds, 0x3570); | |
bx <<= 1; | |
ax = memoryAGet16(es, si + 148); | |
es = memoryAGet16(ds, 0x356c); | |
stop(); // les di, ptr es:[0x10] | |
ax += memoryAGet16(es, bx + di); | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
ax -= dx; | |
ax = sar(ax, 1); | |
es = memoryAGet16(ds, 0x3570); | |
memoryASet16(es, si + 148, ax); | |
stop(); // les bx, ptr [bp + 6] | |
si = memoryAGet16(ss, bp - 12- 2); | |
memoryASet(es, bx + si, memoryAGet(es, bx + si) + al); | |
memoryASet16(ss, bp - 12- 2, memoryAGet16(ss, bp - 12- 2) + 1); | |
if ((short)memoryAGet16(ss, bp - 12- 2) < (short)0x0003) | |
goto loc_1246d; | |
memoryASet16(ss, bp - 12- 2, 0x0000); | |
goto loc_12520; | |
loc_124bd: | |
memoryASet16(ss, bp - 16- 2, 0x0000); | |
ax = 0x10f4; | |
cx = 0x1adc; | |
push(cx); | |
push(ax); | |
push(cs); | |
sub_123ca(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 22- 2, ax); | |
es = memoryAGet16(ds, 0x357a); | |
bx = memoryAGet16(ss, bp - 12- 2); | |
bx <<= 1; | |
ax = memoryAGet16(es, bx + 84); | |
memoryASet16(ss, bp - 22- 2, memoryAGet16(ss, bp - 22- 2) - 0x000f); | |
ax += memoryAGet16(ss, bp - 22- 2); | |
memoryASet16(ss, bp - 20- 2, ax); | |
memoryASet16(es, bx + 84, ax); | |
ax = memoryAGet16(ss, bp - 20- 2); | |
es = memoryAGet16(ds, 0x3590); | |
memoryASet16(es, bx + 202, ax); | |
if (ax != 0x0010) | |
goto loc_1251d; | |
ax = 0x0eaa; | |
push(ds); | |
push(ax); | |
ax = 0x2f18; | |
push(ds); | |
push(ax); | |
sub_143ca(); | |
sp += 0x0008; | |
ax = 0xffff; | |
push(ax); | |
sub_13e55(); | |
bx = pop(); | |
loc_1251d: | |
memoryASet16(ss, bp - 12- 2, memoryAGet16(ss, bp - 12- 2) + 1); | |
loc_12520: | |
if ((short)memoryAGet16(ss, bp - 12- 2) >= (short)0x0010) | |
goto loc_12532; | |
stop(); // les bx, ptr [bp + 6] | |
si = memoryAGet16(ss, bp - 12- 2); | |
if (memoryAGet(es, bx + si) != 0xff) | |
goto loc_124bd; | |
loc_12532: | |
memoryASet16(ss, bp - 12- 2, 0x0000); | |
goto loc_126e4; | |
loc_1253a: | |
if (si) | |
goto loc_12546; | |
ax = memoryAGet16(ds, 0x05ea); | |
ax <<= 1; | |
ax--; | |
goto loc_1255e; | |
loc_12546: | |
if (!(memoryAGet(es, bx + si) & 0x40)) | |
goto loc_12554; | |
si <<= 1; | |
ax = memoryAGet16(ds, si + 1514); | |
goto loc_1255e; | |
loc_12554: | |
bx = si; | |
bx <<= 1; | |
ax = memoryAGet16(ds, bx + 1514); | |
ax <<= 1; | |
loc_1255e: | |
memoryASet16(ss, bp - 10- 2, ax); | |
es = memoryAGet16(ds, 0x3590); | |
bx = memoryAGet16(ss, bp - 12- 2); | |
bx <<= 1; | |
si = memoryAGet16(es, bx + 202); | |
memoryASet16(ss, bp - 20- 2, si); | |
si <<= 1; | |
si <<= 1; | |
stop(); // les bx, ptr [bp - 8] | |
al = memoryAGet(es, bx + si + 2); | |
stop(); // les bx, ptr [bp + 6] | |
si = memoryAGet16(ss, bp - 12- 2); | |
memoryASet(es, bx + si, memoryAGet(es, bx + si) + al); | |
bx = memoryAGet16(ss, bp - 20- 2); | |
bx <<= 1; | |
bx <<= 1; | |
stop(); // les si, ptr [bp - 8] | |
ax = memoryAGet16(es, bx + si); | |
memoryASet16(ss, bp - 20- 2, ax); | |
if (ax) | |
goto loc_125a1; | |
memoryASet16(ss, bp - 16- 2, 0x0001); | |
goto loc_125a6; | |
loc_125a1: | |
memoryASet16(ss, bp - 16- 2, 0x0000); | |
loc_125a6: | |
if (memoryAGet16(ss, bp - 16- 2) == 0x0000) | |
goto loc_125cc; | |
memoryASet16(ss, bp - 14- 2, 0x0000); | |
goto loc_125b6; | |
loc_125b3: | |
memoryASet16(ss, bp - 14- 2, memoryAGet16(ss, bp - 14- 2) + 1); | |
loc_125b6: | |
ax = memoryAGet16(ss, bp - 14- 2); | |
if ((short)memoryAGet16(ss, bp - 10- 2) <= (short)ax) | |
goto loc_125e3; | |
bx = ax; | |
bx <<= 1; | |
stop(); // les si, ptr [bp - 4] | |
memoryASet16(es, bx + si, 0x0000); | |
goto loc_125b3; | |
loc_125cc: | |
if ((short)ax <= (short)0x0006) | |
goto loc_12647; | |
push(memoryAGet16(ss, bp - 10- 2)); | |
push(ax); | |
push(memoryAGet16(ss, bp - 2- 2)); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
sub_135c1(); | |
sp += 0x0008; | |
loc_125e3: | |
stop(); // les bx, ptr [bp + 6] | |
si = memoryAGet16(ss, bp - 12- 2); | |
if (memoryAGet(es, bx + si) & 0x40) | |
goto loc_125f2; | |
goto loc_126d9; | |
loc_125f2: | |
if (memoryAGet16(ss, bp - 10- 2) == 0x0008) | |
goto loc_12604; | |
ax = 0x0ee3; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
loc_12604: | |
if (memoryAGet16(ss, bp - 12- 2) != 0x0000) | |
goto loc_12616; | |
ax = 0x0efa; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
loc_12616: | |
memoryASet16(ss, bp - 14- 2, 0x0007); | |
es = memoryAGet16(ss, bp - 2- 2); | |
loc_1261e: | |
bx = memoryAGet16(ss, bp - 14- 2); | |
bx <<= 1; | |
si = memoryAGet16(ss, bp - 4- 2); | |
ax = memoryAGet16(es, bx + si); | |
bx = memoryAGet16(ss, bp - 14- 2); | |
bx <<= 1; | |
bx <<= 1; | |
memoryASet16(es, bx + si, ax); | |
bx += si; | |
memoryASet16(es, bx + 2, 0x0000); | |
memoryASet16(ss, bp - 14- 2, memoryAGet16(ss, bp - 14- 2) - 1); | |
if ((short)memoryAGet16(ss, bp - 14- 2) >= 0) | |
goto loc_1261e; | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 0x0020); | |
goto loc_126e1; | |
loc_12647: | |
memoryASet16(ss, bp - 14- 2, 0x0000); | |
goto loc_12669; | |
loc_1264e: | |
cl = memoryAGet(ss, bp - 20- 2); | |
cl--; | |
ax = 0xffff; | |
ax <<= cl; | |
ax += memoryAGet16(ss, bp - 22- 2); | |
bx = memoryAGet16(ss, bp - 14- 2); | |
bx <<= 1; | |
stop(); // les si, ptr [bp - 4] | |
memoryASet16(es, bx + si, ax); | |
loc_12666: | |
memoryASet16(ss, bp - 14- 2, memoryAGet16(ss, bp - 14- 2) + 1); | |
loc_12669: | |
ax = memoryAGet16(ss, bp - 14- 2); | |
if ((short)memoryAGet16(ss, bp - 10- 2) > (short)ax) | |
goto loc_12674; | |
goto loc_125e3; | |
loc_12674: | |
es = memoryAGet16(ds, 0x3596); | |
bx = memoryAGet16(ss, bp - 20- 2); | |
bx <<= 1; | |
bx <<= 1; | |
push(memoryAGet16(es, bx + 11842)); | |
push(memoryAGet16(es, bx + 11840)); | |
push(cs); | |
sub_123ca(); | |
bx = pop(); | |
bx = pop(); | |
memoryASet16(ss, bp - 22- 2, ax); | |
cl = memoryAGet(ss, bp - 20- 2); | |
dx = 0x0001; | |
dx <<= cl; | |
if (ax != dx) | |
goto loc_1264e; | |
ax = memoryAGet16(ss, bp - 10- 2); | |
ax -= memoryAGet16(ss, bp - 14- 2); | |
ax--; | |
if (ax != 0) | |
goto loc_126bd; | |
ax = 0x0ec2; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
ax = 0xffff; | |
push(ax); | |
sub_13e55(); | |
bx = pop(); | |
loc_126bd: | |
bx = memoryAGet16(ss, bp - 14- 2); | |
bx <<= 1; | |
stop(); // les si, ptr [bp - 4] | |
memoryASet16(es, bx + si, 0x0000); | |
memoryASet16(ss, bp - 14- 2, memoryAGet16(ss, bp - 14- 2) + 1); | |
bx = memoryAGet16(ss, bp - 14- 2); | |
bx <<= 1; | |
memoryASet16(es, bx + si, 0x0000); | |
goto loc_12666; | |
loc_126d9: | |
ax = memoryAGet16(ss, bp - 10- 2); | |
ax <<= 1; | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + ax); | |
loc_126e1: | |
memoryASet16(ss, bp - 12- 2, memoryAGet16(ss, bp - 12- 2) + 1); | |
loc_126e4: | |
if ((short)memoryAGet16(ss, bp - 12- 2) >= (short)0x0010) | |
goto loc_12722; | |
bx = memoryAGet16(ss, bp - 12- 2); | |
bx <<= 1; | |
bx = memoryAGet16(ds, bx + 1852); | |
bx <<= 1; | |
bx <<= 1; | |
ax = memoryAGet16(ds, bx + 1836); | |
dx = memoryAGet16(ds, bx + 1838); | |
memoryASet16(ss, bp - 8- 2, ax); | |
memoryASet16(ss, bp - 6- 2, dx); | |
stop(); // les bx, ptr [bp + 6] | |
si = memoryAGet16(ss, bp - 12- 2); | |
if (memoryAGet(es, bx + si) == 0xff) | |
goto loc_12714; | |
goto loc_1253a; | |
loc_12714: | |
goto loc_12722; | |
loc_12716: | |
stop(); // les bx, ptr [bp - 4] | |
memoryASet16(es, bx, 0x0000); | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 0x0002); | |
loc_12722: | |
if (memoryAGet16(ss, bp - 4- 2) < 0x3990) | |
goto loc_12716; | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_1272f() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x000c; | |
sub_13f40(); | |
ax = 0x0080; | |
push(ax); | |
ax = 0x401e; | |
push(ds); | |
push(ax); | |
sub_12d2e(); | |
sp += 0x0006; | |
ax = 0x0040; | |
push(ax); | |
cx = 0x401e; | |
push(ds); | |
push(cx); | |
sub_12d2e(); | |
sp += 0x0006; | |
ax = 0x0040; | |
push(ax); | |
ax = 0x441e; | |
push(ds); | |
push(ax); | |
sub_12d6c(); | |
sp += 0x0006; | |
memoryASet16(ss, bp - 10- 2, 0x481e); | |
memoryASet16(ss, bp - 6- 2, 0x0020); | |
goto loc_127b1; | |
loc_12779: | |
memoryASet16(ss, bp - 12- 2, memoryAGet16(ss, bp - 12- 2) + 1); | |
loc_1277c: | |
ax = memoryAGet16(ss, bp - 10- 2); | |
if (memoryAGet16(ss, bp - 4- 2) >= ax) | |
goto loc_127ae; | |
push(memoryAGet16(ss, bp - 6- 2)); | |
bx = memoryAGet16(ss, bp - 12- 2); | |
bx <<= 1; | |
push(memoryAGet16(ds, bx + 2140)); | |
push(memoryAGet16(ds, bx + 1884)); | |
push(memoryAGet16(ss, bp - 2- 2)); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
sub_12b59(); | |
sp += 0x000a; | |
cl = 0x04; | |
ax = memoryAGet16(ss, bp - 6- 2); | |
ax <<= cl; | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + ax); | |
goto loc_12779; | |
loc_127ae: | |
memoryASet16(ss, bp - 6- 2, sar(memoryAGet16(ss, bp - 6- 2), 1)); | |
loc_127b1: | |
if (memoryAGet16(ss, bp - 6- 2) == 0x0000) | |
goto loc_127f5; | |
push(memoryAGet16(ss, bp - 6- 2)); | |
ax = 0x401e; | |
push(ds); | |
push(ax); | |
sub_12d2e(); | |
sp += 0x0006; | |
push(memoryAGet16(ss, bp - 6- 2)); | |
cl = 0x04; | |
ax = memoryAGet16(ss, bp - 6- 2); | |
ax <<= cl; | |
ax += 0x401e; | |
push(ds); | |
push(ax); | |
sub_12d6c(); | |
sp += 0x0006; | |
cl = 0x05; | |
ax = memoryAGet16(ss, bp - 6- 2); | |
ax <<= cl; | |
ax += 0x401e; | |
memoryASet16(ss, bp - 4- 2, ax); | |
memoryASet16(ss, bp - 2- 2, ds); | |
memoryASet16(ss, bp - 12- 2, 0x0002); | |
goto loc_1277c; | |
loc_127f5: | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_127f9() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0006; | |
sub_13f40(); | |
push(si); | |
stop(); // les bx, ptr [bp + 6] | |
ax = memoryAGet16(es, bx); | |
dx = memoryAGet16(es, bx + 2); | |
memoryASet16(ss, bp - 4- 2, ax); | |
memoryASet16(ss, bp - 2- 2, dx); | |
goto loc_1281a; | |
loc_12817: | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 1); | |
loc_1281a: | |
stop(); // les bx, ptr [bp - 4] | |
if (memoryAGet(es, bx) == 0x20) | |
goto loc_12817; | |
if (memoryAGet(es, bx) != 0x00) | |
goto loc_1283c; | |
stop(); // les si, ptr [bp + 6] | |
ax = bx; | |
dx = memoryAGet16(ss, bp - 2- 2); | |
memoryASet16(es, si, ax); | |
memoryASet16(es, si + 2, dx); | |
ax = 0; | |
goto loc_12899; | |
loc_1283c: | |
memoryASet16(ss, bp - 6- 2, 0x0000); | |
loc_12841: | |
if ((short)memoryAGet16(ss, bp - 6- 2) >= (short)0x0080) | |
goto loc_12854; | |
al = memoryAGet(es, bx); | |
stop(); // les bx, ptr [bp + 0xa] | |
si = memoryAGet16(ss, bp - 6- 2); | |
memoryASet(es, bx + si, al); | |
loc_12854: | |
memoryASet16(ss, bp - 6- 2, memoryAGet16(ss, bp - 6- 2) + 1); | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 1); | |
stop(); // les bx, ptr [bp - 4] | |
if (memoryAGet(es, bx) == 0x20) | |
goto loc_12869; | |
if (memoryAGet(es, bx) != 0x00) | |
goto loc_12841; | |
loc_12869: | |
ax = bx; | |
dx = es; | |
stop(); // les bx, ptr [bp + 6] | |
memoryASet16(es, bx, ax); | |
memoryASet16(es, bx + 2, dx); | |
if ((short)memoryAGet16(ss, bp - 6- 2) <= (short)0x0080) | |
goto loc_1288c; | |
stop(); // les bx, ptr [bp + 0xa] | |
memoryASet(es, bx + 128, 0x00); | |
ax = 0xffff; | |
goto loc_12899; | |
loc_1288c: | |
stop(); // les bx, ptr [bp + 0xa] | |
si = memoryAGet16(ss, bp - 6- 2); | |
memoryASet(es, bx + si, 0x00); | |
ax = 0x0001; | |
loc_12899: | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_1289e() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0004; | |
sub_13f40(); | |
stop(); // lea ax, [bp + 0xc] | |
push(ss); | |
push(ax); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
ax = 0x49cc; | |
push(ds); | |
push(ax); | |
sub_15e04(); | |
sp += 0x000c; | |
ax = 0x49cc; | |
push(ds); | |
push(ax); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
sub_12a30(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_1292e() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0004; | |
sub_13f40(); | |
push(si); | |
memoryASet16(ss, bp - 4- 2, 0xffff); | |
ax = 0x1010; | |
push(ds); | |
push(ax); | |
sub_14714(); | |
bx = pop(); | |
bx = pop(); | |
if ((short)memoryAGet16(ss, bp + 6- 2) < (short)0x0002) | |
goto loc_12989; | |
stop(); // les bx, ptr [bp + 8] | |
push(memoryAGet16(es, bx + 6)); | |
push(memoryAGet16(es, bx + 4)); | |
sub_1595c(); | |
bx = pop(); | |
bx = pop(); | |
ax--; | |
if (ax != 0) | |
goto loc_12989; | |
stop(); // les bx, ptr [bp + 8] | |
stop(); // les bx, ptr es:[bx + 4] | |
al = memoryAGet(es, bx); | |
cbw(); | |
if (ax == 0x0064) | |
goto loc_129c7; | |
if (ax > 0x0064) | |
goto loc_12989; | |
al -= 0x43; | |
if (al == 0) | |
goto loc_12984; | |
al--; | |
if (al == 0) | |
goto loc_129c7; | |
al -= 0x1f; | |
if (al != 0) | |
goto loc_12989; | |
loc_12984: | |
memoryASet16(ss, bp - 4- 2, 0x0000); | |
loc_12989: | |
if (memoryAGet16(ss, bp - 4- 2) == 0xffff) | |
goto loc_12995; | |
if ((short)memoryAGet16(ss, bp + 6- 2) >= (short)0x0003) | |
goto loc_129a8; | |
loc_12995: | |
push(memoryAGet16(ss, bp - 4- 2)); | |
sub_10000(); | |
bx = pop(); | |
ax = 0x0001; | |
push(ax); | |
sub_13e55(); | |
bx = pop(); | |
loc_129a8: | |
stop(); // les bx, ptr [bp + 8] | |
push(memoryAGet16(es, bx + 10)); | |
push(memoryAGet16(es, bx + 8)); | |
ax = 0x4acc; | |
push(ds); | |
push(ax); | |
sub_15926(); | |
sp += 0x0008; | |
memoryASet16(ss, bp - 2- 2, 0x0003); | |
goto loc_129d1; | |
loc_129c7: | |
memoryASet16(ss, bp - 4- 2, 0x0001); | |
goto loc_12989; | |
loc_129ce: | |
memoryASet16(ss, bp - 2- 2, memoryAGet16(ss, bp - 2- 2) + 1); | |
loc_129d1: | |
ax = memoryAGet16(ss, bp - 2- 2); | |
if ((short)memoryAGet16(ss, bp + 6- 2) <= (short)ax) | |
goto loc_12a0b; | |
cx = 0x1038; | |
push(ds); | |
push(cx); | |
cx = 0x4acc; | |
push(ds); | |
push(cx); | |
sub_158e0(); | |
sp += 0x0008; | |
bx = memoryAGet16(ss, bp - 2- 2); | |
bx <<= 1; | |
bx <<= 1; | |
stop(); // les si, ptr [bp + 8] | |
push(memoryAGet16(es, bx + si + 2)); | |
push(memoryAGet16(es, bx + si)); | |
ax = 0x4acc; | |
push(ds); | |
push(ax); | |
sub_158e0(); | |
sp += 0x0008; | |
goto loc_129ce; | |
loc_12a0b: | |
if (memoryAGet16(ss, bp - 4- 2) != 0x0000) | |
goto loc_12a1f; | |
ax = 0x4acc; | |
push(ds); | |
push(ax); | |
sub_101e2(); | |
loc_12a1b: | |
bx = pop(); | |
bx = pop(); | |
goto loc_12a2b; | |
loc_12a1f: | |
ax = 0x4acc; | |
push(ds); | |
push(ax); | |
sub_101fd(); | |
goto loc_12a1b; | |
loc_12a2b: | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_12a30() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0; | |
sub_13f40(); | |
ax = 0x2f0c; | |
push(ds); | |
push(ax); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
sub_15b86(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_12b15() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
push(di); | |
push(ds); | |
stop(); // les di, ptr [bp + 6] | |
stop(); // lds si, ptr [bp + 0xa] | |
flags.direction = false; | |
cx = 0x0010; | |
loc_12b25: | |
push(cx); | |
lodsw<MemAuto, DirAuto>(); | |
bp = ax; | |
imul(memoryAGet16(es, di + 2)); | |
cx = ax; | |
bx = dx; | |
ax = bp; | |
bp = 0; | |
mul(memoryAGet16(es, di)); | |
flags.carry = (cx + dx) >= 0x10000; | |
cx += dx; | |
bx += bp + flags.carry; | |
ax <<= 1; | |
stop(/*carry*/); | |
cx = rcl(cx, 0x0001); | |
stop(/*carry*/); | |
bx = rcl(bx, 0x0001); | |
stop(/*74*/); | |
ax <<= 1; | |
tl = flags.carry; | |
flags.carry = (cx + bp + tl) >= 0x10000; | |
cx += bp + tl; | |
bx += bp + flags.carry; | |
ax = cx; | |
stosw<MemAuto, DirAuto>(); | |
ax = bx; | |
stosw<MemAuto, DirAuto>(); | |
di += 0x0004; | |
cx = pop(); | |
if (--cx) | |
goto loc_12b25; | |
ds = pop(); | |
di = pop(); | |
si = pop(); | |
bp = pop(); | |
} | |
void sub_12b59() | |
{ | |
stop(); // enter 0xa, 0 | |
push(ds); | |
push(si); | |
push(di); | |
stop(); // lds si, ptr [bp + 6] | |
di = memoryAGet16(ss, bp + 14- 2); | |
di <<= 3; | |
di += si; | |
ax = memoryAGet16(ss, bp + 10- 2); | |
if (!(ax & 0x8000)) | |
goto loc_12b7a; | |
ax = -ax; | |
memoryASet16(ss, bp + 10- 2, ax); | |
goto loc_12c54; | |
loc_12b7a: | |
ax = memoryAGet16(ss, bp + 10- 2); | |
imul(memoryAGet16(ds, di + 2)); | |
cx = ax; | |
bx = dx; | |
ax = memoryAGet16(ss, bp + 10- 2); | |
mul(memoryAGet16(ds, di)); | |
flags.carry = (cx + dx) >= 0x10000; | |
cx += dx; | |
bx += flags.carry; | |
memoryASet16(ss, bp - 6- 2, ax); | |
memoryASet16(ss, bp - 4- 2, cx); | |
memoryASet16(ss, bp - 2- 2, bx); | |
ax = memoryAGet16(ss, bp + 12- 2); | |
imul(memoryAGet16(ds, di + 6)); | |
cx = ax; | |
bx = dx; | |
ax = memoryAGet16(ss, bp + 12- 2); | |
mul(memoryAGet16(ds, di + 4)); | |
flags.carry = (cx + dx) >= 0x10000; | |
cx += dx; | |
bx += flags.carry; | |
flags.carry = (ax + memoryAGet16(ss, bp - 6- 2)) >= 0x10000; | |
ax += memoryAGet16(ss, bp - 6- 2); | |
tl = flags.carry; | |
flags.carry = (cx + memoryAGet16(ss, bp - 4- 2) + tl) >= 0x10000; | |
cx += memoryAGet16(ss, bp - 4- 2) + tl; | |
bx += memoryAGet16(ss, bp - 2- 2) + flags.carry; | |
ax <<= 1; | |
stop(/*carry*/); | |
cx = rcl(cx, 0x0001); | |
stop(/*carry*/); | |
bx = rcl(bx, 0x0001); | |
ax <<= 1; | |
if (stop(/*70*/)) | |
goto loc_12bc3; | |
cx++; | |
if (cx != 0) | |
goto loc_12bc3; | |
bx++; | |
loc_12bc3: | |
memoryASet16(ss, bp - 10- 2, cx); | |
memoryASet16(ss, bp - 8- 2, bx); | |
ax = memoryAGet16(ss, bp + 10- 2); | |
imul(memoryAGet16(ds, di + 6)); | |
cx = ax; | |
bx = dx; | |
ax = memoryAGet16(ss, bp + 10- 2); | |
mul(memoryAGet16(ds, di + 4)); | |
flags.carry = (cx + dx) >= 0x10000; | |
cx += dx; | |
bx += flags.carry; | |
memoryASet16(ss, bp - 6- 2, ax); | |
memoryASet16(ss, bp - 4- 2, cx); | |
memoryASet16(ss, bp - 2- 2, bx); | |
ax = memoryAGet16(ss, bp + 12- 2); | |
imul(memoryAGet16(ds, di + 2)); | |
cx = ax; | |
bx = dx; | |
ax = memoryAGet16(ss, bp + 12- 2); | |
mul(memoryAGet16(ds, di)); | |
flags.carry = (cx + dx) >= 0x10000; | |
cx += dx; | |
bx += flags.carry; | |
flags.carry = ax < memoryAGet16(ss, bp - 6- 2); | |
ax -= memoryAGet16(ss, bp - 6- 2); | |
stop(/*74*/); | |
cx -= memoryAGet16(ss, bp - 4- 2) + flags.carry; | |
bx -= memoryAGet16(ss, bp - 2- 2) + flags.carry; | |
ax <<= 1; | |
stop(/*carry*/); | |
cx = rcl(cx, 0x0001); | |
stop(/*carry*/); | |
bx = rcl(bx, 0x0001); | |
ax <<= 1; | |
if (stop(/*70*/)) | |
goto loc_12c12; | |
cx++; | |
if (cx != 0) | |
goto loc_12c12; | |
bx++; | |
loc_12c12: | |
ax = memoryAGet16(ds, si + 4); | |
dx = memoryAGet16(ds, si + 6); | |
flags.carry = (ax + cx) >= 0x10000; | |
ax += cx; | |
dx += bx + flags.carry; | |
memoryASet16(ds, di + 4, ax); | |
memoryASet16(ds, di + 6, dx); | |
flags.carry = memoryAGet16(ds, si + 4) < cx; | |
memoryASet16(ds, si + 4, memoryAGet16(ds, si + 4) - cx); | |
memoryASet16(ds, si + 6, memoryAGet16(ds, si + 6) - (bx + flags.carry)); | |
cx = memoryAGet16(ss, bp - 10- 2); | |
bx = memoryAGet16(ss, bp - 8- 2); | |
ax = memoryAGet16(ds, si); | |
dx = memoryAGet16(ds, si + 2); | |
flags.carry = ax < cx; | |
ax -= cx; | |
dx -= bx + flags.carry; | |
memoryASet16(ds, di, ax); | |
memoryASet16(ds, di + 2, dx); | |
flags.carry = (memoryAGet16(ds, si) + cx) >= 0x10000; | |
memoryASet16(ds, si, memoryAGet16(ds, si) + cx); | |
memoryASet16(ds, si + 2, memoryAGet16(ds, si + 2) + (bx + flags.carry)); | |
si += 0x0008; | |
di += 0x0008; | |
memoryASet16(ss, bp + 14- 2, memoryAGet16(ss, bp + 14- 2) - 1); | |
if (memoryAGet16(ss, bp + 14- 2) == 0) | |
goto loc_12c4f; | |
goto loc_12b7a; | |
loc_12c4f: | |
di = pop(); | |
si = pop(); | |
ds = pop(); | |
stop(); // leave | |
return; | |
loc_12c54: | |
ax = memoryAGet16(ss, bp + 10- 2); | |
imul(memoryAGet16(ds, di + 2)); | |
cx = ax; | |
bx = dx; | |
ax = memoryAGet16(ss, bp + 10- 2); | |
mul(memoryAGet16(ds, di)); | |
flags.carry = (cx + dx) >= 0x10000; | |
cx += dx; | |
bx += flags.carry; | |
memoryASet16(ss, bp - 6- 2, ax); | |
memoryASet16(ss, bp - 4- 2, cx); | |
memoryASet16(ss, bp - 2- 2, bx); | |
ax = memoryAGet16(ss, bp + 12- 2); | |
imul(memoryAGet16(ds, di + 6)); | |
cx = ax; | |
bx = dx; | |
ax = memoryAGet16(ss, bp + 12- 2); | |
mul(memoryAGet16(ds, di + 4)); | |
flags.carry = (cx + dx) >= 0x10000; | |
cx += dx; | |
bx += flags.carry; | |
flags.carry = ax < memoryAGet16(ss, bp - 6- 2); | |
ax -= memoryAGet16(ss, bp - 6- 2); | |
stop(/*74*/); | |
cx -= memoryAGet16(ss, bp - 4- 2) + flags.carry; | |
bx -= memoryAGet16(ss, bp - 2- 2) + flags.carry; | |
ax <<= 1; | |
stop(/*carry*/); | |
cx = rcl(cx, 0x0001); | |
stop(/*carry*/); | |
bx = rcl(bx, 0x0001); | |
ax <<= 1; | |
if (stop(/*70*/)) | |
goto loc_12c9d; | |
cx++; | |
if (cx != 0) | |
goto loc_12c9d; | |
bx++; | |
loc_12c9d: | |
memoryASet16(ss, bp - 10- 2, cx); | |
memoryASet16(ss, bp - 8- 2, bx); | |
ax = memoryAGet16(ss, bp + 10- 2); | |
imul(memoryAGet16(ds, di + 6)); | |
cx = ax; | |
bx = dx; | |
ax = memoryAGet16(ss, bp + 10- 2); | |
mul(memoryAGet16(ds, di + 4)); | |
flags.carry = (cx + dx) >= 0x10000; | |
cx += dx; | |
bx += flags.carry; | |
memoryASet16(ss, bp - 6- 2, ax); | |
memoryASet16(ss, bp - 4- 2, cx); | |
memoryASet16(ss, bp - 2- 2, bx); | |
ax = memoryAGet16(ss, bp + 12- 2); | |
imul(memoryAGet16(ds, di + 2)); | |
cx = ax; | |
bx = dx; | |
ax = memoryAGet16(ss, bp + 12- 2); | |
mul(memoryAGet16(ds, di)); | |
flags.carry = (cx + dx) >= 0x10000; | |
cx += dx; | |
bx += flags.carry; | |
ax += memoryAGet16(ss, bp - 6- 2); | |
flags.carry = (cx + memoryAGet16(ss, bp - 4- 2)) >= 0x10000; | |
cx += memoryAGet16(ss, bp - 4- 2); | |
bx += memoryAGet16(ss, bp - 2- 2) + flags.carry; | |
ax <<= 1; | |
stop(/*carry*/); | |
cx = rcl(cx, 0x0001); | |
stop(/*carry*/); | |
bx = rcl(bx, 0x0001); | |
ax <<= 1; | |
if (stop(/*70*/)) | |
goto loc_12cec; | |
cx++; | |
if (cx != 0) | |
goto loc_12cec; | |
bx++; | |
loc_12cec: | |
ax = memoryAGet16(ds, si + 4); | |
dx = memoryAGet16(ds, si + 6); | |
flags.carry = (ax + cx) >= 0x10000; | |
ax += cx; | |
dx += bx + flags.carry; | |
memoryASet16(ds, di + 4, ax); | |
memoryASet16(ds, di + 6, dx); | |
flags.carry = memoryAGet16(ds, si + 4) < cx; | |
memoryASet16(ds, si + 4, memoryAGet16(ds, si + 4) - cx); | |
memoryASet16(ds, si + 6, memoryAGet16(ds, si + 6) - (bx + flags.carry)); | |
cx = memoryAGet16(ss, bp - 10- 2); | |
bx = memoryAGet16(ss, bp - 8- 2); | |
ax = memoryAGet16(ds, si); | |
dx = memoryAGet16(ds, si + 2); | |
flags.carry = ax < cx; | |
ax -= cx; | |
dx -= bx + flags.carry; | |
memoryASet16(ds, di, ax); | |
memoryASet16(ds, di + 2, dx); | |
flags.carry = (memoryAGet16(ds, si) + cx) >= 0x10000; | |
memoryASet16(ds, si, memoryAGet16(ds, si) + cx); | |
memoryASet16(ds, si + 2, memoryAGet16(ds, si + 2) + (bx + flags.carry)); | |
si += 0x0008; | |
di += 0x0008; | |
memoryASet16(ss, bp + 14- 2, memoryAGet16(ss, bp + 14- 2) - 1); | |
if (memoryAGet16(ss, bp + 14- 2) == 0) | |
goto loc_12d29; | |
goto loc_12c54; | |
loc_12d29: | |
di = pop(); | |
si = pop(); | |
ds = pop(); | |
stop(); // leave | |
} | |
void sub_12d2e() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
push(di); | |
push(ds); | |
stop(); // lds si, ptr [bp + 6] | |
di = memoryAGet16(ss, bp + 10- 2); | |
di <<= 1; | |
memoryASet16(ss, bp + 10- 2, di); | |
di <<= 2; | |
di += si; | |
loc_12d44: | |
ax = memoryAGet16(ds, di); | |
dx = memoryAGet16(ds, di + 2); | |
cx = memoryAGet16(ds, si); | |
bx = memoryAGet16(ds, si + 2); | |
flags.carry = cx < ax; | |
cx -= ax; | |
bx -= dx + flags.carry; | |
memoryASet16(ds, di, cx); | |
memoryASet16(ds, di + 2, bx); | |
flags.carry = (memoryAGet16(ds, si) + ax) >= 0x10000; | |
memoryASet16(ds, si, memoryAGet16(ds, si) + ax); | |
memoryASet16(ds, si + 2, memoryAGet16(ds, si + 2) + (dx + flags.carry)); | |
si += 0x0004; | |
di += 0x0004; | |
memoryASet16(ss, bp + 10- 2, memoryAGet16(ss, bp + 10- 2) - 1); | |
if (memoryAGet16(ss, bp + 10- 2) != 0) | |
goto loc_12d44; | |
ds = pop(); | |
di = pop(); | |
si = pop(); | |
bp = pop(); | |
} | |
void sub_12d6c() | |
{ | |
stop(); // enter 4, 0 | |
push(si); | |
push(di); | |
push(ds); | |
stop(); // lds si, ptr [bp + 6] | |
di = memoryAGet16(ss, bp + 10- 2); | |
di <<= 3; | |
di += si; | |
loc_12d7e: | |
ax = memoryAGet16(ds, di); | |
memoryASet16(ss, bp - 4- 2, ax); | |
ax = memoryAGet16(ds, di + 2); | |
memoryASet16(ss, bp - 2- 2, ax); | |
ax = memoryAGet16(ds, di + 4); | |
dx = memoryAGet16(ds, di + 6); | |
cx = memoryAGet16(ds, si); | |
bx = memoryAGet16(ds, si + 2); | |
flags.carry = cx < ax; | |
cx -= ax; | |
bx -= dx + flags.carry; | |
memoryASet16(ds, di, cx); | |
memoryASet16(ds, di + 2, bx); | |
flags.carry = (memoryAGet16(ds, si) + ax) >= 0x10000; | |
memoryASet16(ds, si, memoryAGet16(ds, si) + ax); | |
memoryASet16(ds, si + 2, memoryAGet16(ds, si + 2) + (dx + flags.carry)); | |
ax = memoryAGet16(ss, bp - 4- 2); | |
dx = memoryAGet16(ss, bp - 2- 2); | |
cx = memoryAGet16(ds, si + 4); | |
bx = memoryAGet16(ds, si + 6); | |
flags.carry = (cx + ax) >= 0x10000; | |
cx += ax; | |
bx += dx + flags.carry; | |
memoryASet16(ds, di + 4, cx); | |
memoryASet16(ds, di + 6, bx); | |
flags.carry = memoryAGet16(ds, si + 4) < ax; | |
memoryASet16(ds, si + 4, memoryAGet16(ds, si + 4) - ax); | |
memoryASet16(ds, si + 6, memoryAGet16(ds, si + 6) - (dx + flags.carry)); | |
si += 0x0008; | |
di += 0x0008; | |
memoryASet16(ss, bp + 10- 2, memoryAGet16(ss, bp + 10- 2) - 1); | |
if (memoryAGet16(ss, bp + 10- 2) != 0) | |
goto loc_12d7e; | |
ds = pop(); | |
di = pop(); | |
si = pop(); | |
stop(); // leave | |
} | |
void sub_12dce() | |
{ | |
stop(); // enter 0, 0 | |
push(di); | |
push(si); | |
push(ds); | |
stop(); // lds si, ptr [bp + 6] | |
stop(); // les di, ptr [bp + 0xa] | |
cx = 0x0100; | |
flags.direction = false; | |
di += 0x0004; | |
loc_12de2: | |
lodsw<MemAuto, DirAuto>(); | |
dx = ax; | |
dx = sar(dx, 4); | |
ax <<= 12; | |
stosw<MemAuto, DirAuto>(); | |
ax = dx; | |
stosw<MemAuto, DirAuto>(); | |
if (--cx) | |
goto loc_12de2; | |
di = memoryAGet16(ss, bp + 10- 2); | |
ax = memoryAGet16(es, di + 4); | |
stosw<MemAuto, DirAuto>(); | |
ax = memoryAGet16(es, di + 4); | |
stosw<MemAuto, DirAuto>(); | |
ax = 0; | |
stosw<MemAuto, DirAuto>(); | |
stosw<MemAuto, DirAuto>(); | |
di += 0x03fc; | |
stosw<MemAuto, DirAuto>(); | |
stosw<MemAuto, DirAuto>(); | |
ds = memoryAGet16(ss, bp + 12- 2); | |
stop(); // lea si, [di - 0x10] | |
cx = 0x007f; | |
bx = 0xffff; | |
loc_12e14: | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
lodsw<MemAuto, DirAuto>(); | |
stosw<MemAuto, DirAuto>(); | |
tx = ax; | |
ax = dx; | |
dx = tx; | |
lodsw<MemAuto, DirAuto>(); | |
stosw<MemAuto, DirAuto>(); | |
ax = ~ax; | |
dx = -dx; | |
stop(/*81*/); | |
ax -= bx + flags.carry; | |
memoryASet16(ds, si + 65532, dx); | |
memoryASet16(ds, si + 65534, ax); | |
si -= 0x0010; | |
if (--cx) | |
goto loc_12e14; | |
ds = pop(); | |
si = pop(); | |
di = pop(); | |
stop(); // leave | |
} | |
void sub_12f4a() | |
{ | |
stop(); // enter 2, 0 | |
push(si); | |
push(di); | |
push(ds); | |
bx = 0x082b; | |
memoryASet16(ss, bp - 2- 2, 0x0078); | |
stop(); // lds si, ptr [bp + 6] | |
stop(); // les di, ptr [bp + 6] | |
flags.direction = false; | |
loc_12f60: | |
si += memoryAGet16(cs, bx); | |
di += memoryAGet16(cs, bx + 2); | |
cx = 0x0004; | |
bx += cx; | |
loc_12f6c: | |
lodsw<MemAuto, DirAuto>(); | |
dx = memoryAGet16(ds, di); | |
stosw<MemAuto, DirAuto>(); | |
memoryASet16(ds, si + 65534, dx); | |
if (--cx) | |
goto loc_12f6c; | |
memoryASet16(ss, bp - 2- 2, memoryAGet16(ss, bp - 2- 2) - 1); | |
if (memoryAGet16(ss, bp - 2- 2) != 0) | |
goto loc_12f60; | |
ds = pop(); | |
di = pop(); | |
si = pop(); | |
stop(); // leave | |
} | |
void sub_12f7f() | |
{ | |
stop(); // enter 2, 0 | |
push(si); | |
push(di); | |
push(ds); | |
flags.direction = false; | |
stop(); // lds si, ptr [bp + 6] | |
stop(); // les di, ptr [bp + 0xa] | |
memoryASet16(ss, bp - 2- 2, 0x00f0); | |
loc_12f92: | |
ax = memoryAGet16(ds, si + 2); | |
imul(memoryAGet16(ss, bp + 14- 2)); | |
bx = dx; | |
cx = ax; | |
lodsw<MemAuto, DirAuto>(); | |
mul(memoryAGet16(ss, bp + 14- 2)); | |
flags.carry = (dx + cx) >= 0x10000; | |
dx += cx; | |
cx = 0x0000; | |
bx += cx + flags.carry; | |
stop(/*74*/); | |
ax <<= 1; | |
tl = flags.carry; | |
flags.carry = (dx + cx + tl) >= 0x10000; | |
dx += cx + tl; | |
bx += cx + flags.carry; | |
ax = bx; | |
tx = ax; | |
ax = dx; | |
dx = tx; | |
cx = memoryAGet16(ss, bp + 16- 2); | |
if (cx == 0) | |
goto loc_12fbf; | |
loc_12fb5: | |
dx = sar(dx, 1); | |
stop(/*carry*/); | |
ax = rcr(ax, 1); | |
if (--cx) | |
goto loc_12fb5; | |
tl = flags.carry; | |
flags.carry = (ax + cx + tl) >= 0x10000; | |
stop(/*8*/); // inject carry failed | |
ax += cx + tl; | |
dx += cx + flags.carry; | |
loc_12fbf: | |
if (dx & 0x8000) | |
goto loc_12fcf; | |
if (dx) | |
goto loc_12fc9; | |
if (!(ax & 0x8000)) | |
goto loc_12fd9; | |
loc_12fc9: | |
ax = 0x7fff; | |
goto loc_12fd9; | |
// gap of 1 bytes | |
loc_12fcf: | |
dx++; | |
if (dx != 0) | |
goto loc_12fd6; | |
if (ax & 0x8000) | |
goto loc_12fd9; | |
loc_12fd6: | |
ax = 0x8000; | |
loc_12fd9: | |
stosw<MemAuto, DirAuto>(); | |
si += 0x0006; | |
memoryASet16(ss, bp - 2- 2, memoryAGet16(ss, bp - 2- 2) - 1); | |
if (memoryAGet16(ss, bp - 2- 2) != 0) | |
goto loc_12f92; | |
ds = pop(); | |
di = pop(); | |
si = pop(); | |
stop(); // leave | |
} | |
void sub_13030() | |
{ | |
push(bp); | |
bp = sp; | |
push(di); | |
push(si); | |
stop(); // les di, ptr [bp + 6] | |
cx = memoryAGet16(ss, bp + 10- 2); | |
bx = memoryAGet16(ss, bp + 12- 2); | |
flags.direction = false; | |
loc_1303f: | |
ax = memoryAGet16(es, di); | |
mul(bx); | |
si = dx; | |
bp = ax; | |
ax = memoryAGet16(es, di + 2); | |
imul(bx); | |
flags.carry = (ax + si) >= 0x10000; | |
ax += si; | |
dx += flags.carry; | |
bp <<= 1; | |
stop(/*carry*/); | |
ax = rcl(ax, 0x0001); | |
stop(/*carry*/); | |
dx = rcl(dx, 0x0001); | |
stop(/*74*/); | |
bp <<= 1; | |
tl = flags.carry; | |
flags.carry = (ax + 0x0000 + tl) >= 0x10000; | |
ax += tl; | |
dx += flags.carry; | |
stosw<MemAuto, DirAuto>(); | |
ax = dx; | |
stosw<MemAuto, DirAuto>(); | |
if (--cx) | |
goto loc_1303f; | |
si = pop(); | |
di = pop(); | |
bp = pop(); | |
} | |
void sub_1354a() | |
{ | |
bx = sp; | |
ax = memoryAGet16(ss, bx + 4); | |
memoryASet16(ds, 0x4b54, ax); | |
memoryASet16(ds, 0x4b5a, ax); | |
ax = memoryAGet16(ss, bx + 6); | |
memoryASet16(ds, 0x4b56, ax); | |
memoryASet(ds, 0x4b58, 0x00); | |
} | |
void sub_13563() | |
{ | |
stop(); // enter 0, 0 | |
bx = memoryAGet16(ds, 0x4b54); | |
cl = memoryAGet(ds, 0x4b58); | |
if (!cl) | |
goto loc_13579; | |
bx--; | |
memoryASet(ds, 0x4b58, 0x00); | |
loc_13579: | |
cx = memoryAGet16(ds, 0x4b5a); | |
ax = memoryAGet16(ss, bp + 6- 2); | |
if (!ax) | |
goto loc_1358d; | |
al = bl; | |
al ^= cl; | |
al &= 0x01; | |
if (al == 0) | |
goto loc_1358d; | |
bx--; | |
loc_1358d: | |
memoryASet16(ds, 0x4b54, bx); | |
ax = cx; | |
ax -= bx; | |
stop(); // leave | |
} | |
void sub_13597() | |
{ | |
push(si); | |
si = sp; | |
push(ds); | |
dx = memoryAGet16(ss, si + 6); | |
bl = dl; | |
cl = memoryAGet(ds, 0x4b58); | |
stop(); // lds si, ptr [0x4b54] | |
sub_135ee(); | |
ds = pop(); | |
memoryASet16(ds, 0x4b54, si); | |
memoryASet(ds, 0x4b58, cl); | |
cl = bl; | |
bx = 0x0001; | |
bx <<= cl; | |
bx--; | |
ax &= bx; | |
si = pop(); | |
} | |
void sub_135c1() | |
{ | |
stop(); // enter 4, 0 | |
push(di); | |
push(si); | |
push(ds); | |
stop(); // les di, ptr [bp + 6] | |
bx = memoryAGet16(ss, bp + 12- 2); | |
flags.direction = false; | |
cl = memoryAGet(ds, 0x4b58); | |
stop(); // lds si, ptr [0x4b54] | |
loc_135d7: | |
dl = memoryAGet(ss, bp + 10- 2); | |
sub_135ee(); | |
stosw<MemAuto, DirAuto>(); | |
bx--; | |
if (bx != 0) | |
goto loc_135d7; | |
ds = pop(); | |
memoryASet16(ds, 0x4b54, si); | |
memoryASet(ds, 0x4b58, cl); | |
si = pop(); | |
di = pop(); | |
stop(); // leave | |
} | |
void sub_135ee() | |
{ | |
dh = dl; | |
dl += cl; | |
ax = memoryAGet16(ds, si + 65535); | |
ax <<= cl; | |
cl = 0x10; | |
cl -= dh; | |
ax = sar(ax, cl); | |
cl = 0x18; | |
cl -= dl; | |
if (cl >= 0x08) | |
goto loc_1360d; | |
dh = memoryAGet(ds, si + 65534); | |
dh >>= cl; | |
al |= dh; | |
loc_1360d: | |
dh = 0x00; | |
cl = 0x07; | |
cl &= dl; | |
dx >>= 3; | |
si -= dx; | |
} | |
void sub_13c90() | |
{ | |
ah = 0x30; | |
interrupt(0x21); | |
if (al >= 0x02) | |
goto loc_13c9d; | |
ax = 0; | |
push(es); | |
push(ax); | |
return; | |
loc_13c9d: | |
di = 0x1adc; | |
si = memoryAGet16(ds, 0x0002); | |
si -= di; | |
if (si < 0x1000) | |
goto loc_13caf; | |
si = 0x1000; | |
loc_13caf: | |
flags.interrupts = false; | |
ss = di; | |
sp += 0x4d8e; | |
flags.interrupts = true; | |
if (stop(/*1*/)) | |
goto loc_13ccb; | |
push(ss); | |
ds = pop(); | |
push(cs); | |
sub_13f18(); | |
ax = 0; | |
push(ax); | |
push(cs); | |
sub_14201(); | |
ax = 0x4cff; | |
interrupt(0x21); | |
loc_13ccb: | |
ax = si; | |
cl = 0x04; | |
ax <<= cl; | |
ax--; | |
memoryASet16(ss, 0x2e68, ax); | |
bx = 0x2e6a; | |
memoryASet16(ss, bx, ss); | |
sp &= 0xfffe; | |
memoryASet16(ss, bx + 4, sp); | |
ax = 0xfffe; | |
push(ax); | |
memoryASet16(ss, bx + 10, sp); | |
ax = ~ax; | |
push(ax); | |
memoryASet16(ss, bx + 6, sp); | |
memoryASet16(ss, bx + 8, sp); | |
memoryASet16(ss, 0x2e64, sp); | |
si += di; | |
memoryASet16(ds, 0x0002, si); | |
bx = es; | |
bx -= si; | |
bx = -bx; | |
ah = 0x4a; | |
interrupt(0x21); | |
memoryASet16(ss, 0x2ea4, ds); | |
push(ss); | |
es = pop(); | |
flags.direction = false; | |
di = 0x3790; | |
cx = 0x4d90; | |
cx -= di; | |
ax = 0; | |
rep_stosb<MemAuto, DirAuto>(); | |
push(ss); | |
ds = pop(); | |
cx = memoryAGet16(ds, 0x34fa); | |
if (cx == 0) | |
goto loc_13d29; | |
callIndirect(cx); | |
loc_13d29: | |
push(cs); | |
sub_14136(); | |
push(cs); | |
sub_13f88(); | |
bp = 0; | |
push(cs); | |
sub_13d90(); | |
push(ss); | |
ds = pop(); | |
push(memoryAGet16(ds, 0x2ec9)); | |
push(memoryAGet16(ds, 0x2ec7)); | |
push(memoryAGet16(ds, 0x2ec5)); | |
push(memoryAGet16(ds, 0x2ec3)); | |
push(memoryAGet16(ds, 0x2ec1)); | |
sub_1292e(); | |
push(ax); | |
push(cs); | |
sub_13e55(); | |
} | |
void sub_13e55() | |
{ | |
push(bp); | |
bp = sp; | |
cx = 0; | |
goto loc_13e76; | |
// gap of 26 bytes | |
loc_13e76: | |
push(cx); | |
if (cl) | |
goto loc_13e99; | |
si = 0x4b8c; | |
di = 0x4b8c; | |
sub_13f05(); | |
si = 0x3524; | |
di = 0x3528; | |
sub_13f05(); | |
if (memoryAGet16(ds, 0x34fc) != 0xd6d6) | |
goto loc_13e99; | |
callIndirect(memoryAGet16(ds, 0x3502)); | |
loc_13e99: | |
si = 0x3528; | |
di = 0x3528; | |
sub_13f05(); | |
si = 0x3528; | |
di = 0x3528; | |
sub_13f05(); | |
push(cs); | |
sub_13f64(); | |
if (!ax) | |
goto loc_13ec5; | |
ax = pop(); | |
push(ax); | |
if (ah) | |
goto loc_13ec5; | |
if (memoryAGet16(ss, bp + 6- 2) != 0x0000) | |
goto loc_13ec5; | |
memoryASet16(ss, bp + 6- 2, 0x00ff); | |
loc_13ec5: | |
sub_13ed8(); | |
ax = pop(); | |
if (ah) | |
goto loc_13ed4; | |
ax = memoryAGet16(ss, bp + 6- 2); | |
ah = 0x4c; | |
interrupt(0x21); | |
loc_13ed4: | |
di = pop(); | |
si = pop(); | |
bp = pop(); | |
} | |
void sub_13ed8() | |
{ | |
cx = memoryAGet16(ds, 0x350e); | |
if (cx == 0) | |
goto loc_13ee5; | |
bx = 0x0002; | |
sub_0(); | |
loc_13ee5: | |
push(ds); | |
stop(); // lds dx, ptr [0x2e90] | |
ax = 0x2500; | |
interrupt(0x21); | |
ds = pop(); | |
if (memoryAGet(ds, 0x2ed2) == 0x00) | |
return; | |
push(ds); | |
al = memoryAGet(ds, 0x2ed3); | |
stop(); // lds dx, ptr [0x2ed4] | |
ah = 0x25; | |
interrupt(0x21); | |
ds = pop(); | |
} | |
void sub_13ed9() | |
{ | |
push(cs); | |
push(cs); | |
ax ^= 0x07e3; | |
bx = 0x0002; | |
sub_0(); | |
push(ds); | |
stop(); // lds dx, ptr [0x2e90] | |
ax = 0x2500; | |
interrupt(0x21); | |
ds = pop(); | |
if (memoryAGet(ds, 0x2ed2) == 0x00) | |
return; | |
push(ds); | |
al = memoryAGet(ds, 0x2ed3); | |
stop(); // lds dx, ptr [0x2ed4] | |
ah = 0x25; | |
interrupt(0x21); | |
ds = pop(); | |
} | |
void sub_13f05() | |
{ | |
loc_13f05: | |
if (si >= di) | |
return; | |
di -= 0x0004; | |
ax = memoryAGet16(ds, di); | |
ax |= memoryAGet16(ds, di + 2); | |
if (!ax) | |
goto loc_13f05; | |
sub_0(); | |
goto loc_13f05; | |
} | |
void sub_13f18() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x00fc; | |
push(ax); | |
push(cs); | |
sub_14201(); | |
if (memoryAGet16(ds, 0x2eda) == 0x0000) | |
goto loc_13f2e; | |
sub_0(); | |
loc_13f2e: | |
ax = 0x00ff; | |
push(ax); | |
push(cs); | |
sub_14201(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_13f40() | |
{ | |
goto loc_13f40; | |
loc_13d6b: | |
push(ax); | |
push(cs); | |
sub_13f18(); | |
push(cs); | |
sub_14201(); | |
if (memoryAGet16(ss, 0x34fc) != 0xd6d6) | |
goto loc_13d84; | |
ax = pop(); | |
push(ax); | |
callIndirect(memoryAGet16(ss, 0x3500)); | |
loc_13d84: | |
ax = 0x00ff; | |
push(ax); | |
push(cs); | |
callIndirect(memoryAGet16(ds, 0x2e66)); | |
stop(); // fcomp qword ptr [bp + si] | |
memoryASet(ds, bx + si + 13568, memoryAGet(ds, bx + si + 13568) + bh); | |
interrupt(0x21); | |
memoryASet16(ds, 0x2e90, bx); | |
memoryASet16(ds, 0x2e92, es); | |
push(cs); | |
ds = pop(); | |
ax = 0x2500; | |
dx = 0x00db; | |
interrupt(0x21); | |
push(ss); | |
ds = pop(); | |
cx = memoryAGet16(ds, 0x350e); | |
if (cx == 0) | |
goto loc_13ddd; | |
es = memoryAGet16(ds, 0x2ea4); | |
si = memoryAGet16(es, 0x002c); | |
stop(); // lds ax, ptr [0x3510] | |
dx = ds; | |
bx = 0; | |
sub_310(); | |
if (stop(/*1*/)) | |
goto loc_13dcc; | |
push(ss); | |
ds = pop(); | |
goto loc_13f3a; | |
loc_13dcc: | |
stop(); // lds ax, ptr ss:[0x3514] | |
dx = ds; | |
bx = 0x0003; | |
sub_310(); | |
push(ss); | |
ds = pop(); | |
loc_13ddd: | |
es = memoryAGet16(ds, 0x2ea4); | |
cx = memoryAGet16(es, 0x002c); | |
if (cx == 0) | |
goto loc_13e26; | |
es = cx; | |
di = 0; | |
loc_13dec: | |
if (memoryAGet(es, di) == 0x00) | |
goto loc_13e26; | |
cx = 0x000d; | |
si = 0x2e82; | |
cmpsb<MemData, MemData, DirAuto>(); | |
if (stop(/*1*/)) | |
goto loc_13e07; | |
cx = 0x7fff; | |
ax = 0; | |
stop(); // repne scasb al, byte ptr es:[di] | |
if (stop(/*1*/)) | |
goto loc_13e26; | |
goto loc_13dec; | |
loc_13e07: | |
push(es); | |
push(ds); | |
es = pop(); | |
ds = pop(); | |
si = di; | |
di = 0x2ead; | |
cl = 0x04; | |
loc_13e12: | |
lodsb<MemAuto, DirAuto>(); | |
flags.carry = al < 0x41; | |
al -= 0x41; | |
if (flags.carry) | |
goto loc_13e24; | |
al <<= cl; | |
tx = ax; | |
ax = dx; | |
dx = tx; | |
lodsb<MemAuto, DirAuto>(); | |
flags.carry = al < 0x41; | |
al -= 0x41; | |
if (flags.carry) | |
goto loc_13e24; | |
al |= dl; | |
stosb<MemAuto, DirAuto>(); | |
goto loc_13e12; | |
loc_13e24: | |
push(ss); | |
ds = pop(); | |
loc_13e26: | |
bx = 0x0004; | |
loc_13e29: | |
memoryASet(ds, bx + 11949, memoryAGet(ds, bx + 11949) & 0xbf); | |
ax = 0x4400; | |
interrupt(0x21); | |
if (flags.carry) | |
goto loc_13e3f; | |
if (!(dl & 0x80)) | |
goto loc_13e3f; | |
memoryASet(ds, bx + 11949, memoryAGet(ds, bx + 11949) | 0x40); | |
loc_13e3f: | |
bx--; | |
if ((short)bx >= 0) | |
goto loc_13e29; | |
si = 0x3518; | |
di = 0x3518; | |
sub_13f05(); | |
si = 0x3518; | |
di = 0x3524; | |
sub_13f05(); | |
return; | |
// gap of 229 bytes | |
loc_13f3a: | |
ax = 0x0002; | |
goto loc_13d6b; | |
loc_13f40: | |
cx = pop(); | |
dx = pop(); | |
bx = sp; | |
flags.carry = bx < ax; | |
bx -= ax; | |
if (flags.carry) | |
goto loc_13f53; | |
if (bx < memoryAGet16(ds, 0x2ee0)) | |
goto loc_13f53; | |
sp = bx; | |
push(dx); | |
push(cx); | |
return; | |
loc_13f53: | |
push(dx); | |
push(cx); | |
ax = memoryAGet16(ds, 0x2edc); | |
ax++; | |
if (ax != 0) | |
goto loc_13f60; | |
ax = 0; | |
goto loc_13d6b; | |
loc_13f60: | |
stop(); // ljmp [0x2edc] | |
push(si); | |
si = 0; | |
cx = 0x0042; | |
ah = 0; | |
flags.direction = false; | |
loc_13f6d: | |
lodsb<MemAuto, DirAuto>(); | |
ah ^= al; | |
if (--cx) | |
goto loc_13f6d; | |
ah ^= 0x55; | |
if (!ah) | |
goto loc_13f86; | |
push(cs); | |
sub_13f18(); | |
ax = 0x0001; | |
push(ax); | |
push(cs); | |
sub_14201(); | |
ax = 0x0001; | |
loc_13f86: | |
si = pop(); | |
} | |
void sub_13f64() | |
{ | |
push(si); | |
si = 0; | |
cx = 0x0042; | |
ah = 0; | |
flags.direction = false; | |
loc_13f6d: | |
lodsb<MemAuto, DirAuto>(); | |
ah ^= al; | |
if (--cx) | |
goto loc_13f6d; | |
ah ^= 0x55; | |
if (!ah) | |
goto loc_13f86; | |
push(cs); | |
sub_13f18(); | |
ax = 0x0001; | |
push(ax); | |
push(cs); | |
sub_14201(); | |
ax = 0x0001; | |
loc_13f86: | |
si = pop(); | |
} | |
void sub_13f88() | |
{ | |
memoryASet16(ds, 0x2ee2, pop()); | |
memoryASet16(ds, 0x2ee4, pop()); | |
ah = 0x30; | |
interrupt(0x21); | |
memoryASet16(ds, 0x2ea6, ax); | |
dx = 0x0001; | |
if (al == 0x02) | |
goto loc_13fc7; | |
es = memoryAGet16(ds, 0x2ea4); | |
es = memoryAGet16(es, 0x002c); | |
memoryASet16(ds, 0x2ecd, es); | |
ax = 0; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
cx = 0x8000; | |
di = 0; | |
loc_13fb3: | |
stop(); // repne scasb al, byte ptr es:[di] | |
flags.zero = memoryAGet(es, di++) == al; | |
if (stop(/*1*/)) | |
goto loc_13fb3; | |
di++; | |
di++; | |
memoryASet16(ds, 0x2ecb, di); | |
cx = 0xffff; | |
stop(); // repne scasb al, byte ptr es:[di] | |
cx = ~cx; | |
dx = cx; | |
loc_13fc7: | |
di = 0x0001; | |
si = 0x0081; | |
ds = memoryAGet16(ds, 0x2ea4); | |
loc_13fd1: | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x20) | |
goto loc_13fd1; | |
if (al == 0x09) | |
goto loc_13fd1; | |
if (al == 0x0d) | |
goto loc_1404d; | |
if (!al) | |
goto loc_1404d; | |
di++; | |
loc_13fe3: | |
si--; | |
loc_13fe4: | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x20) | |
goto loc_13fd1; | |
if (al == 0x09) | |
goto loc_13fd1; | |
if (al == 0x0d) | |
goto loc_1404d; | |
if (!al) | |
goto loc_1404d; | |
if (al == 0x22) | |
goto loc_1401d; | |
if (al == 0x5c) | |
goto loc_14000; | |
dx++; | |
goto loc_13fe4; | |
loc_14000: | |
cx = 0; | |
loc_14002: | |
cx++; | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x5c) | |
goto loc_14002; | |
if (al == 0x22) | |
goto loc_14010; | |
dx += cx; | |
goto loc_13fe3; | |
loc_14010: | |
ax = cx; | |
flags.carry = cx & 1; | |
cx >>= 1; | |
dx += cx + flags.carry; | |
if (al & 0x01) | |
goto loc_13fe4; | |
goto loc_1401d; | |
loc_1401c: | |
si--; | |
loc_1401d: | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x0d) | |
goto loc_1404d; | |
if (!al) | |
goto loc_1404d; | |
if (al == 0x22) | |
goto loc_13fe4; | |
if (al == 0x5c) | |
goto loc_14031; | |
dx++; | |
goto loc_1401d; | |
loc_14031: | |
cx = 0; | |
loc_14033: | |
cx++; | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x5c) | |
goto loc_14033; | |
if (al == 0x22) | |
goto loc_14041; | |
dx += cx; | |
goto loc_1401c; | |
loc_14041: | |
ax = cx; | |
flags.carry = cx & 1; | |
cx >>= 1; | |
dx += cx + flags.carry; | |
if (al & 0x01) | |
goto loc_1401d; | |
goto loc_13fe4; | |
loc_1404d: | |
push(ss); | |
ds = pop(); | |
memoryASet16(ds, 0x2ec1, di); | |
dx += di; | |
di++; | |
di <<= 1; | |
di <<= 1; | |
dx += di; | |
dx++; | |
dl &= 0xfe; | |
sp -= dx; | |
ax = sp; | |
memoryASet16(ds, 0x2ec3, ax); | |
memoryASet16(ds, 0x2ec5, ss); | |
bx = ax; | |
di += bx; | |
push(ss); | |
es = pop(); | |
memoryASet16(ss, bx, di); | |
memoryASet16(ss, bx + 2, ss); | |
bx += 0x0004; | |
stop(); // lds si, ptr [0x2ecb] | |
loc_1407f: | |
lodsb<MemAuto, DirAuto>(); | |
stosb<MemAuto, DirAuto>(); | |
if (al) | |
goto loc_1407f; | |
ds = memoryAGet16(ss, 0x2ea4); | |
si = 0x0081; | |
goto loc_14092; | |
loc_1408f: | |
ax = 0; | |
stosb<MemAuto, DirAuto>(); | |
loc_14092: | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x20) | |
goto loc_14092; | |
if (al == 0x09) | |
goto loc_14092; | |
if (al != 0x0d) | |
goto loc_140a2; | |
goto loc_14126; | |
loc_140a2: | |
if (al) | |
goto loc_140a9; | |
goto loc_14126; | |
// gap of 1 bytes | |
loc_140a9: | |
memoryASet16(ss, bx, di); | |
memoryASet16(ss, bx + 2, ss); | |
bx += 0x0004; | |
loc_140b3: | |
si--; | |
loc_140b4: | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x20) | |
goto loc_1408f; | |
if (al == 0x09) | |
goto loc_1408f; | |
if (al == 0x0d) | |
goto loc_14123; | |
if (!al) | |
goto loc_14123; | |
if (al == 0x22) | |
goto loc_140f0; | |
if (al == 0x5c) | |
goto loc_140d0; | |
stosb<MemAuto, DirAuto>(); | |
goto loc_140b4; | |
loc_140d0: | |
cx = 0; | |
loc_140d2: | |
cx++; | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x5c) | |
goto loc_140d2; | |
if (al == 0x22) | |
goto loc_140e2; | |
al = 0x5c; | |
rep_stosb<MemAuto, DirAuto>(); | |
goto loc_140b3; | |
loc_140e2: | |
al = 0x5c; | |
cx >>= 1; | |
rep_stosb<MemAuto, DirAuto>(); | |
if (stop(/*1*/)) | |
goto loc_140f0; | |
al = 0x22; | |
stosb<MemAuto, DirAuto>(); | |
goto loc_140b4; | |
loc_140ef: | |
si--; | |
loc_140f0: | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x0d) | |
goto loc_14123; | |
if (!al) | |
goto loc_14123; | |
if (al == 0x22) | |
goto loc_140b4; | |
if (al == 0x5c) | |
goto loc_14104; | |
stosb<MemAuto, DirAuto>(); | |
goto loc_140f0; | |
loc_14104: | |
cx = 0; | |
loc_14106: | |
cx++; | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x5c) | |
goto loc_14106; | |
if (al == 0x22) | |
goto loc_14116; | |
al = 0x5c; | |
rep_stosb<MemAuto, DirAuto>(); | |
goto loc_140ef; | |
loc_14116: | |
al = 0x5c; | |
cx >>= 1; | |
rep_stosb<MemAuto, DirAuto>(); | |
if (stop(/*1*/)) | |
goto loc_140b4; | |
al = 0x22; | |
stosb<MemAuto, DirAuto>(); | |
goto loc_140f0; | |
loc_14123: | |
ax = 0; | |
stosb<MemAuto, DirAuto>(); | |
loc_14126: | |
push(ss); | |
ds = pop(); | |
memoryASet16(ds, bx, 0x0000); | |
memoryASet16(ds, bx + 2, 0x0000); | |
stop(); // ljmp [0x2ee2] | |
memoryASet(ds, di + 65419, memoryAGet(ds, di + 65419) + dl); | |
in(al, dx); | |
sp -= 0x0004; | |
push(ds); | |
es = memoryAGet16(ds, 0x2ea4); | |
bx = memoryAGet16(es, 0x002c); | |
es = bx; | |
memoryASet16(ss, bp - 2- 2, es); | |
ax = 0; | |
si = 0; | |
di = 0; | |
cx = 0xffff; | |
if (!bx) | |
goto loc_14166; | |
if (memoryAGet(es, 0x0000) == 0x00) | |
goto loc_14166; | |
loc_14160: | |
stop(); // repne scasb al, byte ptr es:[di] | |
si++; | |
flags.zero = memoryAGet(es, di++) == al; | |
if (stop(/*1*/)) | |
goto loc_14160; | |
loc_14166: | |
ax = di; | |
ax++; | |
al &= 0xfe; | |
si++; | |
di = si; | |
si <<= 1; | |
si <<= 1; | |
cx = 0x0009; | |
sub_14238(); | |
push(dx); | |
push(ax); | |
ax = si; | |
sub_14238(); | |
memoryASet16(ds, 0x2ec7, ax); | |
memoryASet16(ds, 0x2ec9, dx); | |
memoryASet16(ss, bp - 4- 2, dx); | |
push(es); | |
ds = pop(); | |
cx = di; | |
bx = ax; | |
si = 0; | |
di = pop(); | |
es = pop(); | |
cx--; | |
if (cx == 0) | |
goto loc_141c9; | |
loc_14196: | |
ax = memoryAGet16(ds, si); | |
if (ax != memoryAGet16(ss, 0x2e82)) | |
goto loc_141b3; | |
push(cx); | |
push(si); | |
push(di); | |
push(es); | |
push(ss); | |
es = pop(); | |
di = 0x2e82; | |
cx = 0x0006; | |
stop(); // repe cmpsw word ptr [si], word ptr es:[di] | |
es = pop(); | |
di = pop(); | |
si = pop(); | |
cx = pop(); | |
if (stop(/*1*/)) | |
goto loc_141be; | |
loc_141b3: | |
ds = memoryAGet16(ss, bp - 4- 2); | |
memoryASet16(ds, bx, di); | |
memoryASet16(ds, bx + 2, es); | |
bx += 0x0004; | |
loc_141be: | |
ds = memoryAGet16(ss, bp - 2- 2); | |
loc_141c1: | |
lodsb<MemAuto, DirAuto>(); | |
stosb<MemAuto, DirAuto>(); | |
if (al) | |
goto loc_141c1; | |
if (--cx) | |
goto loc_14196; | |
loc_141c9: | |
ds = memoryAGet16(ss, bp - 4- 2); | |
memoryASet16(ds, bx, cx); | |
memoryASet16(ds, bx + 2, cx); | |
ds = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_14136() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0004; | |
push(ds); | |
es = memoryAGet16(ds, 0x2ea4); | |
bx = memoryAGet16(es, 0x002c); | |
es = bx; | |
memoryASet16(ss, bp - 2- 2, es); | |
ax = 0; | |
si = 0; | |
di = 0; | |
cx = 0xffff; | |
if (!bx) | |
goto loc_14166; | |
if (memoryAGet(es, 0x0000) == 0x00) | |
goto loc_14166; | |
loc_14160: | |
stop(); // repne scasb al, byte ptr es:[di] | |
si++; | |
flags.zero = memoryAGet(es, di++) == al; | |
if (stop(/*1*/)) | |
goto loc_14160; | |
loc_14166: | |
ax = di; | |
ax++; | |
al &= 0xfe; | |
si++; | |
di = si; | |
si <<= 1; | |
si <<= 1; | |
cx = 0x0009; | |
sub_14238(); | |
push(dx); | |
push(ax); | |
ax = si; | |
sub_14238(); | |
memoryASet16(ds, 0x2ec7, ax); | |
memoryASet16(ds, 0x2ec9, dx); | |
memoryASet16(ss, bp - 4- 2, dx); | |
push(es); | |
ds = pop(); | |
cx = di; | |
bx = ax; | |
si = 0; | |
di = pop(); | |
es = pop(); | |
cx--; | |
if (cx == 0) | |
goto loc_141c9; | |
loc_14196: | |
ax = memoryAGet16(ds, si); | |
if (ax != memoryAGet16(ss, 0x2e82)) | |
goto loc_141b3; | |
push(cx); | |
push(si); | |
push(di); | |
push(es); | |
push(ss); | |
es = pop(); | |
di = 0x2e82; | |
cx = 0x0006; | |
stop(); // repe cmpsw word ptr [si], word ptr es:[di] | |
es = pop(); | |
di = pop(); | |
si = pop(); | |
cx = pop(); | |
if (stop(/*1*/)) | |
goto loc_141be; | |
loc_141b3: | |
ds = memoryAGet16(ss, bp - 4- 2); | |
memoryASet16(ds, bx, di); | |
memoryASet16(ds, bx + 2, es); | |
bx += 0x0004; | |
loc_141be: | |
ds = memoryAGet16(ss, bp - 2- 2); | |
loc_141c1: | |
lodsb<MemAuto, DirAuto>(); | |
stosb<MemAuto, DirAuto>(); | |
if (al) | |
goto loc_141c1; | |
if (--cx) | |
goto loc_14196; | |
loc_141c9: | |
ds = memoryAGet16(ss, bp - 4- 2); | |
memoryASet16(ds, bx, cx); | |
memoryASet16(ds, bx + 2, cx); | |
ds = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_141d6() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
push(di); | |
push(ds); | |
es = pop(); | |
dx = memoryAGet16(ss, bp + 6- 2); | |
si = 0x35b0; | |
loc_141e3: | |
lodsw<MemAuto, DirAuto>(); | |
if (ax == dx) | |
goto loc_141f8; | |
ax++; | |
tx = ax; | |
ax = si; | |
si = tx; | |
if (stop(/*1*/)) | |
goto loc_141f8; | |
tx = ax; | |
ax = di; | |
di = tx; | |
ax = 0; | |
cx = 0xffff; | |
stop(); // repne scasb al, byte ptr es:[di] | |
si = di; | |
goto loc_141e3; | |
loc_141f8: | |
tx = ax; | |
ax = si; | |
si = tx; | |
di = pop(); | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
sp += 2; | |
} | |
void sub_14201() | |
{ | |
push(bp); | |
bp = sp; | |
push(di); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_141d6(); | |
if (!ax) | |
goto loc_14230; | |
tx = ax; | |
ax = dx; | |
dx = tx; | |
di = dx; | |
ax = 0; | |
cx = 0xffff; | |
stop(); // repne scasb al, byte ptr es:[di] | |
cx = ~cx; | |
cx--; | |
bx = 0x0002; | |
if (memoryAGet16(ds, 0x34fc) != 0xd6d6) | |
goto loc_1422c; | |
callIndirect(memoryAGet16(ds, 0x34fe)); | |
loc_1422c: | |
ah = 0x40; | |
interrupt(0x21); | |
loc_14230: | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
sp += 2; | |
} | |
void sub_14238() | |
{ | |
goto loc_14238; | |
loc_13d6b: | |
push(ax); | |
push(cs); | |
sub_13f18(); | |
push(cs); | |
sub_14201(); | |
if (memoryAGet16(ss, 0x34fc) != 0xd6d6) | |
goto loc_13d84; | |
ax = pop(); | |
push(ax); | |
callIndirect(memoryAGet16(ss, 0x3500)); | |
loc_13d84: | |
ax = 0x00ff; | |
push(ax); | |
push(cs); | |
callIndirect(memoryAGet16(ds, 0x2e66)); | |
stop(); // fcomp qword ptr [bp + si] | |
memoryASet(ds, bx + si + 13568, memoryAGet(ds, bx + si + 13568) + bh); | |
interrupt(0x21); | |
memoryASet16(ds, 0x2e90, bx); | |
memoryASet16(ds, 0x2e92, es); | |
push(cs); | |
ds = pop(); | |
ax = 0x2500; | |
dx = 0x00db; | |
interrupt(0x21); | |
push(ss); | |
ds = pop(); | |
cx = memoryAGet16(ds, 0x350e); | |
if (cx == 0) | |
goto loc_13ddd; | |
es = memoryAGet16(ds, 0x2ea4); | |
si = memoryAGet16(es, 0x002c); | |
stop(); // lds ax, ptr [0x3510] | |
dx = ds; | |
bx = 0; | |
sub_310(); | |
if (stop(/*1*/)) | |
goto loc_13dcc; | |
push(ss); | |
ds = pop(); | |
goto loc_13f3a; | |
loc_13dcc: | |
stop(); // lds ax, ptr ss:[0x3514] | |
dx = ds; | |
bx = 0x0003; | |
sub_310(); | |
push(ss); | |
ds = pop(); | |
loc_13ddd: | |
es = memoryAGet16(ds, 0x2ea4); | |
cx = memoryAGet16(es, 0x002c); | |
if (cx == 0) | |
goto loc_13e26; | |
es = cx; | |
di = 0; | |
loc_13dec: | |
if (memoryAGet(es, di) == 0x00) | |
goto loc_13e26; | |
cx = 0x000d; | |
si = 0x2e82; | |
cmpsb<MemData, MemData, DirAuto>(); | |
if (stop(/*1*/)) | |
goto loc_13e07; | |
cx = 0x7fff; | |
ax = 0; | |
stop(); // repne scasb al, byte ptr es:[di] | |
if (stop(/*1*/)) | |
goto loc_13e26; | |
goto loc_13dec; | |
loc_13e07: | |
push(es); | |
push(ds); | |
es = pop(); | |
ds = pop(); | |
si = di; | |
di = 0x2ead; | |
cl = 0x04; | |
loc_13e12: | |
lodsb<MemAuto, DirAuto>(); | |
flags.carry = al < 0x41; | |
al -= 0x41; | |
if (flags.carry) | |
goto loc_13e24; | |
al <<= cl; | |
tx = ax; | |
ax = dx; | |
dx = tx; | |
lodsb<MemAuto, DirAuto>(); | |
flags.carry = al < 0x41; | |
al -= 0x41; | |
if (flags.carry) | |
goto loc_13e24; | |
al |= dl; | |
stosb<MemAuto, DirAuto>(); | |
goto loc_13e12; | |
loc_13e24: | |
push(ss); | |
ds = pop(); | |
loc_13e26: | |
bx = 0x0004; | |
loc_13e29: | |
memoryASet(ds, bx + 11949, memoryAGet(ds, bx + 11949) & 0xbf); | |
ax = 0x4400; | |
interrupt(0x21); | |
if (flags.carry) | |
goto loc_13e3f; | |
if (!(dl & 0x80)) | |
goto loc_13e3f; | |
memoryASet(ds, bx + 11949, memoryAGet(ds, bx + 11949) | 0x40); | |
loc_13e3f: | |
bx--; | |
if ((short)bx >= 0) | |
goto loc_13e29; | |
si = 0x3518; | |
di = 0x3518; | |
sub_13f05(); | |
si = 0x3518; | |
di = 0x3524; | |
sub_13f05(); | |
return; | |
// gap of 229 bytes | |
loc_13f3a: | |
ax = 0x0002; | |
goto loc_13d6b; | |
// gap of 760 bytes | |
loc_14238: | |
push(bx); | |
push(es); | |
push(cx); | |
cx = 0x0400; | |
tx = memoryAGet16(ds, 0x3162); | |
memoryASet16(ds, 0x3162, cx); | |
cx = tx; | |
push(cx); | |
push(ax); | |
push(cs); | |
sub_1561a(); | |
bx = pop(); | |
memoryASet16(ds, 0x3162, pop()); | |
cx = pop(); | |
bx = dx; | |
bx |= ax; | |
if (!bx) | |
goto loc_14258; | |
es = pop(); | |
bx = pop(); | |
return; | |
loc_14258: | |
ax = cx; | |
goto loc_13d6b; | |
} | |
void sub_14286() | |
{ | |
memoryASet(ds, 0x2ea9, al); | |
if (ah) | |
goto loc_142af; | |
if (memoryAGet(ds, 0x2ea6) < 0x03) | |
goto loc_142a0; | |
if (al >= 0x22) | |
goto loc_142a4; | |
if (al < 0x20) | |
goto loc_142a0; | |
al = 0x05; | |
goto loc_142a6; | |
loc_142a0: | |
if (al <= 0x13) | |
goto loc_142a6; | |
loc_142a4: | |
al = 0x13; | |
loc_142a6: | |
bx = 0x2ee6; | |
al = memory(ds, bx+al); | |
loc_142aa: | |
cbw(); | |
memoryASet16(ds, 0x2e9e, ax); | |
return; | |
loc_142af: | |
al = ah; | |
goto loc_142aa; | |
} | |
void sub_142b4() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0010; | |
push(di); | |
push(si); | |
di = 0xffff; | |
si = memoryAGet16(ss, bp + 6- 2); | |
if (!(memoryAGet(ds, si + 10) & 0x40)) | |
goto loc_142cb; | |
goto loc_1436e; | |
loc_142cb: | |
if (memoryAGet(ds, si + 10) & 0x83) | |
goto loc_142d4; | |
goto loc_1436e; | |
loc_142d4: | |
push(ds); | |
push(si); | |
push(cs); | |
sub_14b26(); | |
sp += 0x0004; | |
di = ax; | |
bx = si; | |
bx -= 0x2f00; | |
ax = memoryAGet16(ds, bx + 12276); | |
memoryASet16(ss, bp - 6- 2, ax); | |
push(ds); | |
push(si); | |
sub_148e0(); | |
sp += 0x0004; | |
al = memoryAGet(ds, si + 11); | |
ah = 0; | |
push(ax); | |
push(cs); | |
sub_15142(); | |
sp += 0x0002; | |
if (stop(/*condition!*/)) | |
goto loc_1436b; | |
if (memoryAGet16(ss, bp - 6- 2) == 0x0000) | |
goto loc_1436e; | |
ax = 0x2efa; | |
push(ds); | |
push(ax); | |
stop(); // lea ax, [bp - 0x10] | |
push(ss); | |
push(ax); | |
push(cs); | |
sub_15926(); | |
sp += 0x0008; | |
stop(); // lea ax, [bp - 0xe] | |
memoryASet16(ss, bp - 4- 2, ax); | |
memoryASet16(ss, bp - 2- 2, ss); | |
if (memoryAGet(ss, bp - 16- 2) == 0x5c) | |
goto loc_14342; | |
ax = 0x2efc; | |
push(ds); | |
push(ax); | |
stop(); // lea ax, [bp - 0x10] | |
push(ss); | |
push(ax); | |
push(cs); | |
sub_158e0(); | |
sp += 0x0008; | |
goto loc_14345; | |
loc_14342: | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) - 1); | |
loc_14345: | |
ax = 0x000a; | |
push(ax); | |
push(memoryAGet16(ss, bp - 2- 2)); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
push(memoryAGet16(ss, bp - 6- 2)); | |
push(cs); | |
sub_15a2a(); | |
sp += 0x0008; | |
stop(); // lea ax, [bp - 0x10] | |
push(ss); | |
push(ax); | |
push(cs); | |
sub_161f6(); | |
sp += 0x0004; | |
if (!ax) | |
goto loc_1436e; | |
loc_1436b: | |
di = 0xffff; | |
loc_1436e: | |
memoryASet(ds, si + 10, 0x00); | |
ax = di; | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_1437a() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0008; | |
push(cs); | |
sub_150f4(); | |
memoryASet16(ss, bp - 2- 2, dx); | |
dx |= ax; | |
if (dx) | |
goto loc_14392; | |
ax = 0; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
goto loc_143aa; | |
// gap of 1 bytes | |
loc_14392: | |
push(memoryAGet16(ss, bp - 2- 2)); | |
push(ax); | |
push(memoryAGet16(ss, bp + 14- 2)); | |
push(memoryAGet16(ss, bp + 12- 2)); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_14964(); | |
loc_143aa: | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_143ae() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0; | |
push(ax); | |
push(memoryAGet16(ss, bp + 12- 2)); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_1437a(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_143ca() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0006; | |
push(di); | |
push(si); | |
si = memoryAGet16(ss, bp + 6- 2); | |
push(ds); | |
push(si); | |
sub_14a5c(); | |
sp += 0x0004; | |
di = ax; | |
stop(); // lea ax, [bp + 0xe] | |
push(ss); | |
push(ax); | |
push(memoryAGet16(ss, bp + 12- 2)); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(ds); | |
push(si); | |
push(cs); | |
sub_14c0a(); | |
sp += 0x000c; | |
memoryASet16(ss, bp - 6- 2, ax); | |
push(ds); | |
push(si); | |
push(di); | |
sub_14add(); | |
sp += 0x0006; | |
ax = memoryAGet16(ss, bp - 6- 2); | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_1457c() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0004; | |
push(si); | |
push(di); | |
ax = memoryAGet16(ss, bp + 10- 2); | |
mul(memoryAGet16(ss, bp + 12- 2)); | |
cx = ax; | |
cx |= dx; | |
if (!cx) | |
goto loc_145f1; | |
memoryASet16(ss, bp - 4- 2, ax); | |
memoryASet16(ss, bp - 2- 2, dx); | |
stop(); // les bx, ptr [bp + 6] | |
si = memoryAGet16(ss, bp + 14- 2); | |
loc_1459c: | |
if (dx) | |
goto loc_145bf; | |
if (ax == 0xffff) | |
goto loc_145bf; | |
cx = bx; | |
flags.carry = (cx + ax) >= 0x10000; | |
cx += ax; | |
if (flags.carry) | |
goto loc_145bf; | |
push(ax); | |
push(bx); | |
push(dx); | |
cx = ax; | |
sub_1461d(); | |
cx = ax; | |
dx = pop(); | |
bx = pop(); | |
ax = pop(); | |
flags.carry = ax < cx; | |
ax -= cx; | |
dx -= flags.carry; | |
goto loc_145fb; | |
loc_145bf: | |
if (bx > 0x0001) | |
goto loc_145c9; | |
cx = 0x8000; | |
goto loc_145cd; | |
loc_145c9: | |
cx = bx; | |
cx = -cx; | |
loc_145cd: | |
push(cx); | |
push(ax); | |
push(bx); | |
push(dx); | |
sub_1461d(); | |
cx = ax; | |
dx = pop(); | |
bx = pop(); | |
ax = pop(); | |
di = pop(); | |
flags.carry = ax < cx; | |
ax -= cx; | |
dx -= flags.carry; | |
if (cx < di) | |
goto loc_145fb; | |
flags.carry = (bx + cx) >= 0x10000; | |
bx += cx; | |
if (!flags.carry) | |
goto loc_145f3; | |
cx = es; | |
cx += 0x1000; | |
es = cx; | |
goto loc_145f3; | |
loc_145f1: | |
goto loc_14617; | |
loc_145f3: | |
cx = ax; | |
cx |= dx; | |
if (cx) | |
goto loc_1459c; | |
loc_145fb: | |
cx = ax; | |
cx |= dx; | |
if (!cx) | |
goto loc_14614; | |
cx = memoryAGet16(ss, bp - 4- 2); | |
cx -= ax; | |
ax = cx; | |
cx = memoryAGet16(ss, bp - 2- 2); | |
stop(/*PROBLEM-11g*/); | |
dx = cx; | |
div(memory16(ss, bp + 10- 2)); | |
goto loc_14617; | |
loc_14614: | |
ax = memoryAGet16(ss, bp + 12- 2); | |
loc_14617: | |
di = pop(); | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_1461d() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0004; | |
memoryASet16(ss, bp - 2- 2, cx); | |
di = 0x2ff0; | |
ax = si; | |
ax -= 0x2f00; | |
di += ax; | |
if (memoryAGet(ds, si + 10) & 0x0c) | |
goto loc_1463b; | |
if (!(memoryAGet(ds, di) & 0x01)) | |
goto loc_14640; | |
loc_1463b: | |
ax = memoryAGet16(ds, di + 2); | |
goto loc_14643; | |
loc_14640: | |
ax = 0x0200; | |
loc_14643: | |
memoryASet16(ss, bp - 4- 2, ax); | |
loc_14646: | |
if (memoryAGet(ds, si + 10) & 0x08) | |
goto loc_14651; | |
if (!(memoryAGet(ds, di) & 0x01)) | |
goto loc_14687; | |
loc_14651: | |
ax = memoryAGet16(ds, si + 4); | |
if (!ax) | |
goto loc_14687; | |
if (ax <= cx) | |
goto loc_1465e; | |
ax = cx; | |
loc_1465e: | |
push(ax); | |
push(bx); | |
push(cx); | |
push(es); | |
push(ax); | |
push(es); | |
push(bx); | |
push(memoryAGet16(ds, si + 2)); | |
push(memoryAGet16(ds, si)); | |
push(cs); | |
sub_15f5c(); | |
sp += 0x000a; | |
es = pop(); | |
cx = pop(); | |
bx = pop(); | |
ax = pop(); | |
cx -= ax; | |
memoryASet16(ds, si + 4, memoryAGet16(ds, si + 4) - ax); | |
bx += ax; | |
memoryASet16(ds, si, memoryAGet16(ds, si) + ax); | |
loc_14680: | |
if (cx) | |
goto loc_14646; | |
goto loc_1470a; | |
loc_14687: | |
if (cx < memoryAGet16(ss, bp - 4- 2)) | |
goto loc_146dc; | |
if (memoryAGet(ds, si + 10) & 0x08) | |
goto loc_14697; | |
if (!(memoryAGet(ds, di) & 0x01)) | |
goto loc_146aa; | |
loc_14697: | |
push(bx); | |
push(cx); | |
push(es); | |
push(ds); | |
push(si); | |
push(cs); | |
sub_14b26(); | |
sp += 0x0004; | |
es = pop(); | |
cx = pop(); | |
bx = pop(); | |
if (ax) | |
goto loc_1470a; | |
loc_146aa: | |
dx = 0; | |
ax = cx; | |
div(memory16(ss, bp - 4- 2)); | |
ax = cx; | |
ax -= dx; | |
push(ax); | |
push(bx); | |
push(cx); | |
push(es); | |
push(ax); | |
push(es); | |
push(bx); | |
ax = 0; | |
al = memoryAGet(ds, si + 11); | |
push(ax); | |
push(cs); | |
sub_154a6(); | |
sp += 0x0008; | |
es = pop(); | |
cx = pop(); | |
bx = pop(); | |
dx = pop(); | |
if (ax == 0xffff) | |
goto loc_14706; | |
cx -= ax; | |
if (ax != dx) | |
goto loc_14706; | |
bx += ax; | |
goto loc_14680; | |
loc_146dc: | |
ax = 0; | |
al = memoryAGet(es, bx); | |
push(bx); | |
push(cx); | |
push(es); | |
push(ds); | |
push(si); | |
push(ax); | |
push(cs); | |
sub_147f4(); | |
sp += 0x0006; | |
es = pop(); | |
cx = pop(); | |
bx = pop(); | |
if (ax == 0xffff) | |
goto loc_1470a; | |
bx++; | |
cx--; | |
ax = memoryAGet16(ds, di + 2); | |
if (ax) | |
goto loc_14700; | |
ax++; | |
loc_14700: | |
memoryASet16(ss, bp - 4- 2, ax); | |
goto loc_14680; | |
loc_14706: | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) | 0x20); | |
loc_1470a: | |
ax = memoryAGet16(ss, bp - 2- 2); | |
ax -= cx; | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_14714() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0006; | |
push(di); | |
ax = 0x2f0c; | |
push(ds); | |
push(ax); | |
sub_14a5c(); | |
sp += 0x0004; | |
di = ax; | |
stop(); // lea ax, [bp + 0xa] | |
push(ss); | |
push(ax); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
ax = 0x2f0c; | |
push(ds); | |
push(ax); | |
push(cs); | |
sub_14c0a(); | |
sp += 0x000c; | |
memoryASet16(ss, bp - 6- 2, ax); | |
ax = 0x2f0c; | |
push(ds); | |
push(ax); | |
push(di); | |
sub_14add(); | |
sp += 0x0006; | |
ax = memoryAGet16(ss, bp - 6- 2); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_14758() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
push(di); | |
si = memoryAGet16(ss, bp + 6- 2); | |
al = memoryAGet(ds, si + 10); | |
if (!(al & 0x83)) | |
goto loc_147c6; | |
if (al & 0x40) | |
goto loc_147c6; | |
if (al & 0x02) | |
goto loc_147b7; | |
al |= 0x01; | |
memoryASet(ds, si + 10, al); | |
di = si; | |
di -= 0x2f00; | |
di += 0x2ff0; | |
if (al & 0x0c) | |
goto loc_1478f; | |
if (memoryAGet(ds, di) & 0x01) | |
goto loc_1478f; | |
push(ds); | |
push(si); | |
sub_14918(); | |
sp += 0x0004; | |
loc_1478f: | |
ax = memoryAGet16(ds, si + 6); | |
memoryASet16(ds, si, ax); | |
push(memoryAGet16(ds, di + 2)); | |
push(memoryAGet16(ds, si + 8)); | |
push(ax); | |
bx = 0; | |
bl = memoryAGet(ds, si + 11); | |
push(bx); | |
push(cs); | |
sub_153a8(); | |
sp += 0x0008; | |
if (!ax) | |
goto loc_147bd; | |
if (ax != 0xffff) | |
goto loc_147cb; | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) | 0x20); | |
goto loc_147c1; | |
loc_147b7: | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) | 0x20); | |
goto loc_147c6; | |
loc_147bd: | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) | 0x10); | |
loc_147c1: | |
memoryASet16(ds, si + 4, 0x0000); | |
loc_147c6: | |
ax = 0xffff; | |
goto loc_147f0; | |
loc_147cb: | |
bh = memoryAGet(ds, bx + 11949); | |
bh &= 0x82; | |
if (bh != 0x82) | |
goto loc_147e2; | |
bh = memoryAGet(ds, si + 10); | |
if (bh & 0x82) | |
goto loc_147e2; | |
memoryASet(ds, di, memoryAGet(ds, di) | 0x20); | |
loc_147e2: | |
ax--; | |
memoryASet16(ds, si + 4, ax); | |
stop(); // les bx, ptr [si] | |
ax = 0; | |
al = memoryAGet(es, bx); | |
bx++; | |
memoryASet16(ds, si, bx); | |
loc_147f0: | |
di = pop(); | |
si = pop(); | |
bp = pop(); | |
} | |
void sub_147f4() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
push(di); | |
si = memoryAGet16(ss, bp + 8- 2); | |
al = memoryAGet(ds, si + 10); | |
if (!(al & 0x82)) | |
goto loc_1486d; | |
if (al & 0x40) | |
goto loc_1486d; | |
memoryASet16(ds, si + 4, 0x0000); | |
if (!(al & 0x01)) | |
goto loc_1481b; | |
if (!(al & 0x10)) | |
goto loc_1486d; | |
cx = memoryAGet16(ds, si + 6); | |
memoryASet16(ds, si, cx); | |
al &= 0xfe; | |
loc_1481b: | |
al |= 0x02; | |
al &= 0xef; | |
memoryASet(ds, si + 10, al); | |
di = si; | |
di -= 0x2f00; | |
di += 0x2ff0; | |
bx = 0; | |
bl = memoryAGet(ds, si + 11); | |
if (al & 0x08) | |
goto loc_14886; | |
if (al & 0x04) | |
goto loc_14857; | |
if (memoryAGet(ds, di) & 0x01) | |
goto loc_14886; | |
if (si == 0x2f0c) | |
goto loc_14850; | |
if (si == 0x2f18) | |
goto loc_14850; | |
if (si != 0x2f30) | |
goto loc_14876; | |
loc_14850: | |
if (!(memoryAGet(ds, bx + 11949) & 0x40)) | |
goto loc_14876; | |
loc_14857: | |
cx = 0x0001; | |
push(cx); | |
push(ss); | |
stop(); // lea di, [bp + 6] | |
push(di); | |
push(bx); | |
push(cs); | |
sub_154a6(); | |
sp += 0x0008; | |
cx = 0x0001; | |
goto loc_148b3; | |
loc_1486d: | |
ax = 0xffff; | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) | 0x20); | |
goto loc_148db; | |
loc_14876: | |
push(bx); | |
push(ds); | |
push(si); | |
sub_14918(); | |
sp += 0x0004; | |
bx = pop(); | |
if (!(memoryAGet(ds, si + 10) & 0x08)) | |
goto loc_14857; | |
loc_14886: | |
cx = memoryAGet16(ds, si); | |
dx = memoryAGet16(ds, si + 6); | |
cx -= dx; | |
dx++; | |
memoryASet16(ds, si, dx); | |
dx = memoryAGet16(ds, di + 2); | |
dx--; | |
memoryASet16(ds, si + 4, dx); | |
if (cx == 0) | |
goto loc_148be; | |
push(cx); | |
push(cx); | |
push(memoryAGet16(ds, si + 8)); | |
push(memoryAGet16(ds, si + 6)); | |
push(bx); | |
push(cs); | |
sub_154a6(); | |
sp += 0x0008; | |
cx = pop(); | |
loc_148aa: | |
stop(); // les di, ptr [si + 6] | |
dx = memoryAGet16(ss, bp + 6- 2); | |
memoryASet(es, di, dl); | |
loc_148b3: | |
if (ax != cx) | |
goto loc_1486d; | |
ax = 0; | |
al = memoryAGet(ss, bp + 6- 2); | |
goto loc_148db; | |
loc_148be: | |
ax = 0; | |
if (!(memoryAGet(ds, bx + 11949) & 0x20)) | |
goto loc_148aa; | |
cx = 0x0002; | |
push(cx); | |
push(ax); | |
push(ax); | |
push(bx); | |
push(cs); | |
sub_15162(); | |
sp += 0x0008; | |
ax = 0; | |
cx = ax; | |
goto loc_148aa; | |
loc_148db: | |
di = pop(); | |
si = pop(); | |
bp = pop(); | |
} | |
void sub_148e0() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
si = memoryAGet16(ss, bp + 4- 2); | |
al = memoryAGet(ds, si + 10); | |
if (!(al & 0x83)) | |
goto loc_14914; | |
if (!(al & 0x08)) | |
goto loc_14914; | |
push(memoryAGet16(ds, si + 8)); | |
push(memoryAGet16(ds, si + 6)); | |
push(cs); | |
sub_15620(); | |
sp += 0x0004; | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) & 0xf7); | |
ax = 0; | |
memoryASet16(ds, si + 6, ax); | |
memoryASet16(ds, si + 8, ax); | |
memoryASet16(ds, si, ax); | |
memoryASet16(ds, si + 2, ax); | |
memoryASet16(ds, si + 4, ax); | |
loc_14914: | |
si = pop(); | |
bp = pop(); | |
} | |
void sub_14918() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
si = memoryAGet16(ss, bp + 4- 2); | |
ax = 0x0200; | |
push(ax); | |
push(cs); | |
sub_1561a(); | |
cx = pop(); | |
bx = si; | |
bx -= 0x2f00; | |
bx += 0x2ff0; | |
if (!dx) | |
goto loc_14942; | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) | 0x08); | |
memoryASet16(ds, bx + 2, 0x0200); | |
goto loc_14950; | |
loc_14942: | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) | 0x04); | |
memoryASet16(ds, bx + 2, 0x0001); | |
dx = ds; | |
stop(); // lea ax, [bx + 1] | |
loc_14950: | |
memoryASet16(ds, si + 2, dx); | |
memoryASet16(ds, si, ax); | |
memoryASet16(ds, si + 8, dx); | |
memoryASet16(ds, si + 6, ax); | |
memoryASet16(ds, si + 4, 0x0000); | |
si = pop(); | |
bp = pop(); | |
} | |
void sub_14964() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0008; | |
push(di); | |
push(si); | |
stop(); // les bx, ptr [bp + 0xa] | |
al = memoryAGet(es, bx); | |
cbw(); | |
if (ax == 0x0077) | |
goto loc_149c0; | |
if (ax > 0x0077) | |
goto loc_14982; | |
al -= 0x61; | |
if (al == 0) | |
goto loc_149ca; | |
al -= 0x11; | |
if (al == 0) | |
goto loc_14988; | |
loc_14982: | |
ax = 0; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
goto loc_14a55; | |
loc_14988: | |
si = 0; | |
memoryASet(ss, bp - 4- 2, 0x01); | |
loc_1498e: | |
memoryASet16(ss, bp - 2- 2, 0x0001); | |
loc_14993: | |
memoryASet16(ss, bp + 10- 2, memoryAGet16(ss, bp + 10- 2) + 1); | |
stop(); // les bx, ptr [bp + 0xa] | |
if (memoryAGet(es, bx) == 0x00) | |
goto loc_149fa; | |
if (memoryAGet16(ss, bp - 2- 2) == 0x0000) | |
goto loc_149fa; | |
al = memoryAGet(es, bx); | |
cbw(); | |
if (ax == 0x0074) | |
goto loc_149e2; | |
if (ax > 0x0074) | |
goto loc_149b8; | |
al -= 0x2b; | |
if (al == 0) | |
goto loc_149d0; | |
al -= 0x37; | |
if (al == 0) | |
goto loc_149ee; | |
loc_149b8: | |
memoryASet16(ss, bp - 2- 2, 0x0000); | |
goto loc_14993; | |
// gap of 1 bytes | |
loc_149c0: | |
si = 0x0301; | |
loc_149c3: | |
memoryASet(ss, bp - 4- 2, 0x02); | |
goto loc_1498e; | |
// gap of 1 bytes | |
loc_149ca: | |
si = 0x0109; | |
goto loc_149c3; | |
// gap of 1 bytes | |
loc_149d0: | |
if (si & 0x0002) | |
goto loc_149b8; | |
si |= 0x0002; | |
si &= 0xfffe; | |
memoryASet(ss, bp - 4- 2, 0x80); | |
goto loc_14993; | |
loc_149e2: | |
if (si & 0xc000) | |
goto loc_149b8; | |
si |= 0x4000; | |
goto loc_14993; | |
loc_149ee: | |
if (si & 0xc000) | |
goto loc_149b8; | |
si |= 0x8000; | |
goto loc_14993; | |
loc_149fa: | |
ax = 0x01a4; | |
push(ax); | |
push(memoryAGet16(ss, bp + 14- 2)); | |
push(si); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_151dc(); | |
sp += 0x000a; | |
memoryASet16(ss, bp - 6- 2, ax); | |
if (stop(/*condition!*/)) | |
goto loc_14a1a; | |
goto loc_14982; | |
loc_14a1a: | |
memoryASet16(ds, 0x2efe, memoryAGet16(ds, 0x2efe) + 1); | |
di = memoryAGet16(ss, bp + 16- 2); | |
ax = di; | |
ax -= 0x2f00; | |
ax += 0x2ff0; | |
memoryASet16(ss, bp - 8- 2, ax); | |
al = memoryAGet(ss, bp - 4- 2); | |
memoryASet(ds, di + 10, al); | |
bx = memoryAGet16(ss, bp - 8- 2); | |
memoryASet(ds, bx, 0x00); | |
ax = 0; | |
memoryASet16(ds, di + 4, ax); | |
memoryASet16(ds, bx + 4, ax); | |
memoryASet16(ds, di + 2, ax); | |
memoryASet16(ds, di, ax); | |
memoryASet16(ds, di + 8, ax); | |
memoryASet16(ds, di + 6, ax); | |
al = memoryAGet(ss, bp - 6- 2); | |
memoryASet(ds, di + 11, al); | |
ax = di; | |
dx = ds; | |
loc_14a55: | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_14a5c() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
push(di); | |
si = memoryAGet16(ss, bp + 4- 2); | |
bx = 0x30e4; | |
if (si == 0x2f0c) | |
goto loc_14a7f; | |
bx = 0x30e8; | |
if (si == 0x2f18) | |
goto loc_14a7f; | |
bx = 0x30ec; | |
if (si != 0x2f30) | |
goto loc_14ad7; | |
loc_14a7f: | |
di = si; | |
di -= 0x2f00; | |
di += 0x2ff0; | |
if (memoryAGet(ds, si + 10) & 0x0c) | |
goto loc_14ad7; | |
if (memoryAGet(ds, di) & 0x01) | |
goto loc_14ad7; | |
ax = memoryAGet16(ds, bx); | |
dx = memoryAGet16(ds, bx + 2); | |
cx = ax; | |
cx |= dx; | |
if (!cx) | |
goto loc_14ac0; | |
loc_14a9f: | |
memoryASet16(ds, si + 6, ax); | |
memoryASet16(ds, si + 8, dx); | |
memoryASet16(ds, si, ax); | |
memoryASet16(ds, si + 2, dx); | |
memoryASet16(ds, si + 4, 0x0200); | |
memoryASet16(ds, di + 2, 0x0200); | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) | 0x02); | |
memoryASet(ds, di, 0x11); | |
ax = 0x0001; | |
goto loc_14ad9; | |
loc_14ac0: | |
push(bx); | |
ax = 0x0200; | |
push(ax); | |
push(cs); | |
sub_1561a(); | |
bx = pop(); | |
bx = pop(); | |
if (!dx) | |
goto loc_14ad7; | |
memoryASet16(ds, bx, ax); | |
memoryASet16(ds, bx + 2, dx); | |
goto loc_14a9f; | |
loc_14ad7: | |
ax = 0; | |
loc_14ad9: | |
di = pop(); | |
si = pop(); | |
bp = pop(); | |
} | |
void sub_14add() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
push(di); | |
si = memoryAGet16(ss, bp + 6- 2); | |
di = si; | |
di -= 0x2f00; | |
di += 0x2ff0; | |
if (!(memoryAGet(ds, di) & 0x10)) | |
goto loc_14b21; | |
bx = 0; | |
bl = memoryAGet(ds, si + 11); | |
if (!(memoryAGet(ds, bx + 11949) & 0x40)) | |
goto loc_14b21; | |
push(ds); | |
push(si); | |
push(cs); | |
sub_14b26(); | |
sp += 0x0004; | |
if (memoryAGet16(ss, bp + 4- 2) == 0x0000) | |
goto loc_14b21; | |
ax = 0; | |
memoryASet(ds, di, al); | |
memoryASet16(ds, di + 2, ax); | |
memoryASet16(ds, si, ax); | |
memoryASet16(ds, si + 2, ax); | |
memoryASet16(ds, si + 6, ax); | |
memoryASet16(ds, si + 8, ax); | |
loc_14b21: | |
di = pop(); | |
si = pop(); | |
bp = pop(); | |
} | |
void sub_14b26() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0002; | |
push(di); | |
push(si); | |
di = 0; | |
ax = memoryAGet16(ss, bp + 8- 2); | |
ax |= memoryAGet16(ss, bp + 6- 2); | |
if (ax) | |
goto loc_14b40; | |
ax = 0; | |
push(ax); | |
sub_14bae(); | |
goto loc_14b9f; | |
loc_14b40: | |
si = memoryAGet16(ss, bp + 6- 2); | |
al = memoryAGet(ds, si + 10); | |
cx = ax; | |
al &= 0x03; | |
if (al != 0x02) | |
goto loc_14b8d; | |
if (cl & 0x08) | |
goto loc_14b60; | |
bx = si; | |
bx -= 0x2f00; | |
if (!(memoryAGet(ds, bx + 12272) & 0x01)) | |
goto loc_14b8d; | |
loc_14b60: | |
ax = memoryAGet16(ds, si); | |
ax -= memoryAGet16(ds, si + 6); | |
memoryASet16(ss, bp - 2- 2, ax); | |
if (stop(/*condition!*/)) | |
goto loc_14b8d; | |
push(ax); | |
push(memoryAGet16(ds, si + 8)); | |
push(memoryAGet16(ds, si + 6)); | |
cl = memoryAGet(ds, si + 11); | |
ch = 0; | |
push(cx); | |
push(cs); | |
sub_154a6(); | |
sp += 0x0008; | |
if (memoryAGet16(ss, bp - 2- 2) == ax) | |
goto loc_14b8d; | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) | 0x20); | |
di = 0xffff; | |
loc_14b8d: | |
ax = memoryAGet16(ds, si + 6); | |
dx = memoryAGet16(ds, si + 8); | |
memoryASet16(ds, si, ax); | |
memoryASet16(ds, si + 2, dx); | |
memoryASet16(ds, si + 4, 0x0000); | |
ax = di; | |
loc_14b9f: | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_14bae() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0002; | |
push(di); | |
push(si); | |
si = 0x2f00; | |
di = 0; | |
memoryASet16(ss, bp - 2- 2, di); | |
goto loc_14bc8; | |
loc_14bc0: | |
memoryASet16(ss, bp - 2- 2, 0xffff); | |
loc_14bc5: | |
si += 0x000c; | |
loc_14bc8: | |
if (memoryAGet16(ds, 0x30e0) < si) | |
goto loc_14be4; | |
if (!(memoryAGet(ds, si + 10) & 0x83)) | |
goto loc_14bc5; | |
push(ds); | |
push(si); | |
push(cs); | |
sub_14b26(); | |
sp += 0x0004; | |
ax++; | |
if (ax == 0) | |
goto loc_14bc0; | |
di++; | |
goto loc_14bc5; | |
loc_14be4: | |
if (memoryAGet16(ss, bp + 4- 2) != 0x0001) | |
goto loc_14bee; | |
ax = di; | |
goto loc_14bf1; | |
loc_14bee: | |
ax = memoryAGet16(ss, bp - 2- 2); | |
loc_14bf1: | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
sp += 2; | |
} | |
void sub_14c0a() | |
{ | |
push(bp); | |
bp = sp; | |
ax = 0x0171; | |
push(cs); | |
sub_13f40(); | |
push(si); | |
push(di); | |
ax = 0; | |
memoryASet16(ss, bp - 8- 2, ax); | |
memoryASet(ss, bp - 5- 2, al); | |
stop(); // les si, ptr [bp + 0xa] | |
lodsb<MemAuto, DirAuto>(es); | |
memoryASet16(ss, bp + 10- 2, si); | |
memoryASet(ss, bp - 2- 2, al); | |
if (!al) | |
goto loc_14c33; | |
if ((short)memoryAGet16(ss, bp - 8- 2) >= (short)0x0000) | |
goto loc_14c39; | |
loc_14c33: | |
ax = memoryAGet16(ss, bp - 8- 2); | |
goto loc_150ee; | |
loc_14c39: | |
bx = 0x30f0; | |
al -= 0x20; | |
if (al > 0x58) | |
goto loc_14c47; | |
al = memory(ds, bx+al); | |
al &= 0x0f; | |
goto loc_14c49; | |
loc_14c47: | |
al = 0x00; | |
loc_14c49: | |
cl = 0x03; | |
al <<= cl; | |
al += memoryAGet(ss, bp - 5- 2); | |
al = memory(ds, bx+al); | |
cl++; | |
al >>= cl; | |
memoryASet(ss, bp - 5- 2, al); | |
cbw(); | |
bx = ax; | |
bx <<= 1; | |
stop(/*2*/); // (jmp word ptr cs:[bx + 0xf7a]) jump Indirect memoryAGet16(cs, bx + 3962) | |
// gap of 1164 bytes | |
loc_150ee: | |
di = pop(); | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_150f4() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0004; | |
push(si); | |
si = 0x2f00; | |
ax = 0; | |
memoryASet16(ss, bp - 2- 2, ax); | |
memoryASet16(ss, bp - 4- 2, ax); | |
goto loc_1510b; | |
loc_15108: | |
si += 0x000c; | |
loc_1510b: | |
if (memoryAGet16(ds, 0x30e0) < si) | |
goto loc_15137; | |
if (memoryAGet(ds, si + 10) & 0x83) | |
goto loc_15108; | |
memoryASet16(ds, si + 4, 0x0000); | |
memoryASet(ds, si + 10, 0x00); | |
ax = 0; | |
memoryASet16(ds, si + 8, ax); | |
memoryASet16(ds, si + 6, ax); | |
memoryASet16(ds, si + 2, ax); | |
memoryASet16(ds, si, ax); | |
memoryASet(ds, si + 11, 0xff); | |
memoryASet16(ss, bp - 4- 2, si); | |
memoryASet16(ss, bp - 2- 2, ds); | |
loc_15137: | |
ax = memoryAGet16(ss, bp - 4- 2); | |
dx = memoryAGet16(ss, bp - 2- 2); | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_15142() | |
{ | |
goto loc_15142; | |
loc_1425e: | |
if (stop(/*1*/)) | |
goto loc_14275; | |
ax = 0; | |
sp = bp; | |
bp = pop(); | |
return; | |
// gap of 15 bytes | |
loc_14275: | |
sub_14286(); | |
ax = 0xffff; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
sp = bp; | |
bp = pop(); | |
return; | |
// gap of 3778 bytes | |
loc_15142: | |
push(bp); | |
bp = sp; | |
bx = memoryAGet16(ss, bp + 6- 2); | |
if (bx < memoryAGet16(ds, 0x2eab)) | |
goto loc_15154; | |
ax = 0x0900; | |
flags.carry = true; | |
goto loc_1515f; | |
loc_15154: | |
ah = 0x3e; | |
interrupt(0x21); | |
if (flags.carry) | |
goto loc_1515f; | |
memoryASet(ds, bx + 11949, 0x00); | |
loc_1515f: | |
goto loc_1425e; | |
} | |
void sub_15162() | |
{ | |
goto loc_15162; | |
loc_14273: | |
if (stop(/*1*/)) | |
goto loc_1427c; | |
sub_14286(); | |
ax = 0xffff; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
loc_1427c: | |
sp = bp; | |
bp = pop(); | |
return; | |
// gap of 3810 bytes | |
loc_15162: | |
push(bp); | |
bp = sp; | |
sp -= 0x0004; | |
bx = memoryAGet16(ss, bp + 6- 2); | |
if (bx < memoryAGet16(ds, 0x2eab)) | |
goto loc_15176; | |
ax = 0x0900; | |
goto loc_151a0; | |
loc_15176: | |
if (!(memoryAGet16(ss, bp + 10- 2) & 0x8000)) | |
goto loc_151c5; | |
if (memoryAGet16(ss, bp + 12- 2) == 0x0000) | |
goto loc_1519d; | |
cx = 0; | |
dx = cx; | |
ax = 0x4201; | |
interrupt(0x21); | |
if (flags.carry) | |
goto loc_151d9; | |
if (memoryAGet16(ss, bp + 12- 2) & 0x0002) | |
goto loc_151a3; | |
flags.carry = (ax + memoryAGet16(ss, bp + 8- 2)) >= 0x10000; | |
ax += memoryAGet16(ss, bp + 8- 2); | |
dx += memoryAGet16(ss, bp + 10- 2) + flags.carry; | |
if ((short)dx >= 0) | |
goto loc_151c5; | |
loc_1519d: | |
ax = 0x1600; | |
loc_151a0: | |
flags.carry = true; | |
goto loc_151d9; | |
loc_151a3: | |
memoryASet16(ss, bp - 2- 2, dx); | |
memoryASet16(ss, bp - 4- 2, ax); | |
dx = cx; | |
ax = 0x4202; | |
interrupt(0x21); | |
flags.carry = (ax + memoryAGet16(ss, bp + 8- 2)) >= 0x10000; | |
ax += memoryAGet16(ss, bp + 8- 2); | |
dx += memoryAGet16(ss, bp + 10- 2) + flags.carry; | |
if ((short)dx >= 0) | |
goto loc_151c5; | |
cx = memoryAGet16(ss, bp - 2- 2); | |
dx = memoryAGet16(ss, bp - 4- 2); | |
ax = 0x4200; | |
interrupt(0x21); | |
goto loc_1519d; | |
loc_151c5: | |
dx = memoryAGet16(ss, bp + 8- 2); | |
cx = memoryAGet16(ss, bp + 10- 2); | |
al = memoryAGet(ss, bp + 12- 2); | |
ah = 0x42; | |
interrupt(0x21); | |
if (flags.carry) | |
goto loc_151d9; | |
memoryASet(ds, bx + 11949, memoryAGet(ds, bx + 11949) & 0xfd); | |
loc_151d9: | |
goto loc_14273; | |
} | |
void sub_151dc() | |
{ | |
goto loc_151dc; | |
loc_14273: | |
if (stop(/*1*/)) | |
goto loc_1427c; | |
sub_14286(); | |
ax = 0xffff; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
loc_1427c: | |
sp = bp; | |
bp = pop(); | |
return; | |
// gap of 3932 bytes | |
loc_151dc: | |
push(bp); | |
bp = sp; | |
sp -= 0x0004; | |
bh = 0; | |
if (memoryAGet(ds, 0x2ea6) < 0x03) | |
goto loc_151ee; | |
bh = memoryAGet(ss, bp + 12- 2); | |
loc_151ee: | |
ax = memoryAGet16(ss, bp + 14- 2); | |
memoryASet16(ss, bp + 12- 2, ax); | |
goto loc_151fe; | |
// gap of 8 bytes | |
loc_151fe: | |
memoryASet(ss, bp - 2- 2, bh); | |
ax = memoryAGet16(ss, bp + 10- 2); | |
cx = ax; | |
memoryASet(ss, bp - 4- 2, 0x00); | |
if (ax & 0x8000) | |
goto loc_1521f; | |
if (ax & 0x4000) | |
goto loc_1521b; | |
if (memoryAGet(ds, 0x3153) & 0x80) | |
goto loc_1521f; | |
loc_1521b: | |
memoryASet(ss, bp - 4- 2, 0x80); | |
loc_1521f: | |
push(ds); | |
stop(); // lds dx, ptr [bp + 6] | |
al &= 0x03; | |
al |= bh; | |
ah = 0x3d; | |
interrupt(0x21); | |
ds = pop(); | |
if (!flags.carry) | |
goto loc_15240; | |
if (ax != 0x0002) | |
goto loc_1523c; | |
if (!(cx & 0x0100)) | |
goto loc_1523c; | |
goto loc_152e1; | |
loc_1523c: | |
flags.carry = true; | |
goto loc_14273; | |
loc_15240: | |
tx = ax; | |
ax = bx; | |
bx = tx; | |
ax = cx; | |
ax &= 0x0500; | |
if (ax != 0x0500) | |
goto loc_15254; | |
ah = 0x3e; | |
interrupt(0x21); | |
ax = 0x1100; | |
goto loc_1523c; | |
loc_15254: | |
memoryASet(ss, bp - 3- 2, 0x01); | |
ax = 0x4400; | |
interrupt(0x21); | |
if (!(dl & 0x80)) | |
goto loc_15266; | |
memoryASet(ss, bp - 4- 2, memoryAGet(ss, bp - 4- 2) | 0x40); | |
loc_15266: | |
if (!(memoryAGet(ss, bp - 4- 2) & 0x40)) | |
goto loc_1526f; | |
goto loc_1534e; | |
loc_1526f: | |
ax = memoryAGet16(ss, bp + 10- 2); | |
if (!(ax & 0x0200)) | |
goto loc_15295; | |
if (!(ax & 0x0003)) | |
goto loc_15285; | |
cx = 0; | |
ah = 0x40; | |
interrupt(0x21); | |
goto loc_1534e; | |
loc_15285: | |
ah = 0x3e; | |
interrupt(0x21); | |
push(ds); | |
stop(); // lds dx, ptr [bp + 6] | |
ax = 0x4300; | |
interrupt(0x21); | |
ds = pop(); | |
goto loc_152fe; | |
loc_15295: | |
if (memoryAGet(ss, bp - 4- 2) & 0x80) | |
goto loc_1529e; | |
goto loc_1534e; | |
loc_1529e: | |
if (ax & 0x0002) | |
goto loc_152a6; | |
goto loc_1534e; | |
loc_152a6: | |
cx = 0xffff; | |
dx = cx; | |
ax = 0x4202; | |
interrupt(0x21); | |
cx = -cx; | |
push(ds); | |
push(ss); | |
ds = pop(); | |
stop(); // lea dx, [bp - 1] | |
ah = 0x3f; | |
interrupt(0x21); | |
ds = pop(); | |
if (!ax) | |
goto loc_152d6; | |
if (memoryAGet(ss, bp - 1- 2) != 0x1a) | |
goto loc_152d6; | |
cx = -cx; | |
dx = cx; | |
ax = 0x4202; | |
interrupt(0x21); | |
cx = 0; | |
ah = 0x40; | |
interrupt(0x21); | |
loc_152d6: | |
cx = 0; | |
dx = cx; | |
ax = 0x4200; | |
interrupt(0x21); | |
goto loc_1534e; | |
loc_152e1: | |
memoryASet(ss, bp - 3- 2, 0x00); | |
cx = memoryAGet16(ss, bp + 12- 2); | |
sub_15397(); | |
memoryASet16(ss, bp + 12- 2, cx); | |
if (memoryAGet(ss, bp - 2- 2) & 0xff) | |
goto loc_152fb; | |
if (memoryAGet16(ss, bp + 10- 2) & 0x0002) | |
goto loc_152fe; | |
loc_152fb: | |
cl &= 0xfe; | |
loc_152fe: | |
push(ds); | |
stop(); // lds dx, ptr [bp + 6] | |
ah = 0x3c; | |
interrupt(0x21); | |
ds = pop(); | |
if (!flags.carry) | |
goto loc_1530c; | |
loc_15309: | |
goto loc_14273; | |
loc_1530c: | |
tx = ax; | |
ax = bx; | |
bx = tx; | |
if (memoryAGet(ss, bp - 2- 2) & 0xff) | |
goto loc_1531a; | |
if (memoryAGet16(ss, bp + 10- 2) & 0x0002) | |
goto loc_1534e; | |
loc_1531a: | |
ah = 0x3e; | |
interrupt(0x21); | |
al = memoryAGet(ss, bp + 10- 2); | |
al &= 0x03; | |
al |= memoryAGet(ss, bp - 2- 2); | |
push(ds); | |
stop(); // lds dx, ptr [bp + 6] | |
ah = 0x3d; | |
interrupt(0x21); | |
ds = pop(); | |
if (flags.carry) | |
goto loc_15309; | |
tx = ax; | |
ax = bx; | |
bx = tx; | |
if (memoryAGet(ss, bp - 3- 2) & 0x01) | |
goto loc_1534e; | |
if (!(memoryAGet16(ss, bp + 12- 2) & 0x0001)) | |
goto loc_1534e; | |
cl |= 0x01; | |
push(ds); | |
stop(); // lds dx, ptr [bp + 6] | |
ax = 0x4301; | |
interrupt(0x21); | |
ds = pop(); | |
if (flags.carry) | |
goto loc_15309; | |
loc_1534e: | |
if (memoryAGet(ss, bp - 4- 2) & 0x40) | |
goto loc_15393; | |
push(ds); | |
stop(); // lds dx, ptr [bp + 6] | |
ax = 0x4300; | |
interrupt(0x21); | |
ds = pop(); | |
ax = cx; | |
cl = 0; | |
ax &= 0x0001; | |
if (ax == 0) | |
goto loc_15369; | |
cl = 0x10; | |
loc_15369: | |
if (!(memoryAGet16(ss, bp + 10- 2) & 0x0008)) | |
goto loc_15373; | |
cl |= 0x20; | |
loc_15373: | |
if (bx < memoryAGet16(ds, 0x2eab)) | |
goto loc_15383; | |
ah = 0x3e; | |
interrupt(0x21); | |
ax = 0x1800; | |
goto loc_1523c; | |
loc_15383: | |
cl |= memoryAGet(ss, bp - 4- 2); | |
cl |= 0x01; | |
memoryASet(ds, bx + 11949, cl); | |
ax = bx; | |
sp = bp; | |
bp = pop(); | |
return; | |
loc_15393: | |
cl = 0; | |
goto loc_15373; | |
} | |
void sub_15397() | |
{ | |
ax = memoryAGet16(ds, 0x2ea0); | |
ax = ~ax; | |
ax &= cx; | |
cx = 0; | |
if (al & 0x80) | |
return; | |
cl |= 0x01; | |
} | |
void sub_153a8() | |
{ | |
goto loc_153a8; | |
loc_14273: | |
if (stop(/*1*/)) | |
goto loc_1427c; | |
sub_14286(); | |
ax = 0xffff; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
loc_1427c: | |
sp = bp; | |
bp = pop(); | |
return; | |
// gap of 4392 bytes | |
loc_153a8: | |
push(bp); | |
bp = sp; | |
sp -= 0x0002; | |
bx = memoryAGet16(ss, bp + 6- 2); | |
if (bx < memoryAGet16(ds, 0x2eab)) | |
goto loc_153bd; | |
flags.carry = true; | |
ax = 0x0900; | |
goto loc_15430; | |
loc_153bd: | |
ax = 0; | |
cx = memoryAGet16(ss, bp + 12- 2); | |
if (cx == 0) | |
goto loc_15430; | |
if (memoryAGet(ds, bx + 11949) & 0x02) | |
goto loc_15430; | |
if (memoryAGet16(ds, 0x34fc) != 0xd6d6) | |
goto loc_153d7; | |
callIndirect(memoryAGet16(ds, 0x34fe)); | |
loc_153d7: | |
cx = memoryAGet16(ss, bp + 12- 2); | |
push(ds); | |
stop(); // lds dx, ptr [bp + 8] | |
ah = 0x3f; | |
interrupt(0x21); | |
ds = pop(); | |
if (!flags.carry) | |
goto loc_153e9; | |
ah = 0x09; | |
goto loc_15430; | |
loc_153e9: | |
if (!(memoryAGet(ds, bx + 11949) & 0x80)) | |
goto loc_15430; | |
memoryASet(ds, bx + 11949, memoryAGet(ds, bx + 11949) & 0xfb); | |
push(si); | |
push(di); | |
push(ds); | |
es = pop(); | |
ds = memoryAGet16(ss, bp + 10- 2); | |
flags.direction = false; | |
si = dx; | |
di = dx; | |
cx = ax; | |
if (cx == 0) | |
goto loc_1542c; | |
ah = 0x0d; | |
if (memoryAGet(ds, si) != 0x0a) | |
goto loc_15412; | |
memoryASet(es, bx + 11949, memoryAGet(es, bx + 11949) | 0x04); | |
loc_15412: | |
lodsb<MemAuto, DirAuto>(); | |
if (al == ah) | |
goto loc_15433; | |
if (al != 0x1a) | |
goto loc_15423; | |
memoryASet(es, bx + 11949, memoryAGet(es, bx + 11949) | 0x02); | |
goto loc_15428; | |
loc_15423: | |
memoryASet(ds, di, al); | |
di++; | |
loc_15426: | |
if (--cx) | |
goto loc_15412; | |
loc_15428: | |
ax = di; | |
ax -= dx; | |
loc_1542c: | |
push(es); | |
ds = pop(); | |
loc_1542e: | |
di = pop(); | |
si = pop(); | |
loc_15430: | |
goto loc_14273; | |
loc_15433: | |
if (cx == 0x0001) | |
goto loc_1543f; | |
if (memoryAGet(ds, si) == 0x0a) | |
goto loc_15426; | |
goto loc_15423; | |
loc_1543f: | |
push(es); | |
ds = pop(); | |
if (!(memoryAGet(ds, bx + 11949) & 0x40)) | |
goto loc_15464; | |
ax = 0x4400; | |
interrupt(0x21); | |
if (dx & 0x0020) | |
goto loc_15460; | |
push(ds); | |
push(ss); | |
ds = pop(); | |
stop(); // lea dx, [bp - 1] | |
ah = 0x3f; | |
interrupt(0x21); | |
ds = pop(); | |
if (flags.carry) | |
goto loc_1542e; | |
loc_15460: | |
al = 0x0a; | |
goto loc_15494; | |
loc_15464: | |
push(ds); | |
push(ss); | |
ds = pop(); | |
memoryASet(ss, bp - 1- 2, 0x00); | |
stop(); // lea dx, [bp - 1] | |
ah = 0x3f; | |
interrupt(0x21); | |
ds = pop(); | |
if (flags.carry) | |
goto loc_1542e; | |
if (!ax) | |
goto loc_15492; | |
if (memoryAGet16(ss, bp + 12- 2) == 0x0001) | |
goto loc_1549e; | |
loc_1547f: | |
cx = 0xffff; | |
dx = cx; | |
ax = 0x4201; | |
interrupt(0x21); | |
cx = 0x0001; | |
if (memoryAGet(ss, bp - 1- 2) == 0x0a) | |
goto loc_15499; | |
loc_15492: | |
al = 0x0d; | |
loc_15494: | |
stop(); // lds dx, ptr [bp + 8] | |
goto loc_15423; | |
loc_15499: | |
stop(); // lds dx, ptr [bp + 8] | |
goto loc_15426; | |
loc_1549e: | |
if (memoryAGet(ss, bp - 1- 2) != 0x0a) | |
goto loc_1547f; | |
goto loc_15460; | |
} | |
void sub_154a6() | |
{ | |
goto loc_154a6; | |
loc_14273: | |
if (stop(/*1*/)) | |
goto loc_1427c; | |
sub_14286(); | |
ax = 0xffff; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
loc_1427c: | |
sp = bp; | |
bp = pop(); | |
return; | |
// gap of 4646 bytes | |
loc_154a6: | |
push(bp); | |
bp = sp; | |
sp -= 0x0008; | |
bx = memoryAGet16(ss, bp + 6- 2); | |
if (bx < memoryAGet16(ds, 0x2eab)) | |
goto loc_154bc; | |
ax = 0x0900; | |
flags.carry = true; | |
loc_154b9: | |
goto loc_14273; | |
loc_154bc: | |
if (memoryAGet16(ds, 0x34fc) != 0xd6d6) | |
goto loc_154c8; | |
callIndirect(memoryAGet16(ds, 0x34fe)); | |
loc_154c8: | |
if (!(memoryAGet(ds, bx + 11949) & 0x20)) | |
goto loc_154da; | |
ax = 0x4202; | |
cx = 0; | |
dx = cx; | |
interrupt(0x21); | |
if (flags.carry) | |
goto loc_154b9; | |
loc_154da: | |
if (!(memoryAGet(ds, bx + 11949) & 0x80)) | |
goto loc_1555d; | |
memoryASet16(ss, bp - 6- 2, ds); | |
es = memoryAGet16(ss, bp + 10- 2); | |
stop(); // lds dx, ptr [bp + 8] | |
ax = 0; | |
memoryASet16(ss, bp - 2- 2, ax); | |
memoryASet16(ss, bp - 4- 2, ax); | |
flags.direction = false; | |
push(di); | |
push(si); | |
di = dx; | |
si = dx; | |
memoryASet16(ss, bp - 8- 2, sp); | |
cx = memoryAGet16(ss, bp + 12- 2); | |
if (cx == 0) | |
goto loc_15540; | |
al = 0x0a; | |
stop(); // repne scasb al, byte ptr es:[di] | |
if (stop(/*1*/)) | |
goto loc_15558; | |
push(ds); | |
ds = memoryAGet16(ss, bp - 6- 2); | |
push(cs); | |
sub_15606(); | |
if (ax <= 0x00a8) | |
goto loc_1555f; | |
ds = pop(); | |
sp -= 0x0002; | |
bx = sp; | |
dx = 0x0200; | |
if (ax >= 0x0228) | |
goto loc_15526; | |
dx = 0x0080; | |
loc_15526: | |
sp -= dx; | |
dx = sp; | |
di = dx; | |
push(ss); | |
es = pop(); | |
cx = memoryAGet16(ss, bp + 12- 2); | |
loc_15531: | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x0a) | |
goto loc_15542; | |
loc_15536: | |
if (di == bx) | |
goto loc_15553; | |
loc_1553a: | |
stosb<MemAuto, DirAuto>(); | |
if (--cx) | |
goto loc_15531; | |
sub_15566(); | |
loc_15540: | |
goto loc_155bb; | |
loc_15542: | |
al = 0x0d; | |
if (di != bx) | |
goto loc_1554b; | |
sub_15566(); | |
loc_1554b: | |
stosb<MemAuto, DirAuto>(); | |
al = 0x0a; | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) + 1); | |
goto loc_15536; | |
loc_15553: | |
sub_15566(); | |
goto loc_1553a; | |
loc_15558: | |
si = pop(); | |
di = pop(); | |
ds = memoryAGet16(ss, bp - 6- 2); | |
loc_1555d: | |
goto loc_155cc; | |
loc_1555f: | |
ax = 0xfffc; | |
push(cs); | |
sub_13f40(); | |
push(ax); | |
push(bx); | |
push(cx); | |
push(ds); | |
push(es); | |
ds = pop(); | |
cx = di; | |
cx -= dx; | |
if (cx == 0) | |
goto loc_15584; | |
push(cx); | |
bx = memoryAGet16(ss, bp + 6- 2); | |
ah = 0x40; | |
interrupt(0x21); | |
cx = pop(); | |
if (flags.carry) | |
goto loc_1558b; | |
memoryASet16(ss, bp - 2- 2, memoryAGet16(ss, bp - 2- 2) + ax); | |
if (cx > ax) | |
goto loc_1558b; | |
loc_15584: | |
ds = pop(); | |
cx = pop(); | |
bx = pop(); | |
ax = pop(); | |
di = dx; | |
return; | |
loc_1558b: | |
ah = flags.carry | (flags.zero << 1); | |
ds = pop(); | |
sp += 0x0008; | |
if (memoryAGet16(ss, bp - 2- 2) != 0x0000) | |
goto loc_155bb; | |
flags.carry = ah & 1; | |
flags.zero = (ah >> 1) & 1; | |
if (stop(/*1*/)) | |
goto loc_1559d; | |
ah = 0x09; | |
goto loc_155c1; | |
loc_1559d: | |
ds = memoryAGet16(ss, bp - 6- 2); | |
if (!(memoryAGet(ds, bx + 11949) & 0x40)) | |
goto loc_155b5; | |
ds = memoryAGet16(ss, bp + 10- 2); | |
bx = memoryAGet16(ss, bp + 8- 2); | |
if (memoryAGet(ds, bx) != 0x1a) | |
goto loc_155b5; | |
flags.carry = false; | |
goto loc_155c1; | |
loc_155b5: | |
flags.carry = true; | |
ax = 0x1c00; | |
goto loc_155c1; | |
loc_155bb: | |
ax = memoryAGet16(ss, bp - 2- 2); | |
ax -= memoryAGet16(ss, bp - 4- 2); | |
loc_155c1: | |
sp = memoryAGet16(ss, bp - 8- 2); | |
si = pop(); | |
di = pop(); | |
ds = memoryAGet16(ss, bp - 6- 2); | |
loc_155c9: | |
goto loc_14273; | |
loc_155cc: | |
cx = memoryAGet16(ss, bp + 12- 2); | |
if (cx) | |
goto loc_155d8; | |
ax = cx; | |
goto loc_14273; | |
loc_155d8: | |
push(ds); | |
stop(); // lds dx, ptr [bp + 8] | |
ah = 0x40; | |
interrupt(0x21); | |
push(ds); | |
es = pop(); | |
ds = pop(); | |
if (!flags.carry) | |
goto loc_155e9; | |
ah = 0x09; | |
goto loc_155c9; | |
loc_155e9: | |
if (ax) | |
goto loc_155c9; | |
if (!(memoryAGet(ds, bx + 11949) & 0x40)) | |
goto loc_155ff; | |
bx = dx; | |
if (memoryAGet(es, bx) != 0x1a) | |
goto loc_155ff; | |
flags.carry = false; | |
goto loc_155c9; | |
loc_155ff: | |
flags.carry = true; | |
ax = 0x1c00; | |
goto loc_155c9; | |
} | |
void sub_15566() | |
{ | |
goto loc_15566; | |
loc_14273: | |
if (stop(/*1*/)) | |
goto loc_1427c; | |
sub_14286(); | |
ax = 0xffff; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
loc_1427c: | |
sp = bp; | |
bp = pop(); | |
return; | |
// gap of 4838 bytes | |
loc_15566: | |
push(ax); | |
push(bx); | |
push(cx); | |
push(ds); | |
push(es); | |
ds = pop(); | |
cx = di; | |
cx -= dx; | |
if (cx == 0) | |
goto loc_15584; | |
push(cx); | |
bx = memoryAGet16(ss, bp + 6- 2); | |
ah = 0x40; | |
interrupt(0x21); | |
cx = pop(); | |
if (flags.carry) | |
goto loc_1558b; | |
memoryASet16(ss, bp - 2- 2, memoryAGet16(ss, bp - 2- 2) + ax); | |
if (cx > ax) | |
goto loc_1558b; | |
loc_15584: | |
ds = pop(); | |
cx = pop(); | |
bx = pop(); | |
ax = pop(); | |
di = dx; | |
return; | |
loc_1558b: | |
ah = flags.carry | (flags.zero << 1); | |
ds = pop(); | |
sp += 0x0008; | |
if (memoryAGet16(ss, bp - 2- 2) != 0x0000) | |
goto loc_155bb; | |
flags.carry = ah & 1; | |
flags.zero = (ah >> 1) & 1; | |
if (stop(/*1*/)) | |
goto loc_1559d; | |
ah = 0x09; | |
goto loc_155c1; | |
loc_1559d: | |
ds = memoryAGet16(ss, bp - 6- 2); | |
if (!(memoryAGet(ds, bx + 11949) & 0x40)) | |
goto loc_155b5; | |
ds = memoryAGet16(ss, bp + 10- 2); | |
bx = memoryAGet16(ss, bp + 8- 2); | |
if (memoryAGet(ds, bx) != 0x1a) | |
goto loc_155b5; | |
flags.carry = false; | |
goto loc_155c1; | |
loc_155b5: | |
flags.carry = true; | |
ax = 0x1c00; | |
goto loc_155c1; | |
loc_155bb: | |
ax = memoryAGet16(ss, bp - 2- 2); | |
ax -= memoryAGet16(ss, bp - 4- 2); | |
loc_155c1: | |
sp = memoryAGet16(ss, bp - 8- 2); | |
si = pop(); | |
di = pop(); | |
ds = memoryAGet16(ss, bp - 6- 2); | |
goto loc_14273; | |
} | |
void sub_15606() | |
{ | |
cx = pop(); | |
dx = pop(); | |
ax = memoryAGet16(ds, 0x2ee0); | |
if (ax >= sp) | |
goto loc_15616; | |
ax -= sp; | |
ax = -ax; | |
loc_15613: | |
push(dx); | |
push(cx); | |
return; | |
loc_15616: | |
ax = 0; | |
goto loc_15613; | |
} | |
void sub_1561a() | |
{ | |
goto loc_15639; | |
// gap of 28 bytes | |
loc_15639: | |
push(bp); | |
bp = sp; | |
push(si); | |
push(di); | |
cx = memoryAGet16(ss, bp + 6- 2); | |
if (cx > 0xffe8) | |
goto loc_156af; | |
push(ds); | |
ax = memoryAGet16(ds, 0x3156); | |
if (!ax) | |
goto loc_15696; | |
di = 0x1aa0; | |
loc_15651: | |
si = memoryAGet16(ds, 0x315e); | |
stop(); // lds bx, ptr [0x3158] | |
loc_15659: | |
push(ds); | |
loc_1565a: | |
push(si); | |
push(di); | |
callIndirect(di); | |
di = pop(); | |
si = pop(); | |
if (stop(/*1*/)) | |
goto loc_1568d; | |
dx = ds; | |
stop(); // lds bx, ptr [bx + 0xc] | |
if (dx != si) | |
goto loc_1565a; | |
ax = pop(); | |
ds = pop(); | |
push(ds); | |
stop(); // les si, ptr [0x3158] | |
si = memoryAGet16(es, si + 18); | |
stop(); // lds bx, ptr [0x3154] | |
dx = ds; | |
if (dx != ax) | |
goto loc_15659; | |
ds = pop(); | |
push(ds); | |
if (di == 0x1b1c) | |
goto loc_15696; | |
di = 0x1b1c; | |
goto loc_15651; | |
loc_1568d: | |
si = pop(); | |
if (di == 0x1aa0) | |
goto loc_156a3; | |
goto loc_156a0; | |
loc_15696: | |
es = pop(); | |
push(es); | |
di = 0x3154; | |
sub_1589c(); | |
if (flags.carry) | |
goto loc_156ae; | |
loc_156a0: | |
sub_15720(); | |
loc_156a3: | |
ds = pop(); | |
memoryASet16(ds, 0x315a, dx); | |
memoryASet16(ds, 0x3158, bx); | |
goto loc_156b2; | |
loc_156ae: | |
ds = pop(); | |
loc_156af: | |
ax = 0; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
loc_156b2: | |
di = pop(); | |
si = pop(); | |
bp = pop(); | |
} | |
void sub_15620() | |
{ | |
goto loc_15626; | |
// gap of 3 bytes | |
loc_15626: | |
push(bp); | |
bp = sp; | |
push(si); | |
stop(); // les si, ptr [bp + 6] | |
cx = es; | |
if (cx == 0) | |
goto loc_15636; | |
memoryASet(es, si + 65534, memoryAGet(es, si + 65534) | 0x01); | |
loc_15636: | |
si = pop(); | |
bp = pop(); | |
} | |
void sub_156b6() | |
{ | |
push(es); | |
push(di); | |
di = ax; | |
di += bx; | |
memoryASet16(ds, bx + 4, di); | |
di--; | |
di--; | |
ax -= 0x0016; | |
stop(); // lea si, [bx + 0x14] | |
memoryASet16(ds, di, 0xfffe); | |
memoryASet16(ds, bx + 10, di); | |
ax--; | |
memoryASet16(ds, si, ax); | |
memoryASet16(ds, bx, ds); | |
ax = si; | |
dx = ds; | |
es = dx; | |
stop(); // lea di, [bx + 6] | |
flags.direction = false; | |
stosw<MemAuto, DirAuto>(); | |
stosw<MemAuto, DirAuto>(); | |
di++; | |
di++; | |
ax = 0; | |
stosw<MemAuto, DirAuto>(); | |
stosw<MemAuto, DirAuto>(); | |
stosw<MemAuto, DirAuto>(); | |
stosw<MemAuto, DirAuto>(); | |
di = pop(); | |
es = pop(); | |
} | |
void sub_156ea() | |
{ | |
ax = memoryAGet16(es, di + 2); | |
if (ax) | |
goto loc_156fb; | |
memoryASet16(es, di + 2, ds); | |
memoryASet16(es, di, bx); | |
goto loc_1570f; | |
loc_156fb: | |
push(es); | |
stop(); // les si, ptr es:[di + 8] | |
memoryASet16(es, si + 14, ds); | |
memoryASet16(es, si + 12, bx); | |
memoryASet16(ds, bx + 18, es); | |
memoryASet16(ds, bx + 16, si); | |
es = pop(); | |
loc_1570f: | |
memoryASet16(es, di + 10, ds); | |
memoryASet16(es, di + 8, bx); | |
memoryASet16(es, di + 6, ds); | |
memoryASet16(es, di + 4, bx); | |
} | |
void sub_15720() | |
{ | |
cx++; | |
cl &= 0xfe; | |
push(bx); | |
flags.direction = false; | |
si = memoryAGet16(ds, bx + 8); | |
bx = memoryAGet16(ds, bx + 10); | |
di = 0; | |
goto loc_15753; | |
loc_15730: | |
ax = bx; | |
bx = pop(); | |
if (al & 0x01) | |
goto loc_15779; | |
push(bx); | |
si = memoryAGet16(ds, bx + 6); | |
bx = memoryAGet16(ds, bx + 8); | |
if (bx == si) | |
goto loc_15778; | |
bx--; | |
di = 0; | |
goto loc_15753; | |
// gap of 1 bytes | |
loc_15748: | |
stop(); // lea dx, [si - 2] | |
if (dx >= bx) | |
goto loc_15730; | |
flags.carry = (si + ax) >= 0x10000; | |
si += ax; | |
if (flags.carry) | |
goto loc_15776; | |
loc_15753: | |
lodsw<MemAuto, DirAuto>(); | |
if (!(al & 0x01)) | |
goto loc_15748; | |
di = si; | |
loc_1575a: | |
ax--; | |
if (ax >= cx) | |
goto loc_15782; | |
flags.carry = (si + ax) >= 0x10000; | |
si += ax; | |
if (flags.carry) | |
goto loc_15776; | |
dx = ax; | |
lodsw<MemAuto, DirAuto>(); | |
if (!(al & 0x01)) | |
goto loc_15748; | |
ax += dx; | |
ax += 0x0002; | |
si = di; | |
memoryASet16(ds, si + 65534, ax); | |
goto loc_1575a; | |
loc_15776: | |
ax = ax; | |
loc_15778: | |
bx = pop(); | |
loc_15779: | |
ax = memoryAGet16(ds, bx + 6); | |
memoryASet16(ds, bx + 8, ax); | |
flags.carry = true; | |
return; | |
loc_15782: | |
bx = pop(); | |
memoryASet16(ds, si + 65534, cx); | |
if (stop(/*1*/)) | |
goto loc_15791; | |
di += cx; | |
ax -= cx; | |
ax--; | |
memoryASet16(ds, di, ax); | |
di -= cx; | |
loc_15791: | |
di += cx; | |
memoryASet16(ds, bx + 8, di); | |
ax = si; | |
dx = ds; | |
flags.carry = false; | |
} | |
// INJECT: Error: cannot inject carry flag in sub_1589c()! | |
void sub_1589c() | |
{ | |
dx = cx; | |
dx += 0x0027; | |
dl &= 0xf0; | |
bx = dx; | |
bx = -bx; | |
bx = -bx; | |
flags.carry = !flags.carry; | |
stop(/*carry*/); | |
bx = rcr(bx, 1); | |
bx >>= 1; | |
bx >>= 1; | |
bx >>= 1; | |
loc_158b3: | |
ah = 0x48; | |
interrupt(0x21); | |
if (flags.carry) | |
goto loc_158df; | |
if (ax <= memoryAGet16(ds, 0x2e80)) | |
goto loc_158b3; | |
if (ax <= memoryAGet16(ds, 0x2e7e)) | |
goto loc_158c8; | |
memoryASet16(ds, 0x2e7e, ax); | |
loc_158c8: | |
ds = ax; | |
bx = 0; | |
ax = memoryAGet16(es, di + 12); | |
memoryASet16(ds, bx + 2, ax); | |
ax = dx; | |
sub_156b6(); | |
sub_156ea(); | |
flags.carry = false; | |
goto loc_158df; | |
// gap of 1 bytes | |
loc_158df: | |
stop(/*inject ret*/); | |
} | |
void sub_158e0() | |
{ | |
push(bp); | |
bp = sp; | |
dx = di; | |
bx = si; | |
push(ds); | |
stop(); // les di, ptr [bp + 6] | |
ax = 0; | |
cx = 0xffff; | |
stop(); // repne scasb al, byte ptr es:[di] | |
stop(); // lea si, [di - 1] | |
stop(); // les di, ptr [bp + 0xa] | |
cx = 0xffff; | |
stop(); // repne scasb al, byte ptr es:[di] | |
cx = ~cx; | |
di -= cx; | |
ax = es; | |
ds = ax; | |
es = memoryAGet16(ss, bp + 8- 2); | |
tx = si; | |
si = di; | |
di = tx; | |
ax = memoryAGet16(ss, bp + 6- 2); | |
if (!(si & 0x0001)) | |
goto loc_15915; | |
movsb<MemAuto, MemAuto, DirAuto>(); | |
cx--; | |
loc_15915: | |
cx >>= 1; | |
rep_movsw<MemAuto, MemAuto, DirAuto>(); | |
stop(/*8*/); // inject carry failed | |
cx += cx + flags.carry; | |
rep_movsb<MemAuto, MemAuto, DirAuto>(); | |
si = bx; | |
di = dx; | |
ds = pop(); | |
dx = es; | |
bp = pop(); | |
} | |
void sub_15926() | |
{ | |
push(bp); | |
bp = sp; | |
dx = di; | |
bx = si; | |
push(ds); | |
stop(); // lds si, ptr [bp + 0xa] | |
di = si; | |
ax = ds; | |
es = ax; | |
ax = 0; | |
cx = 0xffff; | |
stop(); // repne scasb al, byte ptr es:[di] | |
cx = ~cx; | |
stop(); // les di, ptr [bp + 6] | |
ax = di; | |
if (!(al & 0x01)) | |
goto loc_1594b; | |
movsb<MemAuto, MemAuto, DirAuto>(); | |
cx--; | |
loc_1594b: | |
cx >>= 1; | |
rep_movsw<MemAuto, MemAuto, DirAuto>(); | |
stop(/*8*/); // inject carry failed | |
cx += cx + flags.carry; | |
rep_movsb<MemAuto, MemAuto, DirAuto>(); | |
si = bx; | |
di = dx; | |
ds = pop(); | |
dx = es; | |
bp = pop(); | |
} | |
void sub_1595c() | |
{ | |
push(bp); | |
bp = sp; | |
dx = di; | |
stop(); // les di, ptr [bp + 6] | |
ax = 0; | |
cx = 0xffff; | |
stop(); // repne scasb al, byte ptr es:[di] | |
cx = ~cx; | |
cx--; | |
tx = ax; | |
ax = cx; | |
cx = tx; | |
di = dx; | |
bp = pop(); | |
} | |
void sub_15974() | |
{ | |
goto loc_159d4; | |
// gap of 93 bytes | |
loc_159d4: | |
push(bp); | |
bp = sp; | |
push(di); | |
push(si); | |
push(ds); | |
stop(); // lds si, ptr [bp + 6] | |
ax = 0; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
bx = 0; | |
loc_159e2: | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x20) | |
goto loc_159e2; | |
if (al == 0x09) | |
goto loc_159e2; | |
push(ax); | |
if (al == 0x2d) | |
goto loc_159f4; | |
if (al != 0x2b) | |
goto loc_159f5; | |
loc_159f4: | |
lodsb<MemAuto, DirAuto>(); | |
loc_159f5: | |
if (al > 0x39) | |
goto loc_15a18; | |
flags.carry = al < 0x30; | |
al -= 0x30; | |
if (flags.carry) | |
goto loc_15a18; | |
bx <<= 1; | |
stop(/*carry*/); | |
dx = rcl(dx, 0x0001); | |
cx = bx; | |
di = dx; | |
bx <<= 1; | |
stop(/*carry*/); | |
dx = rcl(dx, 0x0001); | |
bx <<= 1; | |
stop(/*carry*/); | |
dx = rcl(dx, 0x0001); | |
flags.carry = (bx + cx) >= 0x10000; | |
bx += cx; | |
dx += di + flags.carry; | |
flags.carry = (bx + ax) >= 0x10000; | |
bx += ax; | |
dx += flags.carry; | |
goto loc_159f4; | |
loc_15a18: | |
ax = pop(); | |
tx = ax; | |
ax = bx; | |
bx = tx; | |
if (stop(/*1*/)) | |
goto loc_15a25; | |
ax = -ax; | |
stop(/*8*/); // inject carry failed | |
dx += flags.carry; | |
dx = -dx; | |
loc_15a25: | |
ds = pop(); | |
si = pop(); | |
di = pop(); | |
bp = pop(); | |
} | |
void sub_15978() | |
{ | |
goto loc_159d4; | |
// gap of 89 bytes | |
loc_159d4: | |
push(bp); | |
bp = sp; | |
push(di); | |
push(si); | |
push(ds); | |
stop(); // lds si, ptr [bp + 6] | |
ax = 0; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
bx = 0; | |
loc_159e2: | |
lodsb<MemAuto, DirAuto>(); | |
if (al == 0x20) | |
goto loc_159e2; | |
if (al == 0x09) | |
goto loc_159e2; | |
push(ax); | |
if (al == 0x2d) | |
goto loc_159f4; | |
if (al != 0x2b) | |
goto loc_159f5; | |
loc_159f4: | |
lodsb<MemAuto, DirAuto>(); | |
loc_159f5: | |
if (al > 0x39) | |
goto loc_15a18; | |
flags.carry = al < 0x30; | |
al -= 0x30; | |
if (flags.carry) | |
goto loc_15a18; | |
bx <<= 1; | |
stop(/*carry*/); | |
dx = rcl(dx, 0x0001); | |
cx = bx; | |
di = dx; | |
bx <<= 1; | |
stop(/*carry*/); | |
dx = rcl(dx, 0x0001); | |
bx <<= 1; | |
stop(/*carry*/); | |
dx = rcl(dx, 0x0001); | |
flags.carry = (bx + cx) >= 0x10000; | |
bx += cx; | |
dx += di + flags.carry; | |
flags.carry = (bx + ax) >= 0x10000; | |
bx += ax; | |
dx += flags.carry; | |
goto loc_159f4; | |
loc_15a18: | |
ax = pop(); | |
tx = ax; | |
ax = bx; | |
bx = tx; | |
if (stop(/*1*/)) | |
goto loc_15a25; | |
ax = -ax; | |
stop(/*8*/); // inject carry failed | |
dx += flags.carry; | |
dx = -dx; | |
loc_15a25: | |
ds = pop(); | |
si = pop(); | |
di = pop(); | |
bp = pop(); | |
} | |
void sub_15a2a() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
push(di); | |
bl = 0x01; | |
cx = memoryAGet16(ss, bp + 12- 2); | |
ax = memoryAGet16(ss, bp + 6- 2); | |
dx = 0; | |
if (cx != 0x000a) | |
goto loc_15a3f; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
loc_15a3f: | |
push(ds); | |
stop(); // lds di, ptr [bp + 8] | |
goto loc_1600f; | |
// gap of 1481 bytes | |
loc_1600f: | |
push(di); | |
push(ds); | |
es = pop(); | |
flags.direction = false; | |
tx = ax; | |
ax = bx; | |
bx = tx; | |
if (!al) | |
goto loc_1602b; | |
if (cx != 0x000a) | |
goto loc_1602b; | |
if (!(dx & 0x8000)) | |
goto loc_1602b; | |
al = 0x2d; | |
stosb<MemAuto, DirAuto>(); | |
bx = -bx; | |
stop(/*8*/); // inject carry failed | |
dx += flags.carry; | |
dx = -dx; | |
loc_1602b: | |
si = di; | |
loc_1602d: | |
tx = ax; | |
ax = dx; | |
dx = tx; | |
dx = 0; | |
if (!ax) | |
goto loc_16036; | |
div(cx); | |
loc_16036: | |
tx = ax; | |
ax = bx; | |
bx = tx; | |
div(cx); | |
tx = ax; | |
ax = dx; | |
dx = tx; | |
tx = bx; | |
bx = dx; | |
dx = tx; | |
al += 0x30; | |
if (al <= 0x39) | |
goto loc_16044; | |
al += 0x27; | |
loc_16044: | |
stosb<MemAuto, DirAuto>(); | |
ax = dx; | |
ax |= bx; | |
if (ax) | |
goto loc_1602d; | |
memoryASet(ds, di, al); | |
loc_1604d: | |
di--; | |
lodsb<MemAuto, DirAuto>(); | |
tl = memoryAGet(ds, di); | |
memoryASet(ds, di, al); | |
al = tl; | |
memoryASet(ds, si + 65535, al); | |
stop(); // lea ax, [si + 1] | |
if (ax < di) | |
goto loc_1604d; | |
dx = ds; | |
ax = pop(); | |
ds = pop(); | |
di = pop(); | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_15b86() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0002; | |
push(di); | |
push(si); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_1595c(); | |
sp += 0x0004; | |
di = ax; | |
push(memoryAGet16(ss, bp + 12- 2)); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
sub_14a5c(); | |
sp += 0x0004; | |
si = ax; | |
push(memoryAGet16(ss, bp + 12- 2)); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(di); | |
ax = 0x0001; | |
push(ax); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
push(cs); | |
sub_1457c(); | |
sp += 0x000c; | |
memoryASet16(ss, bp - 2- 2, ax); | |
push(memoryAGet16(ss, bp + 12- 2)); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
push(si); | |
sub_14add(); | |
sp += 0x0006; | |
if (memoryAGet16(ss, bp - 2- 2) != di) | |
goto loc_15bde; | |
ax = 0; | |
goto loc_15be1; | |
loc_15bde: | |
ax = 0xffff; | |
loc_15be1: | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_15be8() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
si = memoryAGet16(ss, bp + 6- 2); | |
if (!(memoryAGet(ds, si + 10) & 0x83)) | |
goto loc_15c01; | |
if ((short)memoryAGet16(ss, bp + 14- 2) > (short)0x0002) | |
goto loc_15c01; | |
if ((short)memoryAGet16(ss, bp + 14- 2) >= (short)0x0000) | |
goto loc_15c0a; | |
loc_15c01: | |
memoryASet16(ds, 0x2e9e, 0x0016); | |
goto loc_15c5d; | |
// gap of 1 bytes | |
loc_15c0a: | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) & 0xef); | |
if (memoryAGet16(ss, bp + 14- 2) != 0x0001) | |
goto loc_15c29; | |
push(ds); | |
push(si); | |
push(cs); | |
sub_15c6a(); | |
sp += 0x0004; | |
flags.carry = (memoryAGet16(ss, bp + 10- 2) + ax) >= 0x10000; | |
memoryASet16(ss, bp + 10- 2, memoryAGet16(ss, bp + 10- 2) + ax); | |
memoryASet16(ss, bp + 12- 2, memoryAGet16(ss, bp + 12- 2) + (dx + flags.carry)); | |
memoryASet16(ss, bp + 14- 2, 0x0000); | |
loc_15c29: | |
push(ds); | |
push(si); | |
push(cs); | |
sub_14b26(); | |
sp += 0x0004; | |
if (!(memoryAGet(ds, si + 10) & 0x80)) | |
goto loc_15c3d; | |
memoryASet(ds, si + 10, memoryAGet(ds, si + 10) & 0xfc); | |
loc_15c3d: | |
push(memoryAGet16(ss, bp + 14- 2)); | |
push(memoryAGet16(ss, bp + 12- 2)); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
al = memoryAGet(ds, si + 11); | |
ah = 0; | |
push(ax); | |
push(cs); | |
sub_15162(); | |
sp += 0x0008; | |
if (ax != 0xffff) | |
goto loc_15c62; | |
if (dx != ax) | |
goto loc_15c62; | |
loc_15c5d: | |
ax = 0xffff; | |
goto loc_15c64; | |
loc_15c62: | |
ax = 0; | |
loc_15c64: | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_15c6a() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0014; | |
push(si); | |
si = memoryAGet16(ss, bp + 6- 2); | |
ax = si; | |
ax -= 0x2f00; | |
ax += 0x2ff0; | |
memoryASet16(ss, bp - 16- 2, ax); | |
al = memoryAGet(ds, si + 11); | |
ah = 0; | |
memoryASet16(ss, bp - 12- 2, ax); | |
if ((short)memoryAGet16(ds, si + 4) >= (short)0x0000) | |
goto loc_15c92; | |
memoryASet16(ds, si + 4, 0x0000); | |
loc_15c92: | |
ax = 0x0001; | |
push(ax); | |
ax = 0; | |
push(ax); | |
push(ax); | |
push(memoryAGet16(ss, bp - 12- 2)); | |
push(cs); | |
sub_15162(); | |
sp += 0x0008; | |
memoryASet16(ss, bp - 4- 2, ax); | |
memoryASet16(ss, bp - 2- 2, dx); | |
if (stop(/*condition!*/)) | |
goto loc_15cb6; | |
loc_15caf: | |
ax = 0xffff; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
goto loc_15dfe; | |
loc_15cb6: | |
if (memoryAGet(ds, si + 10) & 0x08) | |
goto loc_15cda; | |
bx = memoryAGet16(ss, bp - 16- 2); | |
if (memoryAGet(ds, bx) & 0x01) | |
goto loc_15cda; | |
ax = memoryAGet16(ds, si + 4); | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
cx = ax; | |
bx = dx; | |
ax = memoryAGet16(ss, bp - 4- 2); | |
dx = memoryAGet16(ss, bp - 2- 2); | |
flags.carry = ax < cx; | |
ax -= cx; | |
dx -= bx + flags.carry; | |
goto loc_15dfe; | |
// gap of 1 bytes | |
loc_15cda: | |
ax = memoryAGet16(ds, si); | |
ax -= memoryAGet16(ds, si + 6); | |
memoryASet16(ss, bp - 10- 2, ax); | |
if (!(memoryAGet(ds, si + 10) & 0x03)) | |
goto loc_15d26; | |
bx = memoryAGet16(ss, bp - 12- 2); | |
if (!(memoryAGet(ds, bx + 11949) & 0x80)) | |
goto loc_15d16; | |
ax = memoryAGet16(ds, si + 6); | |
dx = memoryAGet16(ds, si + 8); | |
memoryASet16(ss, bp - 20- 2, ax); | |
memoryASet16(ss, bp - 18- 2, dx); | |
goto loc_15d0f; | |
loc_15d00: | |
stop(); // les bx, ptr [bp - 0x14] | |
if (memoryAGet(es, bx) != 0x0a) | |
goto loc_15d0c; | |
memoryASet16(ss, bp - 10- 2, memoryAGet16(ss, bp - 10- 2) + 1); | |
loc_15d0c: | |
memoryASet16(ss, bp - 20- 2, memoryAGet16(ss, bp - 20- 2) + 1); | |
loc_15d0f: | |
ax = memoryAGet16(ds, si); | |
if (memoryAGet16(ss, bp - 20- 2) < ax) | |
goto loc_15d00; | |
loc_15d16: | |
ax = memoryAGet16(ss, bp - 2- 2); | |
ax |= memoryAGet16(ss, bp - 4- 2); | |
if (ax) | |
goto loc_15d36; | |
ax = memoryAGet16(ss, bp - 10- 2); | |
dx = 0; | |
goto loc_15dfe; | |
loc_15d26: | |
if (memoryAGet(ds, si + 10) & 0x80) | |
goto loc_15d16; | |
memoryASet16(ds, 0x2e9e, 0x0016); | |
goto loc_15caf; | |
// gap of 1 bytes | |
loc_15d36: | |
if (memoryAGet(ds, si + 10) & 0x01) | |
goto loc_15d3f; | |
goto loc_15df2; | |
loc_15d3f: | |
if (memoryAGet16(ds, si + 4) != 0x0000) | |
goto loc_15d4e; | |
memoryASet16(ss, bp - 10- 2, 0x0000); | |
goto loc_15df2; | |
// gap of 1 bytes | |
loc_15d4e: | |
ax = memoryAGet16(ds, si); | |
ax -= memoryAGet16(ds, si + 6); | |
ax += memoryAGet16(ds, si + 4); | |
memoryASet16(ss, bp - 14- 2, ax); | |
bx = memoryAGet16(ss, bp - 12- 2); | |
if (memoryAGet(ds, bx + 11949) & 0x80) | |
goto loc_15d66; | |
goto loc_15de7; | |
loc_15d66: | |
cx = 0x0002; | |
push(cx); | |
cx = 0; | |
push(cx); | |
push(cx); | |
push(bx); | |
push(cs); | |
sub_15162(); | |
sp += 0x0008; | |
if (ax != memoryAGet16(ss, bp - 4- 2)) | |
goto loc_15dbc; | |
if (dx != memoryAGet16(ss, bp - 2- 2)) | |
goto loc_15dbc; | |
ax = memoryAGet16(ss, bp - 14- 2); | |
ax += memoryAGet16(ds, si + 6); | |
memoryASet16(ss, bp - 8- 2, ax); | |
ax = memoryAGet16(ds, si + 6); | |
dx = memoryAGet16(ds, si + 8); | |
memoryASet16(ss, bp - 20- 2, ax); | |
memoryASet16(ss, bp - 18- 2, dx); | |
goto loc_15da7; | |
loc_15d98: | |
stop(); // les bx, ptr [bp - 0x14] | |
if (memoryAGet(es, bx) != 0x0a) | |
goto loc_15da4; | |
memoryASet16(ss, bp - 14- 2, memoryAGet16(ss, bp - 14- 2) + 1); | |
loc_15da4: | |
memoryASet16(ss, bp - 20- 2, memoryAGet16(ss, bp - 20- 2) + 1); | |
loc_15da7: | |
ax = memoryAGet16(ss, bp - 20- 2); | |
if (memoryAGet16(ss, bp - 8- 2) > ax) | |
goto loc_15d98; | |
bx = memoryAGet16(ss, bp - 16- 2); | |
if (!(memoryAGet(ds, bx) & 0x20)) | |
goto loc_15de7; | |
memoryASet16(ss, bp - 14- 2, memoryAGet16(ss, bp - 14- 2) + 1); | |
goto loc_15de7; | |
loc_15dbc: | |
ax = 0; | |
push(ax); | |
push(memoryAGet16(ss, bp - 2- 2)); | |
push(memoryAGet16(ss, bp - 4- 2)); | |
push(memoryAGet16(ss, bp - 12- 2)); | |
push(cs); | |
sub_15162(); | |
sp += 0x0008; | |
bx = memoryAGet16(ss, bp - 16- 2); | |
ax = memoryAGet16(ds, bx + 2); | |
memoryASet16(ss, bp - 14- 2, ax); | |
bx = memoryAGet16(ss, bp - 12- 2); | |
if (!(memoryAGet(ds, bx + 11949) & 0x04)) | |
goto loc_15de7; | |
ax++; | |
memoryASet16(ss, bp - 14- 2, ax); | |
loc_15de7: | |
ax = memoryAGet16(ss, bp - 14- 2); | |
dx = 0; | |
flags.carry = memoryAGet16(ss, bp - 4- 2) < ax; | |
memoryASet16(ss, bp - 4- 2, memoryAGet16(ss, bp - 4- 2) - ax); | |
memoryASet16(ss, bp - 2- 2, memoryAGet16(ss, bp - 2- 2) - (dx + flags.carry)); | |
loc_15df2: | |
ax = memoryAGet16(ss, bp - 4- 2); | |
dx = memoryAGet16(ss, bp - 2- 2); | |
flags.carry = (ax + memoryAGet16(ss, bp - 10- 2)) >= 0x10000; | |
ax += memoryAGet16(ss, bp - 10- 2); | |
dx += flags.carry; | |
loc_15dfe: | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_15e04() | |
{ | |
push(bp); | |
bp = sp; | |
push(di); | |
push(si); | |
memoryASet(ds, 0x4b6e, 0x42); | |
ax = memoryAGet16(ss, bp + 6- 2); | |
dx = memoryAGet16(ss, bp + 8- 2); | |
memoryASet16(ds, 0x4b6a, ax); | |
memoryASet16(ds, 0x4b6c, dx); | |
si = 0x4b64; | |
memoryASet16(ds, si, ax); | |
memoryASet16(ds, si + 2, dx); | |
memoryASet16(ds, 0x4b68, 0x7fff); | |
push(memoryAGet16(ss, bp + 16- 2)); | |
push(memoryAGet16(ss, bp + 14- 2)); | |
push(memoryAGet16(ss, bp + 12- 2)); | |
push(memoryAGet16(ss, bp + 10- 2)); | |
ax = si; | |
push(ds); | |
push(ax); | |
push(cs); | |
sub_14c0a(); | |
sp += 0x000c; | |
di = ax; | |
memoryASet16(ds, 0x4b68, memoryAGet16(ds, 0x4b68) - 1); | |
if ((short)memoryAGet16(ds, 0x4b68) < 0) | |
goto loc_15e58; | |
stop(); // les bx, ptr [0x4b64] | |
memoryASet16(ds, 0x4b64, memoryAGet16(ds, 0x4b64) + 1); | |
memoryASet(es, bx, 0x00); | |
goto loc_15e65; | |
// gap of 1 bytes | |
loc_15e58: | |
push(ds); | |
push(si); | |
ax = 0; | |
push(ax); | |
push(cs); | |
sub_147f4(); | |
sp += 0x0006; | |
loc_15e65: | |
ax = di; | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_15e6e() | |
{ | |
push(bp); | |
bp = sp; | |
cx = ds; | |
stop(); // lds bx, ptr [bp + 6] | |
dx = bx; | |
goto loc_15e85; | |
loc_15e7a: | |
al -= 0x61; | |
if (al >= 0x1a) | |
goto loc_15e84; | |
al += 0x41; | |
memoryASet(ds, bx, al); | |
loc_15e84: | |
bx++; | |
loc_15e85: | |
al = memoryAGet(ds, bx); | |
if (al) | |
goto loc_15e7a; | |
tx = ax; | |
ax = dx; | |
dx = tx; | |
dx = ds; | |
ds = cx; | |
bp = pop(); | |
} | |
void sub_15f5c() | |
{ | |
push(bp); | |
bp = sp; | |
cx = memoryAGet16(ss, bp + 14- 2); | |
push(ds); | |
push(di); | |
push(si); | |
if (cx == 0) | |
goto loc_15faf; | |
stop(); // lds si, ptr [bp + 0xa] | |
stop(); // les di, ptr [bp + 6] | |
loc_15f6d: | |
ax = cx; | |
ax--; | |
dx = di; | |
dx = ~dx; | |
flags.carry = ax < dx; | |
ax -= dx; | |
bx -= bx + flags.carry; | |
ax &= bx; | |
ax += dx; | |
dx = si; | |
dx = ~dx; | |
flags.carry = ax < dx; | |
ax -= dx; | |
bx -= bx + flags.carry; | |
ax &= bx; | |
ax += dx; | |
ax++; | |
tx = ax; | |
ax = cx; | |
cx = tx; | |
ax -= cx; | |
cx >>= 1; | |
rep_movsw<MemAuto, MemAuto, DirAuto>(); | |
stop(/*8*/); // inject carry failed | |
cx += cx + flags.carry; | |
rep_movsb<MemAuto, MemAuto, DirAuto>(); | |
tx = ax; | |
ax = cx; | |
cx = tx; | |
if (cx == 0) | |
goto loc_15faf; | |
if (si) | |
goto loc_15fa2; | |
ax = ds; | |
ax += 0x1000; | |
ds = ax; | |
loc_15fa2: | |
if (di) | |
goto loc_15f6d; | |
ax = es; | |
ax += 0x1000; | |
es = ax; | |
goto loc_15f6d; | |
loc_15faf: | |
ax = memoryAGet16(ss, bp + 6- 2); | |
dx = memoryAGet16(ss, bp + 8- 2); | |
si = pop(); | |
di = pop(); | |
ds = pop(); | |
bp = pop(); | |
} | |
void sub_16066() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0012; | |
push(di); | |
push(si); | |
ax = memoryAGet16(ss, bp + 6- 2); | |
dx = memoryAGet16(ss, bp + 8- 2); | |
memoryASet16(ss, bp - 18- 2, ax); | |
memoryASet16(ss, bp - 16- 2, dx); | |
goto loc_1607f; | |
loc_1607c: | |
memoryASet16(ss, bp - 18- 2, memoryAGet16(ss, bp - 18- 2) + 1); | |
loc_1607f: | |
stop(); // les bx, ptr [bp - 0x12] | |
al = memoryAGet(es, bx); | |
cbw(); | |
bx = ax; | |
if (memoryAGet(ds, bx + 12675) & 0x08) | |
goto loc_1607c; | |
ax = 0; | |
push(ax); | |
push(ax); | |
push(es); | |
push(memoryAGet16(ss, bp - 18- 2)); | |
push(cs); | |
sub_1595c(); | |
sp += 0x0004; | |
push(ax); | |
push(memoryAGet16(ss, bp - 16- 2)); | |
push(memoryAGet16(ss, bp - 18- 2)); | |
push(cs); | |
sub_17ef8(); | |
sp += 0x000a; | |
memoryASet16(ss, bp - 4- 2, ax); | |
memoryASet16(ss, bp - 2- 2, dx); | |
ax = memoryAGet16(ss, bp + 12- 2); | |
ax |= memoryAGet16(ss, bp + 10- 2); | |
if (!ax) | |
goto loc_160d3; | |
stop(); // les bx, ptr [bp - 4] | |
ax = memoryAGet16(es, bx + 2); | |
ax += memoryAGet16(ss, bp - 18- 2); | |
dx = memoryAGet16(ss, bp - 16- 2); | |
stop(); // les bx, ptr [bp + 0xa] | |
memoryASet16(es, bx, ax); | |
memoryASet16(es, bx + 2, dx); | |
loc_160d3: | |
stop(); // les bx, ptr [bp - 4] | |
ax = memoryAGet16(es, bx); | |
memoryASet16(ss, bp - 14- 2, ax); | |
if (!(ax & 0x0240)) | |
goto loc_1610a; | |
stop(); // lea di, [bp - 0xc] | |
si = 0x3598; | |
ax = ss; | |
es = ax; | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
ax = memoryAGet16(ss, bp + 12- 2); | |
ax |= memoryAGet16(ss, bp + 10- 2); | |
if (!ax) | |
goto loc_1616c; | |
ax = memoryAGet16(ss, bp + 6- 2); | |
dx = memoryAGet16(ss, bp + 8- 2); | |
stop(); // les bx, ptr [bp + 0xa] | |
memoryASet16(es, bx, ax); | |
memoryASet16(es, bx + 2, dx); | |
goto loc_1616c; | |
// gap of 1 bytes | |
loc_1610a: | |
if (!(memoryAGet(ss, bp - 14- 2) & 0x81)) | |
goto loc_16148; | |
stop(); // les bx, ptr [bp - 0x12] | |
if (memoryAGet(es, bx) != 0x2d) | |
goto loc_16132; | |
stop(); // lea bx, [0x34f0] | |
push(cs); | |
sub_17b1c(); | |
push(cs); | |
sub_17b10(); | |
stop(); // lea bx, [bp - 0xc] | |
push(cs); | |
sub_17c42(); | |
goto loc_16140; | |
// gap of 1 bytes | |
loc_16132: | |
stop(); // lea di, [bp - 0xc] | |
si = 0x34f0; | |
loc_16138: | |
ax = ss; | |
es = ax; | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
loc_16140: | |
memoryASet16(ds, 0x2e9e, 0x0022); | |
goto loc_1616c; | |
loc_16148: | |
if (!(memoryAGet(ss, bp - 13- 2) & 0x01)) | |
goto loc_16156; | |
stop(); // lea di, [bp - 0xc] | |
si = 0x3598; | |
goto loc_16138; | |
loc_16156: | |
ax = bx; | |
dx = es; | |
ax += 0x0008; | |
stop(); // lea di, [bp - 0xc] | |
si = ax; | |
push(ss); | |
es = pop(); | |
push(ds); | |
ds = dx; | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
ds = pop(); | |
loc_1616c: | |
ax = 0x4b70; | |
di = ax; | |
stop(); // lea si, [bp - 0xc] | |
push(ds); | |
es = pop(); | |
push(ds); | |
push(ss); | |
ds = pop(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
ds = pop(); | |
dx = ds; | |
si = pop(); | |
di = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_16186() | |
{ | |
ax = bp; | |
bp = sp; | |
dx = ds; | |
stop(); // lds bx, ptr [bp + 4] | |
memoryASet16(ds, bx, ax); | |
memoryASet16(ds, bx + 2, di); | |
memoryASet16(ds, bx + 4, si); | |
memoryASet16(ds, bx + 6, sp); | |
cx = memoryAGet16(ss, bp- 2); | |
memoryASet16(ds, bx + 8, cx); | |
cx = memoryAGet16(ss, bp + 2- 2); | |
memoryASet16(ds, bx + 10, cx); | |
memoryASet16(ds, bx + 12, dx); | |
ds = dx; | |
bp = ax; | |
ax = 0; | |
} | |
void sub_161b0() | |
{ | |
bp = sp; | |
ax = memoryAGet16(ss, bp + 8- 2); | |
if (ax) | |
goto loc_161ba; | |
ax++; | |
loc_161ba: | |
stop(); // lds bx, ptr [bp + 4] | |
di = memoryAGet16(ds, bx + 2); | |
si = memoryAGet16(ds, bx + 4); | |
sp = memoryAGet16(ds, bx + 6); | |
bp = sp; | |
cx = memoryAGet16(ds, bx + 8); | |
memoryASet16(ss, bp- 2, cx); | |
cx = memoryAGet16(ds, bx + 10); | |
memoryASet16(ss, bp + 2- 2, cx); | |
bp = memoryAGet16(ds, bx); | |
ds = memoryAGet16(ds, bx + 12); | |
} | |
void sub_161f6() | |
{ | |
goto loc_161f6; | |
loc_1425e: | |
if (stop(/*1*/)) | |
goto loc_14275; | |
ax = 0; | |
sp = bp; | |
bp = pop(); | |
return; | |
// gap of 15 bytes | |
loc_14275: | |
sub_14286(); | |
ax = 0xffff; | |
dx = ax & 0x8000 ? 0xffff : 0x0000; | |
sp = bp; | |
bp = pop(); | |
return; | |
// gap of 8054 bytes | |
loc_161f6: | |
push(bp); | |
bp = sp; | |
push(ds); | |
stop(); // lds dx, ptr [bp + 6] | |
ah = 0x41; | |
interrupt(0x21); | |
ds = pop(); | |
goto loc_1425e; | |
} | |
void sub_16206() | |
{ | |
ch = 0; | |
if (cx == 0) | |
return; | |
loc_1620a: | |
ax <<= 1; | |
stop(/*carry*/); | |
dx = rcl(dx, 0x0001); | |
if (--cx) | |
goto loc_1620a; | |
} | |
void sub_1621e() | |
{ | |
push(bp); | |
bp = sp; | |
push(bx); | |
bx = memoryAGet16(ss, bp + 6- 2); | |
ax = memoryAGet16(ds, bx); | |
dx = memoryAGet16(ds, bx + 2); | |
cx = memoryAGet16(ss, bp + 8- 2); | |
push(cs); | |
sub_16206(); | |
memoryASet16(ds, bx, ax); | |
memoryASet16(ds, bx + 2, dx); | |
bx = pop(); | |
bp = pop(); | |
sp += 4; | |
} | |
void sub_17b10() | |
{ | |
goto loc_17b10; | |
loc_17ae4: | |
interrupt(0x3d); | |
sp = bp; | |
bp = pop(); | |
return; | |
// gap of 36 bytes | |
loc_17b10: | |
push(bp); | |
bp = sp; | |
interrupt(0x35); | |
if (--cx && !flags.zero) | |
goto loc_17ae4; | |
bp = pop(); | |
} | |
void sub_17b1c() | |
{ | |
push(bp); | |
bp = sp; | |
interrupt(0x39); | |
es = pop(); | |
interrupt(0x3d); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_17c42() | |
{ | |
push(ss); | |
es = pop(); | |
push(bp); | |
bp = sp; | |
interrupt(0x3c); | |
stop(); // fstp qword ptr [bx] | |
interrupt(0x3d); | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_17e7c() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0004; | |
push(di); | |
interrupt(0x35); | |
loc_17e85: | |
if (stop(/*1*/)) | |
goto loc_17e85; | |
interrupt(0x3d); | |
ax = memoryAGet16(ss, bp - 2- 2); | |
ah &= 0xf3; | |
ah |= 0x04; | |
memoryASet16(ss, bp - 4- 2, ax); | |
interrupt(0x35); | |
stop(); // outsb dx, byte ptr [si] | |
flags.direction = false; | |
interrupt(0x35); | |
flags.direction = false; | |
interrupt(0x35); | |
stop(); // outsb dx, byte ptr [si] | |
ch--; | |
in(ax, 0x005d); | |
} | |
void sub_17ea7() | |
{ | |
push(bp); | |
bp = sp; | |
push(di); | |
interrupt(0x39); | |
si++; | |
push(es); | |
push(cs); | |
sub_17e7c(); | |
di = 0x2e94; | |
stop(/*74*/); | |
interrupt(0x39); | |
ax -= 0x8c97 + flags.carry; | |
stop(); // fcmove st(0), st(5) | |
in(ax, 0x005d); | |
} | |
void sub_17ef8() | |
{ | |
push(bp); | |
bp = sp; | |
sp -= 0x0006; | |
ax = 0x4b84; | |
push(ds); | |
push(ax); | |
stop(); // lea ax, [bp - 6] | |
push(ss); | |
push(ax); | |
push(memoryAGet16(ss, bp + 8- 2)); | |
push(memoryAGet16(ss, bp + 6- 2)); | |
ax = 0; | |
push(ax); | |
sub_1711e(); | |
memoryASet16(ss, bp - 2- 2, ax); | |
ax = memoryAGet16(ss, bp - 6- 2); | |
ax -= memoryAGet16(ss, bp + 6- 2); | |
memoryASet16(ds, 0x4b7e, ax); | |
memoryASet16(ds, 0x4b7c, 0x0000); | |
if (!(memoryAGet(ss, bp - 2- 2) & 0x04)) | |
goto loc_17f32; | |
memoryASet16(ds, 0x4b7c, 0x0200); | |
loc_17f32: | |
if (!(memoryAGet(ss, bp - 2- 2) & 0x02)) | |
goto loc_17f3d; | |
memoryASet(ds, 0x4b7c, memoryAGet(ds, 0x4b7c) | 0x01); | |
loc_17f3d: | |
if (!(memoryAGet(ss, bp - 2- 2) & 0x01)) | |
goto loc_17f48; | |
memoryASet(ds, 0x4b7d, memoryAGet(ds, 0x4b7d) | 0x01); | |
loc_17f48: | |
ax = 0x4b7c; | |
dx = ds; | |
sp = bp; | |
bp = pop(); | |
} | |
void sub_17fe2() | |
{ | |
push(bp); | |
bp = sp; | |
push(si); | |
push(di); | |
stop(); // lea si, [bp + 6] | |
di = 0x2e94; | |
ax = ds; | |
es = ax; | |
flags.direction = false; | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
movsw<MemAuto, MemAuto, DirAuto>(); | |
memoryASet(ds, di + 65535, memoryAGet(ds, di + 65535) & 0x7f); | |
ax = 0x2e94; | |
dx = ds; | |
di = pop(); | |
si = pop(); | |
sp = bp; | |
bp = pop(); | |
} | |
Program ended with exit code: 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment