Bug 16140 - gas generates nopl and nopw instructions with -march=k6_2
Summary: gas generates nopl and nopw instructions with -march=k6_2
Status: RESOLVED FIXED
Alias: None
Product: binutils
Classification: Unclassified
Component: gas (show other bugs)
Version: 2.23
: P2 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-11-07 23:49 UTC by Mikulas Patocka
Modified: 2013-11-08 18:06 UTC (History)
0 users

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mikulas Patocka 2013-11-07 23:49:52 UTC
The k6-2 processor doesn't support the nopl and nopw instructions with the code
0f 1f. Therefore, gas shouldn't use this instruction for alignment with
-march=k6_2

Example - compile the following source file with "as -march=k6_2 --32"
        .global main
main:
        xorl    %eax, %eax
        .balign 8
        ret
The result:
00000000 <main>:
   0:   31 c0                   xor    %eax,%eax
   2:   66 0f 1f 44 00 00       nopw   0x0(%eax,%eax,1)
   8:   c3                      ret
Comment 2 Sourceware Commits 2013-11-08 18:06:30 UTC
       via  9f4e1fadf3e75b8aa37744d2b06b29f8d6d1ca93 (commit)
      from  1d5dce8548bb3702e3f4a7672d1493a032a4c85c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

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

commit 9f4e1fadf3e75b8aa37744d2b06b29f8d6d1ca93
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Nov 8 09:42:08 2013 -0800

    Remove CpuNop from CPU_K6_2_FLAGS
    
    	PR gas/16140
    	* i386-gen.c (cpu_flag_init): Remove CpuNop from CPU_K6_2_FLAGS.
    	* i386-init.h: Regenerated.

-----------------------------------------------------------------------

Summary of changes:
 opcodes/ChangeLog   |    6 ++++++
 opcodes/i386-gen.c  |    2 +-
 opcodes/i386-init.h |    2 +-
 3 files changed, 8 insertions(+), 2 deletions(-)
Comment 3 Sourceware Commits 2013-11-08 18:06:38 UTC
       via  d56da83e58816c45a4bc70503776a6e62a66bf89 (commit)
      from  94d60ebd791e53124a664cdd534920c218b57b08 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

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

commit d56da83e58816c45a4bc70503776a6e62a66bf89
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Fri Nov 8 09:42:08 2013 -0800

    Remove CpuNop from CPU_K6_2_FLAGS
    
    	PR gas/16140
    	* i386-gen.c (cpu_flag_init): Remove CpuNop from CPU_K6_2_FLAGS.
    	* i386-init.h: Regenerated.

-----------------------------------------------------------------------

Summary of changes:
 opcodes/ChangeLog   |    6 ++++++
 opcodes/i386-gen.c  |    2 +-
 opcodes/i386-init.h |    2 +-
 3 files changed, 8 insertions(+), 2 deletions(-)