aboutsummaryrefslogtreecommitdiff
path: root/gas/config
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@novell.com>2018-03-08 08:27:28 +0100
committerJan Beulich <jbeulich@suse.com>2018-03-08 08:27:28 +0100
commita477a8c4f4f7e827d32abc1fbb45bdb3c37cff09 (patch)
tree41f2de02cb003a38c106bb03594057d24ac5d562 /gas/config
parent2907c2f55555de6b1df9a0262629003f4856807d (diff)
downloadgdb-a477a8c4f4f7e827d32abc1fbb45bdb3c37cff09.zip
gdb-a477a8c4f4f7e827d32abc1fbb45bdb3c37cff09.tar.gz
gdb-a477a8c4f4f7e827d32abc1fbb45bdb3c37cff09.tar.bz2
x86: adjust 4-XMM-register-group related warning
Drop "second": For one there's no other source register (the other source operand is in memory), and in Intel syntax such numbering would also be wrong. Take the opportunity and also - properly place declarations ahead of statements - use %u format for unsigned int arguments - fix indentation
Diffstat (limited to 'gas/config')
-rw-r--r--gas/config/tc-i386.c25
1 files changed, 13 insertions, 12 deletions
diff --git a/gas/config/tc-i386.c b/gas/config/tc-i386.c
index 24fa4c7..3a21a35 100644
--- a/gas/config/tc-i386.c
+++ b/gas/config/tc-i386.c
@@ -6414,20 +6414,21 @@ duplicate:
}
else if (i.tm.opcode_modifier.implicitquadgroup)
{
+ unsigned int regnum, first_reg_in_group, last_reg_in_group;
+
/* The second operand must be {x,y,z}mmN, where N is a multiple of 4. */
gas_assert (i.operands >= 2 && i.types[1].bitfield.regsimd);
- unsigned int regnum = register_number (i.op[1].regs);
- unsigned int first_reg_in_group = regnum & ~3;
- unsigned int last_reg_in_group = first_reg_in_group + 3;
- if (regnum != first_reg_in_group) {
- as_warn (_("the second source register `%s%s' implicitly denotes"
- " `%s%.3s%d' to `%s%.3s%d' source group in `%s'"),
- register_prefix, i.op[1].regs->reg_name,
- register_prefix, i.op[1].regs->reg_name, first_reg_in_group,
- register_prefix, i.op[1].regs->reg_name, last_reg_in_group,
- i.tm.name);
- }
- }
+ regnum = register_number (i.op[1].regs);
+ first_reg_in_group = regnum & ~3;
+ last_reg_in_group = first_reg_in_group + 3;
+ if (regnum != first_reg_in_group)
+ as_warn (_("source register `%s%s' implicitly denotes"
+ " `%s%.3s%u' to `%s%.3s%u' source group in `%s'"),
+ register_prefix, i.op[1].regs->reg_name,
+ register_prefix, i.op[1].regs->reg_name, first_reg_in_group,
+ register_prefix, i.op[1].regs->reg_name, last_reg_in_group,
+ i.tm.name);
+ }
else if (i.tm.opcode_modifier.regkludge)
{
/* The imul $imm, %reg instruction is converted into