@@ -181,7 +181,7 @@ bool Debugger::checkDebugMessages(Module *m, RunningState *program_state) {
181
181
fflush (stdout);
182
182
183
183
printf (" Interrupt: %x\n " , *interruptData);
184
- this ->channel ->write (" Interrupt: %x\n " , *interruptData);
184
+ // this->channel->write("Interrupt: %x\n", *interruptData);
185
185
186
186
long start = 0 , size = 0 ;
187
187
switch (*interruptData) {
@@ -317,6 +317,8 @@ bool Debugger::checkDebugMessages(Module *m, RunningState *program_state) {
317
317
this ->transfer (m, interruptData);
318
318
free (interruptData);
319
319
this ->channel ->write (" Transferred!\n " );
320
+ // this->snapshot(m);
321
+ // exit(0);
320
322
break ;
321
323
case interruptProxyCall: {
322
324
this ->handleProxyCall (m, program_state, interruptData + 1 );
@@ -785,7 +787,7 @@ void Debugger::inspect(Module *m, const uint16_t sizeStateArray,
785
787
const uint8_t *state) const {
786
788
debug (" asked for inspect\n " );
787
789
uint16_t idx = 0 ;
788
- auto toVA = [m](uint8_t *addr) { return toVirtualAddress (addr, m) ; };
790
+ auto toVA = [m](uint8_t *addr) { return 0 ; };
789
791
bool addComma = false ;
790
792
791
793
this ->channel ->write (" {" );
@@ -1130,7 +1132,7 @@ void Debugger::load(uint8_t *bytes, Module *m) {
1130
1132
auto start = read_B8 (&bytes);
1131
1133
auto limit = read_B8 (&bytes);
1132
1134
auto total_bytes = limit - start + 1 ;
1133
- this -> channel -> write (" loading into %u - %u \n " , start, limit);
1135
+ printf (" loading into %u - %u \n " , start, limit);
1134
1136
memcpy (m->memory .bytes + start, bytes, total_bytes);
1135
1137
}
1136
1138
@@ -1493,6 +1495,9 @@ void Debugger::sendProxyCallResult(Module *m) const {
1493
1495
bool Debugger::isProxy () const { return this ->proxy != nullptr ; }
1494
1496
1495
1497
bool Debugger::isProxied (Module *m, const uint32_t fidx) const {
1498
+ if (this ->supervisor == nullptr ) {
1499
+ printf (" Has no supervisor!\n " );
1500
+ }
1496
1501
return this ->supervisor != nullptr && fidx < m->import_count ;
1497
1502
}
1498
1503
@@ -1695,7 +1700,7 @@ void Debugger::notifyCompleteStep(Module *m) const {
1695
1700
m->warduino ->debugger ->checkpoint (m);
1696
1701
}
1697
1702
this ->channel ->write (" STEP!\n " );
1698
- printf (" STEP!\n " );
1703
+ // printf("STEP!\n");
1699
1704
}
1700
1705
1701
1706
Debugger::~Debugger () {
0 commit comments