x86: StaticRounding implies SAE
authorJan Beulich <jbeulich@suse.com>
Mon, 1 Jul 2019 06:31:50 +0000 (08:31 +0200)
committerJan Beulich <jbeulich@suse.com>
Mon, 1 Jul 2019 06:31:50 +0000 (08:31 +0200)
This implication allows to simplify some conditionals, thus slightly
improving performance. This change also paves the way for re-using
StaticRounding for non-EVEX insns.

gas/ChangeLog
gas/config/tc-i386.c

index b969177059893e12809290385018a716aeb1e175..c6fcecb2668292f273af2f53a3dd4e4ee9d2e1e5 100644 (file)
@@ -1,3 +1,8 @@
+2019-07-01  Jan Beulich  <jbeulich@suse.com>
+
+       * config/tc-i386.c (is_evex_encoding): Don't check for SAE.
+       (check_VecOperands): Simplify static rounding / SAE checking.
+
 2019-07-01  Jan Beulich  <jbeulich@suse.com>
 
        * config/tc-i386.c (optimize_encoding): Make j unsigned.  Handle
index bc7d55611a101d2adc27cb41f991ea1a212b44ec..fe50566d86b2b2fe45c56da3fce616ff0b150994 100644 (file)
@@ -3557,7 +3557,7 @@ is_evex_encoding (const insn_template *t)
 {
   return t->opcode_modifier.evex || t->opcode_modifier.disp8memshift
         || t->opcode_modifier.broadcast || t->opcode_modifier.masking
-        || t->opcode_modifier.staticrounding || t->opcode_modifier.sae;
+        || t->opcode_modifier.sae;
 }
 
 static INLINE bfd_boolean
@@ -5469,11 +5469,8 @@ check_VecOperands (const insn_template *t)
   /* Check RC/SAE.  */
   if (i.rounding)
     {
-      if ((i.rounding->type != saeonly
-          && !t->opcode_modifier.staticrounding)
-         || (i.rounding->type == saeonly
-             && (t->opcode_modifier.staticrounding
-                 || !t->opcode_modifier.sae)))
+      if (!t->opcode_modifier.sae
+         || (i.rounding->type != saeonly && !t->opcode_modifier.staticrounding))
        {
          i.error = unsupported_rc_sae;
          return 1;
This page took 0.029868 seconds and 4 git commands to generate.