public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "danglin at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/37323] [4.4 Regression] __builtin_apply failures Date: Sat, 08 Nov 2008 17:29:00 -0000 [thread overview] Message-ID: <20081108172807.9407.qmail@sourceware.org> (raw) In-Reply-To: <bug-37323-276@http.gcc.gnu.org/bugzilla/> ------- Comment #3 from danglin at gcc dot gnu dot org 2008-11-08 17:28 ------- (gdb) r Starting program: /test/gnu/gcc/objdir/gcc/testsuite/gcc/builtin-apply4.xg warning: Private mapping of shared library text was not specified by the executable; setting a breakpoint in a shared library which is not privately mapped will not work. See the HP-UX 11i v3 chatr manpage for methods to privately map shared library text. warning: Loadable segment ".tbss" outside of ELF segments warning: Loadable segment ".tbss" outside of ELF segments Program received signal SIGSEGV, Segmentation fault. bar (arg=<value optimized out>) at /test/gnu/gcc/gcc/gcc/testsuite/gcc.dg/builtin-apply4.c:20 20 __builtin_return (__builtin_apply ((void (*) ()) foo, (gdb) p/x $pc $1 = 0x4000000000002b2c (gdb) disass 0x4000000000002b0c 0x4000000000002b3c Dump of assembler code from 0x4000000000002b0c to 0x4000000000002b3c: 0x4000000000002b0c <bar+108>: std r26,58(r3) 0x4000000000002b10 <bar+112>: fstd fr4,60(r3) 0x4000000000002b14 <bar+116>: b,l 0x4000000000002a68 <foo>,rp 0x4000000000002b18 <bar+120>: std r0,10(r3) 0x4000000000002b1c <bar+124>: ldd 10(r3),ret0 0x4000000000002b20 <bar+128>: ldo 20(sp),sp 0x4000000000002b24 <bar+132>: std r3,-8(sp) 0x4000000000002b28 <bar+136>: copy r4,dp 0x4000000000002b2c <bar+140>: ldd,mb -10(ret0),r31 0x4000000000002b30 <bar+144>: std r31,-80(sp) 0x4000000000002b34 <bar+148>: ldo -30(sp),ret1 0x4000000000002b38 <bar+152>: ldd 8(ret0),ret0 End of assembler dump. This is a wrong code bug. Register r0 is always 0. It is stored into the frame at 10(r3) in the delay slot of the first call to foo. The value is loaded from 10(r3) into register ret0. The segv is caused by the null pointer used in the memory load at 0x4000000000002b2c. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37323
next prev parent reply other threads:[~2008-11-08 17:29 UTC|newest] Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top 2008-09-01 19:50 [Bug middle-end/37323] New: " danglin at gcc dot gnu dot org 2008-09-01 19:54 ` [Bug middle-end/37323] " danglin at gcc dot gnu dot org 2008-09-02 11:36 ` rguenth at gcc dot gnu dot org 2008-10-22 3:06 ` mmitchel at gcc dot gnu dot org 2008-11-08 2:04 ` danglin at gcc dot gnu dot org 2008-11-08 17:29 ` danglin at gcc dot gnu dot org [this message] 2008-11-08 19:00 ` dave at hiauly1 dot hia dot nrc dot ca 2008-11-08 19:39 ` danglin at gcc dot gnu dot org 2008-11-08 21:31 ` danglin at gcc dot gnu dot org 2008-11-08 21:41 ` danglin at gcc dot gnu dot org 2008-11-08 21:48 ` danglin at gcc dot gnu dot org 2008-11-09 10:58 ` jakub at gcc dot gnu dot org 2008-11-09 16:30 ` dave at hiauly1 dot hia dot nrc dot ca 2008-11-10 14:55 ` dave at hiauly1 dot hia dot nrc dot ca 2008-11-10 18:07 ` jakub at gcc dot gnu dot org 2008-11-22 8:31 ` jakub at gcc dot gnu dot org 2008-11-22 8:33 ` jakub at gcc dot gnu dot org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20081108172807.9407.qmail@sourceware.org \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
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).