From 2bf05e57303ade685e40991a7779de56ced5d46f Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Thu, 24 Sep 2009 16:37:09 +0000 Subject: gas/ 2009-09-24 H.J. Lu * config/tc-i386.c (build_vex_prefix): Check vex == 2 instead of vex256. opcodes/ 2009-09-24 H.J. Lu * i386-gen.c (opcode_modifiers): Remove Vex256. (set_bitfield): Handle XXX=V. * i386-opc.h (Vex): Update comments. (Vex256): Removed. (VexNDS): Updated. (i386_opcode_modifier): Change vex to 2 bits. Remove vex256. * i386-opc.tbl: Replace "Vex|Vex256" with Vex=2. * i386-tbl.h: Regenerated. --- opcodes/i386-gen.c | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) (limited to 'opcodes/i386-gen.c') diff --git a/opcodes/i386-gen.c b/opcodes/i386-gen.c index fb1c78e..337f93c 100644 --- a/opcodes/i386-gen.c +++ b/opcodes/i386-gen.c @@ -347,7 +347,6 @@ static bitfield opcode_modifiers[] = BITFIELD (Rex64), BITFIELD (Ugh), BITFIELD (Vex), - BITFIELD (Vex256), BITFIELD (VexNDS), BITFIELD (VexNDD), BITFIELD (VexW0), @@ -540,6 +539,29 @@ set_bitfield (const char *f, bitfield *array, int value, return; } + if (value) + { + const char *v = strchr (f, '='); + + if (v) + { + size_t n = v - f; + char *end; + + for (i = 0; i < size; i++) + if (strncasecmp (array[i].name, f, n) == 0) + { + value = strtol (v + 1, &end, 0); + if (*end == '\0') + { + array[i].value = value; + return; + } + break; + } + } + } + if (lineno != -1) fail (_("%s: %d: Unknown bitfield: %s\n"), filename, lineno, f); else -- cgit v1.1