187 |
FREETMPS; |
FREETMPS; |
188 |
LEAVE; |
LEAVE; |
189 |
cycles = SvIV( get_sv("M6502::run_for", FALSE) ); |
cycles = SvIV( get_sv("M6502::run_for", FALSE) ); |
190 |
printf("run CPU for %d cycles\n", cycles); |
if ( cycles > 0 ) { |
191 |
dump_R; |
printf("run CPU for %d cycles\n", cycles); |
192 |
//Run6502(R); |
dump_R; |
193 |
Exec6502(R, cycles); |
//Run6502(R); |
194 |
dump_R; |
Exec6502(R, cycles); |
195 |
push_R(R); |
dump_R; |
196 |
printf("end of %d cycles CPU run\n", cycles); |
push_R(R); |
197 |
|
printf("end of %d cycles CPU run\n", cycles); |
198 |
|
} else { |
199 |
|
printf("no cpu cycles set for run\n"); |
200 |
|
cycles = 1; // never exit, prevents segfault |
201 |
|
} |
202 |
} |
} |
203 |
} |
} |
204 |
free(R); |
free(R); |