public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/98667] New: gcc generates endbr32 invalid opcode on -march=i486
@ 2021-01-14  1:24 tedheadster at gmail dot com
  2021-01-14  1:28 ` [Bug c++/98667] " tedheadster at gmail dot com
                   ` (19 more replies)
  0 siblings, 20 replies; 21+ messages in thread
From: tedheadster at gmail dot com @ 2021-01-14  1:24 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98667

            Bug ID: 98667
           Summary: gcc generates endbr32 invalid opcode on -march=i486
           Product: gcc
           Version: 9.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: tedheadster at gmail dot com
  Target Milestone: ---

Compiling the 'eix' program with gcc 9.3.0 and the '-march=i486' generated an
'endbr32' opcode. This is an undefined opcode on an i486.


# /usr/bin/gdb /usr/bin/eix
GNU gdb (Gentoo 10.1 vanilla) 10.1
...
Reading symbols from /usr/bin/eix...
Reading symbols from /usr/lib/debug//usr/bin/eix.debug...
(gdb) run
Starting program: /usr/bin/eix

Program received signal SIGILL, Illegal instruction.
_GLOBAL__sub_I_spaces () at eixTk/stringutils.cc:686
686     }

(gdb) disassemble _GLOBAL__sub_I_spaces
Dump of assembler code for function _GLOBAL__sub_I_spaces():
=> 0x004208e0 <+0>:     endbr32
   0x004208e4 <+4>:     push   %esi
   0x004208e5 <+5>:     push   %ebx
   0x004208e6 <+6>:     sub    $0xc,%esp
   0x004208e9 <+9>:     call   0x420d30 <__x86.get_pc_thunk.bx>
   0x004208ee <+14>:    add    $0x17e712,%ebx
   0x0042091e <+62>:    add    $0x14,%esp
   0x00420921 <+65>:    pop    %ebx
   0x00420922 <+66>:    pop    %esi
   0x00420923 <+67>:    ret    

(gdb) list
681                     if(likely(isutf8firstgyte(t[i]))) {
682                             ++len;
683                     }
684             }
685             return len;
686     }

^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2021-10-21 19:14 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-14  1:24 [Bug c++/98667] New: gcc generates endbr32 invalid opcode on -march=i486 tedheadster at gmail dot com
2021-01-14  1:28 ` [Bug c++/98667] " tedheadster at gmail dot com
2021-01-14  7:28 ` [Bug target/98667] " pinskia at gcc dot gnu.org
2021-01-14 11:53 ` tedheadster at gmail dot com
2021-01-14 13:22 ` tedheadster at gmail dot com
2021-01-14 13:29 ` jakub at gcc dot gnu.org
2021-01-14 14:04 ` rguenth at gcc dot gnu.org
2021-01-14 14:07 ` hjl.tools at gmail dot com
2021-01-14 14:08 ` hjl.tools at gmail dot com
2021-01-14 15:43 ` cvs-commit at gcc dot gnu.org
2021-01-14 15:45 ` hjl.tools at gmail dot com
2021-01-15 13:26 ` tedheadster at gmail dot com
2021-04-27 13:12 ` hjl.tools at gmail dot com
2021-07-15 17:40 ` hjl.tools at gmail dot com
2021-10-21 15:22 ` marxin at gcc dot gnu.org
2021-10-21 15:55 ` hjl.tools at gmail dot com
2021-10-21 16:14 ` marxin at gcc dot gnu.org
2021-10-21 19:09 ` cvs-commit at gcc dot gnu.org
2021-10-21 19:10 ` cvs-commit at gcc dot gnu.org
2021-10-21 19:11 ` cvs-commit at gcc dot gnu.org
2021-10-21 19:14 ` cvs-commit at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).