Failed assertion when stepping over instruction in gdbstub #11
Labels
No Label
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: OpenE2K/qemu-e2k#11
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
I'm running
qemu-e2k -g 1234 helloworld
and then attach to it. Issuingstepi
GDB command results inApplying the following patch makes the problem go away:
Hi.
396d746b93
should fix the problem but there is another one. Gdb cannot step in/over a syscall because recently in upstream was removed the function to check breakpoints.The workaround is to type
finish
command in gdb.This indeed does fix the initial problem for me, thanks!
Speaking of 396d746b93d5e5441a25f2bb767529c277cb7cd4, what is the point of added
e2k_proc_call(env, env->wd.size, env->ip, true);
call incase EXCP_DEBUG
?It changes
wsz
register, according to CPU dump.Gdb expects the frame from the interrupted procedure to be on procedure and chain stacks. We also need to manually restore it after returning from gdb.
Does that mean that after each
stepi
command I typed in GDB, I need to do some extra steps before continuing running the program?No, you do not have to do that. The frame is restored in
e2k_tr_tb_start
. You need to setenv->is_bp = true
and save the current frame whenEXCP_DEBUG
appears.Previously frame saving was done in
e2k_tr_breakpoint_check
, but this function has been removed in the upstream1b3e36f3e0
.Now it is clear, thanks for explanations!