+ prefix #field, (int)offsetof(type, field))
+
+#define DUMP_P(f, field) \
+ fprintf(f, "#define %-20s 0x%04x\n", \
+ "OFS_Pico_" #field, (char *)&p.field - (char *)&p)
+
+#define DUMP_PS(f, s1, field) \
+ fprintf(f, "#define %-20s 0x%04x\n", \
+ "OFS_Pico_" #s1 "_" #field, (char *)&p.s1.field - (char *)&p)
+
+#define DUMP_EST(f, field) \
+ DUMP(f, "OFS_EST_", struct PicoEState, field)
+
+#define DUMP_PMEM(f, field) \
+ DUMP(f, "OFS_PMEM_", struct PicoMem, field)
+
+extern struct Pico p;