• R/O
  • HTTP
  • SSH
  • HTTPS

提交

标签
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

GNU Binutils with patches for OS216


Commit MetaInfo

修订版33d0ab95489cb3cf7ec98bee63c3541b5295adb6 (tree)
时间2016-07-05 18:14:51
作者Jan Beulich <jbeulich@nove...>
CommiterJan Beulich

Log Message

x86: fix register check in check_qword_reg()

A missing 'r' (or wrong 'e') register prefix needs to be complained
about if the template allows for a 64-bit register, not a 32-bit one.
I assume this was a copy-and-paste type of mistake
(from check_long_reg()).

更改概述

差异

--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,12 @@
1+2016-07-04 Jan Beulich <jbeulich@suse.com>
2+
3+ * config/tc-i386.c (check_qword_reg): Correct register kind
4+ checked.
5+ * testsuite/gas/i386/x86-64-suffix-bad.s: Add q-suffix with
6+ 16-bit register cases.
7+ * testsuite/gas/i386/x86-64-suffix-bad.l: Adjust expectations.
8+
9+
110 2016-07-02 Maciej W. Rozycki <macro@imgtec.com>
211
312 * testsuite/gas/mips/ecoff@ld.d: Remove test.
--- a/gas/config/tc-i386.c
+++ b/gas/config/tc-i386.c
@@ -5670,7 +5670,7 @@ check_qword_reg (void)
56705670 /* Warn if the r prefix on a general reg is missing. */
56715671 else if ((i.types[op].bitfield.reg16
56725672 || i.types[op].bitfield.reg32)
5673- && (i.tm.operand_types[op].bitfield.reg32
5673+ && (i.tm.operand_types[op].bitfield.reg64
56745674 || i.tm.operand_types[op].bitfield.acc))
56755675 {
56765676 /* Prohibit these changes in the 64bit mode, since the
--- a/gas/testsuite/gas/i386/x86-64-suffix-bad.l
+++ b/gas/testsuite/gas/i386/x86-64-suffix-bad.l
@@ -11,3 +11,7 @@
1111 .*:15: Error: .*
1212 .*:16: Error: .*
1313 .*:17: Error: .*
14+.*:19: Error: .*
15+.*:20: Error: .*
16+.*:21: Error: .*
17+.*:22: Error: .*
--- a/gas/testsuite/gas/i386/x86-64-suffix-bad.s
+++ b/gas/testsuite/gas/i386/x86-64-suffix-bad.s
@@ -15,3 +15,8 @@ start:
1515 orb %rax, (%rax)
1616 orw %rax, (%rax)
1717 orl %rax, (%rax)
18+
19+ pushq %ax
20+ popq %ax
21+ callq *%ax
22+ jmpq *%ax