aboutsummaryrefslogtreecommitdiff
path: root/risu_reginfo_m68k.h
diff options
context:
space:
mode:
authorLaurent Vivier <laurent@vivier.eu>2017-02-07 19:33:53 +0100
committerPeter Maydell <peter.maydell@linaro.org>2017-02-10 15:21:09 +0000
commit8a75d66028f19454cd73037d9ada5b55ca175fee (patch)
treeaa7373d3fc0dff1f8f4778d632af84c03dcc7c60 /risu_reginfo_m68k.h
parenta24f700fba480908faf279725fd9fa8a64ad5306 (diff)
m68k: implement server and client side
This also adds the basic test file and the configuration update. This implementation can only test instructions with values in register and no memory access. Signed-off-by: Laurent Vivier <laurent@vivier.eu> Message-id: 20170207183356.17840-3-laurent@vivier.eu Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'risu_reginfo_m68k.h')
-rw-r--r--risu_reginfo_m68k.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/risu_reginfo_m68k.h b/risu_reginfo_m68k.h
new file mode 100644
index 0000000..9dd8f32
--- /dev/null
+++ b/risu_reginfo_m68k.h
@@ -0,0 +1,32 @@
+/*****************************************************************************
+ * Copyright (c) 2016 Laurent Vivier
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *****************************************************************************/
+
+#ifndef RISU_REGINFO_M68K_H
+#define RISU_REGINFO_M68K_H
+
+struct reginfo
+{
+ uint32_t faulting_insn;
+ uint32_t pc;
+ gregset_t gregs;
+ fpregset_t fpregs;
+};
+
+/* initialize structure from a ucontext */
+void reginfo_init(struct reginfo *ri, ucontext_t *uc);
+
+/* return 1 if structs are equal, 0 otherwise. */
+int reginfo_is_eq(struct reginfo *r1, struct reginfo *r2, ucontext_t *uc);
+
+/* print reginfo state to a stream */
+void reginfo_dump(struct reginfo *ri, int is_master);
+
+/* reginfo_dump_mismatch: print mismatch details to a stream, ret nonzero=ok */
+int reginfo_dump_mismatch(struct reginfo *m, struct reginfo *a, FILE *f);
+
+#endif /* RISU_REGINFO_M68K_H */