This is the mail archive of the binutils-cvs@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] x86: avoid cpu_flags_match() bogusly setting CPU_FLAGS_ARCH_MATCH


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=bcb1753ee643a7d5ac136189f9bc06717dfdfb64

commit bcb1753ee643a7d5ac136189f9bc06717dfdfb64
Author: Jan Beulich <jbeulich@novell.com>
Date:   Thu Mar 8 08:44:12 2018 +0100

    x86: avoid cpu_flags_match() bogusly setting CPU_FLAGS_ARCH_MATCH

Diff:
---
 gas/ChangeLog        | 5 +++++
 gas/config/tc-i386.c | 6 ------
 2 files changed, 5 insertions(+), 6 deletions(-)

diff --git a/gas/ChangeLog b/gas/ChangeLog
index 78fafb6..683d1bc 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,5 +1,10 @@
 2018-03-08  Jan Beulich  <jbeulich@suse.com>
 
+	* config/tc-i386.c (cpu_flags_match): Drop "else" branches
+	setting CPU_FLAGS_ARCH_MATCH.
+
+2018-03-08  Jan Beulich  <jbeulich@suse.com>
+
 	* config/tc-i386.c (md_assemble): Extend SSE check conditional.
 	* testsuite/gas/i386/ilp32/x86-64-sse-check-none.d,
 	testsuite/gas/i386/ilp32/x86-64-sse-check-warn.d,
diff --git a/gas/config/tc-i386.c b/gas/config/tc-i386.c
index 4cf7b9d..0c0b591 100644
--- a/gas/config/tc-i386.c
+++ b/gas/config/tc-i386.c
@@ -1740,8 +1740,6 @@ cpu_flags_match (const insn_template *t)
 			match |= CPU_FLAGS_PCLMUL_MATCH;
 		    }
 		}
-	      else
-		match |= CPU_FLAGS_ARCH_MATCH;
 	    }
 	  else if (x.bitfield.cpuavx512vl)
 	    {
@@ -1752,11 +1750,7 @@ cpu_flags_match (const insn_template *t)
 		  cpu.bitfield.cpuavx512vl = 0;
 		  if (!cpu_flags_all_zero (&cpu))
 		    match |= CPU_FLAGS_32BIT_MATCH;
-		  else
-		    match |= CPU_FLAGS_ARCH_MATCH;
 		}
-	      else
-		match |= CPU_FLAGS_ARCH_MATCH;
 	    }
 	  else
 	    match |= CPU_FLAGS_32BIT_MATCH;


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]