On Sun, Aug 11, 2013 at 11:06 PM, Franck Jullien <[email protected]> wrote: > Hi, > > In the original patch we substituted the pc with the npc value while > flushing the pipe after a dbg_stall disassertion. This doesn't work > everytime because npc might not be always equal the the bp address. > > In this patch, we save the npc content when the dbg_stall occurs > (saved_npc). This value will be used to set the pc after a dbg_stall > disassertion.
Hi Franck, This makes sense. However, what happens if we hit a breakpoint and then set a new NPC via the debugger? It looks like we can resume from the saved PC only, and not a newly written one. I think you'll need a mechanism for detecting a write to the NPC while the CPU is stalled and resuming from that address. Also, this saved address doesn't look like it's accessible by reading the NPC in SPR space. Surely being able to read the actual NPC you're going to resume from is important. I presume the NPC register doesn't hold the right value here, and if so, that's not great. Or maybe I'm not reading the patch correctly? Oh, one more small thing - patches inline next time please ;) > > BTW, I finally submitted the openocd OpenRISC port > (http://openocd.zylin.com/#/c/1547/). It has been a long road before > required changes were applied.... > I'll post some informations on the openocd tcl configuration files > very soon. As a matter of fact, as we can choose which cores to use, > there is some new configurations commands (see here: > https://github.com/Franck79/openOCD/blob/auto_tdesc/or1k_usb_blaster_adv.tcl). Great effort mate! You deserve a beer or three at ORCONF ;) Cheers Julius > > Franck. > > _______________________________________________ > OpenRISC mailing list > [email protected] > http://lists.openrisc.net/listinfo/openrisc > _______________________________________________ OpenRISC mailing list [email protected] http://lists.openrisc.net/listinfo/openrisc
