aboutsummaryrefslogtreecommitdiff
path: root/gdb/rs6000-tdep.c
diff options
context:
space:
mode:
authorMichael Meissner <gnu@the-meissners.org>1995-03-02 21:51:30 +0000
committerMichael Meissner <gnu@the-meissners.org>1995-03-02 21:51:30 +0000
commitdc59e9828683ce04aa921cc9e7ee5f333c4c4fe3 (patch)
tree9e786eaf0b9797c70c3845a13c2e87675c6948f2 /gdb/rs6000-tdep.c
parent773033d2d2369f6a73ffd8dadd36ce687bfdb890 (diff)
downloadgdb-dc59e9828683ce04aa921cc9e7ee5f333c4c4fe3.zip
gdb-dc59e9828683ce04aa921cc9e7ee5f333c4c4fe3.tar.gz
gdb-dc59e9828683ce04aa921cc9e7ee5f333c4c4fe3.tar.bz2
Minor code cleanup in rs6000-tdep.c
Diffstat (limited to 'gdb/rs6000-tdep.c')
-rw-r--r--gdb/rs6000-tdep.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/gdb/rs6000-tdep.c b/gdb/rs6000-tdep.c
index f08c77d..e226f54 100644
--- a/gdb/rs6000-tdep.c
+++ b/gdb/rs6000-tdep.c
@@ -78,10 +78,14 @@ branch_dest (opcode, instr, pc, safety)
switch (opcode) {
case 18 :
immediate = ((instr & ~3) << 6) >> 6; /* br unconditional */
+ if (absolute)
+ dest = immediate;
+ else
+ dest = pc + immediate;
+ break;
case 16 :
- if (opcode != 18) /* br conditional */
- immediate = ((instr & ~3) << 16) >> 16;
+ immediate = ((instr & ~3) << 16) >> 16; /* br conditional */
if (absolute)
dest = immediate;
else