summaryrefslogtreecommitdiffstats
path: root/recipes-devtools/gdb/files/0013-microblaze-Handle-framless-functions-in-determining-.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-devtools/gdb/files/0013-microblaze-Handle-framless-functions-in-determining-.patch')
-rw-r--r--recipes-devtools/gdb/files/0013-microblaze-Handle-framless-functions-in-determining-.patch40
1 files changed, 40 insertions, 0 deletions
diff --git a/recipes-devtools/gdb/files/0013-microblaze-Handle-framless-functions-in-determining-.patch b/recipes-devtools/gdb/files/0013-microblaze-Handle-framless-functions-in-determining-.patch
new file mode 100644
index 00000000..70dcbe43
--- /dev/null
+++ b/recipes-devtools/gdb/files/0013-microblaze-Handle-framless-functions-in-determining-.patch
@@ -0,0 +1,40 @@
1From: David Holsgrove <david.holsgrove@xilinx.com>
2Date: Thu, 7 Nov 2013 16:58:48 +1000
3Subject: microblaze: Handle framless functions in determining
4 prev reg
5
6Add check for cache->frameless_p in microblaze_frame_prev_register
7to handle frameless functions, and correct the behaviour of using
8'next' to step through debugging
9
10Signed-off-by: David Holsgrove <david.holsgrove@xilinx.com>
11Signed-off-by: Nagaraju Mekala <nagaraju.mekala@xilinx.com>
12Upstream-Status: Pending
13---
14 gdb/microblaze-tdep.c | 10 ++++++++++
15 1 file changed, 10 insertions(+)
16
17diff --git a/gdb/microblaze-tdep.c b/gdb/microblaze-tdep.c
18index f4b48a6..a85adea6 100644
19--- a/gdb/microblaze-tdep.c
20+++ b/gdb/microblaze-tdep.c
21@@ -577,6 +577,16 @@ microblaze_frame_prev_register (struct frame_info *this_frame,
22 return frame_unwind_got_constant (this_frame, regnum,
23 cache->register_offsets[MICROBLAZE_SP_REGNUM]);
24
25+ if (cache->frameless_p)
26+ {
27+ if (regnum == MICROBLAZE_PC_REGNUM)
28+ regnum = 15;
29+ if (regnum == MICROBLAZE_SP_REGNUM)
30+ regnum = 1;
31+ return trad_frame_get_prev_register (this_frame,
32+ cache->saved_regs, regnum);
33+ }
34+
35 if (regnum == MICROBLAZE_PC_REGNUM)
36 {
37 regnum = 15;
38--
391.7.9.5
40