summaryrefslogtreecommitdiff
path: root/plugins/arm
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/arm')
-rw-r--r--plugins/arm/v7/link.c12
-rw-r--r--plugins/arm/v7/opdefs/A8827_bx.d4
-rw-r--r--plugins/arm/v7/opdefs/A8828_bxj.d14
3 files changed, 28 insertions, 2 deletions
diff --git a/plugins/arm/v7/link.c b/plugins/arm/v7/link.c
index 4a63890..e30b0c1 100644
--- a/plugins/arm/v7/link.c
+++ b/plugins/arm/v7/link.c
@@ -62,7 +62,17 @@ void handle_armv7_conditional_branch_from_register(GArchInstruction *instr, GArc
g_arch_instruction_set_flag(instr, AIF_RETURN_POINT);
else
- g_arch_instruction_set_flag(instr, AIF_RETURN_POINT); /* FIXME : jump inconnu ! */
+ {
+ /**
+ * On fait un saut mais on ne sait pas vers où !
+ *
+ * Dans tous les cas, le flot d'exécution ne continue pas naturellement
+ * vers l'instruction suivante, donc on marque le branchement comme
+ * étant un point de retour.
+ */
+ g_arch_instruction_set_flag(instr, AIF_RETURN_POINT);
+
+ }
g_object_unref(G_OBJECT(reg));
diff --git a/plugins/arm/v7/opdefs/A8827_bx.d b/plugins/arm/v7/opdefs/A8827_bx.d
index 64ad628..337728f 100644
--- a/plugins/arm/v7/opdefs/A8827_bx.d
+++ b/plugins/arm/v7/opdefs/A8827_bx.d
@@ -52,6 +52,7 @@
@hooks {
fetch = help_fetching_with_instruction_bx_from_thumb
+ link = handle_armv7_conditional_branch_from_register
}
@@ -83,7 +84,8 @@
@hooks {
- fetch = help_fetching_with_instruction_bx_from_thumb
+ fetch = help_fetching_with_instruction_bx_from_arm
+ link = handle_armv7_conditional_branch_from_register
}
diff --git a/plugins/arm/v7/opdefs/A8828_bxj.d b/plugins/arm/v7/opdefs/A8828_bxj.d
index 7c6ddb5..f3a1bb7 100644
--- a/plugins/arm/v7/opdefs/A8828_bxj.d
+++ b/plugins/arm/v7/opdefs/A8828_bxj.d
@@ -49,6 +49,13 @@
}
+ @hooks {
+
+ fetch = help_fetching_with_instruction_bx_from_thumb
+ link = handle_armv7_conditional_branch_from_register
+
+ }
+
}
@encoding (A1) {
@@ -75,5 +82,12 @@
}
+ @hooks {
+
+ fetch = help_fetching_with_instruction_bx_from_arm
+ link = handle_armv7_conditional_branch_from_register
+
+ }
+
}