aboutsummaryrefslogtreecommitdiff
path: root/gdb/features
diff options
context:
space:
mode:
authorFelix Willgerodt <felix.willgerodt@intel.com>2021-07-21 14:38:04 +0200
committerFelix Willgerodt <felix.willgerodt@intel.com>2021-09-03 14:50:16 +0200
commit41bbbb89c4d31a15ef317dd7de8af749d2a35e5f (patch)
treeb503ba2a952da0940f8b87c2533e5f6d97226665 /gdb/features
parent41e37c9d0ac9dfbdaf725112d510cb10e5854f3d (diff)
downloadgdb-41bbbb89c4d31a15ef317dd7de8af749d2a35e5f.zip
gdb-41bbbb89c4d31a15ef317dd7de8af749d2a35e5f.tar.gz
gdb-41bbbb89c4d31a15ef317dd7de8af749d2a35e5f.tar.bz2
gdb, i386: Enable AVX512-bfloat16 for i386 targets.
Values of type bfloat16 can also be used on 32-bit targets, which was missed in the original enablement. This also adjusts the testcase to pass with "unix/-m32", where only the lower 8 AVX registers are available. gdb/ChangeLog: 2021-07-21 Felix Willgerodt <Felix.Willgerodt@intel.com> * features/i386/32bit-sse.xml: Add bfloat16 type. * features/i386/32bit-sse.c: Regenerated. gdb/testsuite/ChangeLog: 2021-07-21 Felix Willgerodt <Felix.Willgerodt@intel.com> * gdb.arch/x86-avx512bf16.exp: Only use x/z/ymm 0-7.
Diffstat (limited to 'gdb/features')
-rw-r--r--gdb/features/i386/32bit-sse.c5
-rw-r--r--gdb/features/i386/32bit-sse.xml2
2 files changed, 7 insertions, 0 deletions
diff --git a/gdb/features/i386/32bit-sse.c b/gdb/features/i386/32bit-sse.c
index e5eaf8f..b6d5fba 100644
--- a/gdb/features/i386/32bit-sse.c
+++ b/gdb/features/i386/32bit-sse.c
@@ -10,6 +10,9 @@ create_feature_i386_32bit_sse (struct target_desc *result, long regnum)
feature = tdesc_create_feature (result, "org.gnu.gdb.i386.sse");
tdesc_type *element_type;
+ element_type = tdesc_named_type (feature, "bfloat16");
+ tdesc_create_vector (feature, "v8bf16", element_type, 8);
+
element_type = tdesc_named_type (feature, "ieee_single");
tdesc_create_vector (feature, "v4f", element_type, 4);
@@ -31,6 +34,8 @@ create_feature_i386_32bit_sse (struct target_desc *result, long regnum)
tdesc_type_with_fields *type_with_fields;
type_with_fields = tdesc_create_union (feature, "vec128");
tdesc_type *field_type;
+ field_type = tdesc_named_type (feature, "v8bf16");
+ tdesc_add_field (type_with_fields, "v8_bfloat16", field_type);
field_type = tdesc_named_type (feature, "v4f");
tdesc_add_field (type_with_fields, "v4_float", field_type);
field_type = tdesc_named_type (feature, "v2d");
diff --git a/gdb/features/i386/32bit-sse.xml b/gdb/features/i386/32bit-sse.xml
index 7bf3e0f..8710622 100644
--- a/gdb/features/i386/32bit-sse.xml
+++ b/gdb/features/i386/32bit-sse.xml
@@ -7,6 +7,7 @@
<!DOCTYPE feature SYSTEM "gdb-target.dtd">
<feature name="org.gnu.gdb.i386.sse">
+ <vector id="v8bf16" type="bfloat16" count="8"/>
<vector id="v4f" type="ieee_single" count="4"/>
<vector id="v2d" type="ieee_double" count="2"/>
<vector id="v16i8" type="int8" count="16"/>
@@ -14,6 +15,7 @@
<vector id="v4i32" type="int32" count="4"/>
<vector id="v2i64" type="int64" count="2"/>
<union id="vec128">
+ <field name="v8_bfloat16" type="v8bf16"/>
<field name="v4_float" type="v4f"/>
<field name="v2_double" type="v2d"/>
<field name="v16_int8" type="v16i8"/>