16-bit segment registers. */
#define AMD64_FBSD_SIZEOF_GREGSET (22 * 8)
+/* The segment base register set consists of 2 64-bit registers. */
+#define AMD64_FBSD_SIZEOF_SEGBASES_REGSET (2 * 8)
+
/* Register maps. */
static const struct regcache_map_entry amd64_fbsd_gregmap[] =
{ 0 }
};
+static const struct regcache_map_entry amd64_fbsd_segbases_regmap[] =
+{
+ { 1, AMD64_FSBASE_REGNUM, 0 },
+ { 1, AMD64_GSBASE_REGNUM, 0 },
+ { 0 }
+};
+
/* This layout including fsbase and gsbase was adopted in FreeBSD
8.0. */
amd64_fbsd_gregmap, regcache_supply_regset, regcache_collect_regset
};
+const struct regset amd64_fbsd_segbases_regset =
+{
+ amd64_fbsd_segbases_regmap, regcache_supply_regset, regcache_collect_regset
+};
+
/* Support for signal handlers. */
/* In a signal frame, rsp points to a 'struct sigframe' which is
&amd64_fbsd_gregset, NULL, cb_data);
cb (".reg2", tdep->sizeof_fpregset, tdep->sizeof_fpregset, &amd64_fpregset,
NULL, cb_data);
+ cb (".reg-x86-segbases", AMD64_FBSD_SIZEOF_SEGBASES_REGSET,
+ AMD64_FBSD_SIZEOF_SEGBASES_REGSET, &amd64_fbsd_segbases_regset,
+ "segment bases", cb_data);
cb (".reg-xstate", X86_XSTATE_SIZE (tdep->xcr0), X86_XSTATE_SIZE (tdep->xcr0),
&amd64fbsd_xstateregset, "XSAVE extended state", cb_data);
}
/* The general-purpose regset consists of 19 32-bit slots. */
#define I386_FBSD_SIZEOF_GREGSET (19 * 4)
+/* The segment base register set consists of 2 32-bit registers. */
+#define I386_FBSD_SIZEOF_SEGBASES_REGSET (2 * 4)
+
/* Register maps. */
static const struct regcache_map_entry i386_fbsd_gregmap[] =
{ 0 }
};
+static const struct regcache_map_entry i386_fbsd_segbases_regmap[] =
+{
+ { 1, I386_FSBASE_REGNUM, 0 },
+ { 1, I386_GSBASE_REGNUM, 0 },
+ { 0 }
+};
+
/* This layout including fsbase and gsbase was adopted in FreeBSD
8.0. */
i386_fbsd_gregmap, regcache_supply_regset, regcache_collect_regset
};
+const struct regset i386_fbsd_segbases_regset =
+{
+ i386_fbsd_segbases_regmap, regcache_supply_regset, regcache_collect_regset
+};
+
/* Support for signal handlers. */
/* In a signal frame, esp points to a 'struct sigframe' which is
&i386_fbsd_gregset, NULL, cb_data);
cb (".reg2", tdep->sizeof_fpregset, tdep->sizeof_fpregset, &i386_fpregset,
NULL, cb_data);
+ cb (".reg-x86-segbases", I386_FBSD_SIZEOF_SEGBASES_REGSET,
+ I386_FBSD_SIZEOF_SEGBASES_REGSET, &i386_fbsd_segbases_regset,
+ "segment bases", cb_data);
if (tdep->xcr0 & X86_XSTATE_AVX)
cb (".reg-xstate", X86_XSTATE_SIZE (tdep->xcr0),