From a0d3cac4e69101669681a4d8af6dc3e8bd2c9a6a Mon Sep 17 00:00:00 2001 From: Kartik Agaram Date: Sun, 15 Sep 2019 00:01:26 -0700 Subject: 5659 --- html/011run.cc.html | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'html/011run.cc.html') diff --git a/html/011run.cc.html b/html/011run.cc.html index 4f30046d..b8a0963e 100644 --- a/html/011run.cc.html +++ b/html/011run.cc.html @@ -152,11 +152,11 @@ if ('onhashchange' in window) { 92 // convenience to keep tests concise: 'Entry' label need not be provided 93 // not allowed in real programs 94 if (p.entry) - 95 EIP = p.entry; + 95 EIP = p.entry; 96 else - 97 EIP = find(p, "code")->start; - 98 while (EIP < End_of_program) - 99 run_one_instruction(); + 97 EIP = find(p, "code")->start; + 98 while (EIP < End_of_program) + 99 run_one_instruction(); 100 } 101 102 //:: core data structures @@ -229,7 +229,7 @@ if ('onhashchange' in window) { 169 curr_segment->name = segment_name; 170 curr_segment->start = seg_start; 171 if (trace_contains_errors()) continue; -172 trace(3, "parse") << "starts at address 0x" << HEXWORD << curr_segment->start << end(); +172 trace(3, "parse") << "starts at address 0x" << HEXWORD << curr_segment->start << end(); 173 } 174 break; // skip rest of line 175 } @@ -330,8 +330,8 @@ if ('onhashchange' in window) { 270 const segment& seg = p.segments.at(i); 271 uint32_t addr = seg.start; 272 if (!already_allocated(addr)) -273 Mem.push_back(vma(seg.start)); -274 trace(99, "load") << "loading segment " << i << " from " << HEXWORD << addr << end(); +273 Mem.push_back(vma(seg.start)); +274 trace(99, "load") << "loading segment " << i << " from " << HEXWORD << addr << end(); 275 for (int j = 0; j < SIZE(seg.lines); ++j) { 276 const line& l = seg.lines.at(j); 277 for (int k = 0; k < SIZE(l.words); ++k) { @@ -339,14 +339,14 @@ if ('onhashchange' in window) { 279 uint8_t val = hex_byte(w.data); 280 if (trace_contains_errors()) return; 281 assert(overlap.find(addr) == overlap.end()); -282 write_mem_u8(addr, val); +282 write_mem_u8(addr, val); 283 overlap.insert(addr); -284 trace(99, "load") << "0x" << HEXWORD << addr << " -> " << HEXBYTE << NUM(read_mem_u8(addr)) << end(); +284 trace(99, "load") << "0x" << HEXWORD << addr << " -> " << HEXBYTE << NUM(read_mem_u8(addr)) << end(); 285 ++addr; 286 } 287 } 288 if (seg.name == "code") { -289 End_of_program = addr; +289 End_of_program = addr; 290 } 291 } 292 } @@ -479,15 +479,15 @@ if ('onhashchange' in window) { 419 //:: run 420 421 :(before "End Initialize Op Names") -422 put_new(Name, "b8", "copy imm32 to EAX (mov)"); +422 put_new(Name, "b8", "copy imm32 to EAX (mov)"); 423 424 //: our first opcode 425 426 :(before "End Single-Byte Opcodes") 427 case 0xb8: { // copy imm32 to EAX 428 const int32_t src = next32(); -429 trace(Callstack_depth+1, "run") << "copy imm32 0x" << HEXWORD << src << " to EAX" << end(); -430 Reg[EAX].i = src; +429 trace(Callstack_depth+1, "run") << "copy imm32 0x" << HEXWORD << src << " to EAX" << end(); +430 Reg[EAX].i = src; 431 break; 432 } 433 @@ -505,7 +505,7 @@ if ('onhashchange' in window) { 445 446 // read a 32-bit int in little-endian order from the instruction stream 447 int32_t next32() { -448 int32_t result = read_mem_i32(EIP); +448 int32_t result = read_mem_i32(EIP); 449 EIP+=4; 450 return result; 451 } -- cgit 1.4.1-2-gfad0