{
default:
abort ();
- case 0:
+ case HLEPrefixNone:
if (i.prefix[HLE_PREFIX] == XACQUIRE_PREFIX_OPCODE)
as_bad (_("invalid instruction `%s' after `xacquire'"),
i.tm.name);
as_bad (_("invalid instruction `%s' after `xrelease'"),
i.tm.name);
return 0;
- case 1:
+ case HLEPrefixLock:
if (i.prefix[LOCK_PREFIX])
return 1;
if (i.prefix[HLE_PREFIX] == XACQUIRE_PREFIX_OPCODE)
else
as_bad (_("missing `lock' with `xrelease'"));
return 0;
- case 2:
+ case HLEPrefixAny:
return 1;
- case 3:
+ case HLEPrefixRelease:
if (i.prefix[HLE_PREFIX] != XRELEASE_PREFIX_OPCODE)
{
as_bad (_("instruction `%s' after `xacquire' not allowed"),
err_msg = _("unsupported syntax");
break;
case unsupported:
- err_msg = _("unsupported");
- break;
+ as_bad (_("unsupported `%s'"),
+ current_templates->start->name);
+ return NULL;
case invalid_vsib_address:
err_msg = _("invalid VSIB address");
break;
unsigned int prefix;
/* Since the VEX prefix contains the implicit prefix, we don't
- need the explicit prefix. */
+ need the explicit prefix. */
if (!i.tm.opcode_modifier.vex)
{
switch (i.tm.opcode_length)
if (*q)
FRAG_APPEND_1_CHAR (*q);
}
-
- if (i.tm.opcode_modifier.vex)
+ else
{
for (j = 0, q = i.prefix; j < ARRAY_SIZE (i.prefix); j++, q++)
if (*q)
return 1; /* Normal return. */
}
\f
+/* Calculate the maximum variable size (i.e., excluding fr_fix)
+ that an rs_machine_dependent frag may reach. */
+
+unsigned int
+i386_frag_max_var (fragS *frag)
+{
+ /* The only relaxable frags are for jumps.
+ Unconditional jumps can grow by 4 bytes and others by 5 bytes. */
+ gas_assert (frag->fr_type == rs_machine_dependent);
+ return TYPE_FROM_RELAX_STATE (frag->fr_subtype) == UNCOND_JUMP ? 4 : 5;
+}
+
/* md_estimate_size_before_relax()
Called just before relax() for rs_machine_dependent frags. The x86