summaryrefslogtreecommitdiff
path: root/gdb/ia64-tdep.c
diff options
context:
space:
mode:
authorJoel Brobecker <brobecker@gnat.com>2009-09-28 23:56:52 +0000
committerJoel Brobecker <brobecker@gnat.com>2009-09-28 23:56:52 +0000
commit1e0df7fe54d6d5f3a2e921f1ddac64a19009756a (patch)
treec793045aad090eb7cb812eb0ccde3bba5d75cec4 /gdb/ia64-tdep.c
parentc81485b689a07dad8890db3c7288c7e5e5be7c50 (diff)
downloadgdb-1e0df7fe54d6d5f3a2e921f1ddac64a19009756a.tar.gz
* ia64-tdep.c (ia64_memory_insert_breakpoint): Check the slotnum
and the type of instruction before deciding which slot to save in the breakpoint shadown contents.
Diffstat (limited to 'gdb/ia64-tdep.c')
-rw-r--r--gdb/ia64-tdep.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/gdb/ia64-tdep.c b/gdb/ia64-tdep.c
index 674204a9321..bbde5f62054 100644
--- a/gdb/ia64-tdep.c
+++ b/gdb/ia64-tdep.c
@@ -635,6 +635,12 @@ ia64_memory_insert_breakpoint (struct gdbarch *gdbarch,
return val;
}
+ /* Check for L type instruction in slot 1, if present then bump up the slot
+ number to the slot 2. */
+ template = extract_bit_field (bundle, 0, 5);
+ if (slotnum == 1 && template_encoding_table[template][slotnum] == L)
+ slotnum = 2;
+
/* Slot number 2 may skip at most 2 bytes at the beginning. */
bp_tgt->shadow_len = BUNDLE_LEN - 2;
@@ -657,12 +663,6 @@ ia64_memory_insert_breakpoint (struct gdbarch *gdbarch,
return val;
}
- /* Check for L type instruction in slot 1, if present then bump up the slot
- number to the slot 2. */
- template = extract_bit_field (bundle, 0, 5);
- if (slotnum == 1 && template_encoding_table[template][slotnum] == L)
- slotnum = 2;
-
/* Breakpoints already present in the code will get deteacted and not get
reinserted by bp_loc_is_permanent. Multiple breakpoints at the same
location cannot induce the internal error as they are optimized into