From: Haochen Jiang Date: Mon, 1 Sep 2025 02:54:28 +0000 (+0800) Subject: x86/testsuite: Adjust unused FRED and MOVRS tests [PR33348] X-Git-Tag: gdb-17-branchpoint~97 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=6c056e63c6a20977127a4cb53f61a15b150ffb55;p=thirdparty%2Fbinutils-gdb.git x86/testsuite: Adjust unused FRED and MOVRS tests [PR33348] The tests mentioned in PR33348 needs different care. For FRED tests, we could simply remove them since there are no operands and the tests are the same as AT&T Syntax. For MOVRS tests, we allowed suffixes for AT&T suffixes although we could tell the difference according to register operand to align with legacy mov. Thus, the suffixes tests are needed for AT&T Syntax while not needed for Intel Syntax. Adjust them accordingly. gas/ChangeLog: PR ld/33348 * testsuite/gas/i386/x86-64-movrs-suffix.d: Describe the test with more precise. * testsuite/gas/i386/x86-64-movrs-suffix.s: Remove Intel Syntax part. * testsuite/gas/i386/x86-64.exp: Add MOVRS suffix tests. * testsuite/gas/i386/x86-64-fred-intel.d: Removed. * testsuite/gas/i386/x86-64-movrs-suffix-intel.d: Ditto. --- diff --git a/gas/testsuite/gas/i386/x86-64-fred-intel.d b/gas/testsuite/gas/i386/x86-64-fred-intel.d deleted file mode 100644 index 0d8183eb0e8..00000000000 --- a/gas/testsuite/gas/i386/x86-64-fred-intel.d +++ /dev/null @@ -1,14 +0,0 @@ -#objdump: -dw -Mintel -#name: x86_64 FRED insns (Intel disassembly) -#source: x86-64-fred.s - -.*: +file format .* - -Disassembly of section \.text: - -0+ <_start>: -\s*[a-f0-9]+:\s*f2 0f 01 ca\s+erets -\s*[a-f0-9]+:\s*f3 0f 01 ca\s+eretu -\s*[a-f0-9]+:\s*f2 0f 01 ca\s+erets -\s*[a-f0-9]+:\s*f3 0f 01 ca\s+eretu -#pass diff --git a/gas/testsuite/gas/i386/x86-64-movrs-suffix-intel.d b/gas/testsuite/gas/i386/x86-64-movrs-suffix-intel.d deleted file mode 100644 index b1dcb2db898..00000000000 --- a/gas/testsuite/gas/i386/x86-64-movrs-suffix-intel.d +++ /dev/null @@ -1,15 +0,0 @@ -#objdump: -dwMsuffix -Mintel -#name: x86_64 MOVRS insns -#source: x86-64-movrs-suffix.s - -.*: +file format .* - -Disassembly of section \.text: - -#... -[a-f0-9]+ <_intel>: -\s*[a-f0-9]+:\s*66 0f 38 8b 92 00 ff ff ff\s+movrsw -0x100\(%rdx\),%dx -\s*[a-f0-9]+:\s*0f 38 8b 92 00 fe ff ff\s+movrsl -0x200\(%rdx\),%edx -\s*[a-f0-9]+:\s*4c 0f 38 8b a2 00 fc ff ff\s+movrsq -0x400\(%rdx\),%r12 -\s*[a-f0-9]+:\s*0f 38 8a 5a 80\s+movrsb -0x80\(%rdx\),%bl -#pass diff --git a/gas/testsuite/gas/i386/x86-64-movrs-suffix.d b/gas/testsuite/gas/i386/x86-64-movrs-suffix.d index 7f71b1dfbd0..d43a368a6ed 100644 --- a/gas/testsuite/gas/i386/x86-64-movrs-suffix.d +++ b/gas/testsuite/gas/i386/x86-64-movrs-suffix.d @@ -1,5 +1,5 @@ #objdump: -dwMsuffix -#name: x86_64 MOVRS insns +#name: x86_64 MOVRS insns (w/ suffix) .*: +file format .* diff --git a/gas/testsuite/gas/i386/x86-64-movrs-suffix.s b/gas/testsuite/gas/i386/x86-64-movrs-suffix.s index 6120b768d7c..d4f03ea2c91 100644 --- a/gas/testsuite/gas/i386/x86-64-movrs-suffix.s +++ b/gas/testsuite/gas/i386/x86-64-movrs-suffix.s @@ -6,10 +6,3 @@ _start: movrsl -512(%rdx), %edx movrsq -1024(%rdx), %r12 movrsb -128(%rdx), %bl - -_intel: - .intel_syntax noprefix - movrsw dx, WORD PTR [rdx-256] - movrsl edx, DWORD PTR [rdx-512] - movrsq r12, QWORD PTR [rdx-1024] - movrsb bl, BYTE PTR [rdx-128] diff --git a/gas/testsuite/gas/i386/x86-64.exp b/gas/testsuite/gas/i386/x86-64.exp index d24e9101184..fd42263e59a 100644 --- a/gas/testsuite/gas/i386/x86-64.exp +++ b/gas/testsuite/gas/i386/x86-64.exp @@ -539,6 +539,7 @@ run_dump_test "x86-64-amx-avx512" run_dump_test "x86-64-amx-avx512-intel" run_dump_test "x86-64-movrs" run_dump_test "x86-64-movrs-intel" +run_dump_test "x86-64-movrs-suffix" run_dump_test "x86-64-movrs-avx10_2-512" run_dump_test "x86-64-movrs-avx10_2-512-intel" run_dump_test "x86-64-movrs-avx10_2-256"