diff --git a/nemu/src/monitor/sdb/sdb.c b/nemu/src/monitor/sdb/sdb.c index b2f7341..d1b57c7 100644 --- a/nemu/src/monitor/sdb/sdb.c +++ b/nemu/src/monitor/sdb/sdb.c @@ -17,6 +17,7 @@ #include #include #include +#include #include "sdb.h" static int is_batch_mode = false; @@ -53,6 +54,11 @@ static int cmd_q(char *args) { return -1; } +static int cmd_si(char *args) { + printf("%s", args); + return 0; +} + static int cmd_help(char *args); static struct { @@ -63,6 +69,7 @@ static struct { { "help", "Display information about all supported commands", cmd_help }, { "c", "Continue the execution of the program", cmd_c }, { "q", "Exit NEMU", cmd_q }, + { "si", "Single step [n] step", cmd_si }, /* TODO: Add more commands */