aboutsummaryrefslogtreecommitdiff
path: root/gdb/values.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/values.c')
-rw-r--r--gdb/values.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/gdb/values.c b/gdb/values.c
index 3f9e7bb..404485d 100644
--- a/gdb/values.c
+++ b/gdb/values.c
@@ -1259,6 +1259,14 @@ value_from_longest (type, num)
case TYPE_CODE_PTR:
/* This assumes that all pointers of a given length
have the same form. */
+
+/* start-sanitize-d10v */
+#ifdef GDB_TARGET_IS_D10V
+ /* D10V function pointers need adjusted */
+ if (TYPE_TARGET_TYPE(type) && TYPE_CODE(TYPE_TARGET_TYPE(type)) == TYPE_CODE_FUNC)
+ num = D10V_MAKE_IADDR (num);
+#endif
+/* end-sanitize-d10v */
store_address (VALUE_CONTENTS_RAW (val), len, (CORE_ADDR) num);
break;