public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "hjl.tools at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/55145] Different bits for long double constant depending ptr_mode Date: Sun, 04 Nov 2012 08:11:00 -0000 [thread overview] Message-ID: <bug-55145-4-UjQOMhVPCP@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-55145-4@http.gcc.gnu.org/bugzilla/> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55145 H.J. Lu <hjl.tools at gmail dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Component|target |middle-end Summary|[4.8 Regression] [x32] |Different bits for long |-maddress-mode=long |double constant depending |miscompiles glibc |ptr_mode --- Comment #3 from H.J. Lu <hjl.tools at gmail dot com> 2012-11-04 08:11:01 UTC --- GCC i386 and GCC x86-64 generate different bits long double constant depending ptr_mode: [hjl@gnu-tools-1 tmp]$ cat y.c const long double pio2_hi = 1.5707963267948966192021943710788178805159986950457096099853515625L; [hjl@gnu-tools-1 tmp]$ /usr/gcc-4.7.3-32bit/bin/gcc -S y.c -o 32.s [hjl@gnu-tools-1 tmp]$ gcc -S y.c -o 64.s [hjl@gnu-tools-1 tmp]$ diff -up 64.s 32.s --- 64.s 2012-11-04 01:06:52.492398183 -0700 +++ 32.s 2012-11-04 01:06:47.685344002 -0700 @@ -3,11 +3,10 @@ .section .rodata .align 16 .type pio2_hi, @object - .size pio2_hi, 16 + .size pio2_hi, 12 pio2_hi: - .long 560513588 - .long 3373259426 + .long 560513589 + .long -921707870 .long 16383 - .long 0 - .ident "GCC: (GNU) 4.7.2 20120921 (Red Hat 4.7.2-2)" + .ident "GCC: (GNU) 4.7.3 20121024 (prerelease)" .section .note.GNU-stack,"",@progbits [hjl@gnu-tools-1 tmp]$ gcc -c 32.s 64.s [hjl@gnu-tools-1 tmp]$ objdump -s -j .rodata 32.o > 32 [hjl@gnu-tools-1 tmp]$ objdump -s -j .rodata 64.o > 64 [hjl@gnu-tools-1 tmp]$ diff -up 32 64 --- 32 2012-11-04 01:07:37.341913094 -0700 +++ 64 2012-11-04 01:07:42.192979572 -0700 @@ -1,5 +1,5 @@ -32.o: file format elf64-x86-64 +64.o: file format elf64-x86-64 Contents of section .rodata: - 0000 35c26821 a2da0fc9 ff3f0000 5.h!.....?.. + 0000 34c26821 a2da0fc9 ff3f0000 00000000 4.h!.....?...... [hjl@gnu-tools-1 tmp]$ Ignore padding, i386 GCC generates 35c26821 and x86-64 generates 34c26821.
next prev parent reply other threads:[~2012-11-04 8:11 UTC|newest] Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top 2012-10-31 5:39 [Bug target/55145] New: [4.8 Regression] [x32] -maddress-mode=long miscompiles glibc hjl.tools at gmail dot com 2012-10-31 10:27 ` [Bug target/55145] " rguenth at gcc dot gnu.org 2012-11-01 10:09 ` ubizjak at gmail dot com 2012-11-01 22:29 ` hjl.tools at gmail dot com 2012-11-04 8:11 ` hjl.tools at gmail dot com [this message] 2012-11-04 10:14 ` [Bug middle-end/55145] Different bits for long double constant depending on long int size hjl.tools at gmail dot com 2012-11-04 11:04 ` schwab@linux-m68k.org 2012-11-04 11:09 ` hjl.tools at gmail dot com 2012-11-04 22:52 ` hjl.tools at gmail dot com 2012-11-04 23:43 ` vincent-gcc at vinc17 dot net 2013-03-22 14:45 ` jakub at gcc dot gnu.org 2013-05-31 10:59 ` jakub at gcc dot gnu.org 2013-10-16 9:49 ` jakub at gcc dot gnu.org 2013-11-20 14:40 ` jsm28 at gcc dot gnu.org 2013-11-20 14:41 ` jsm28 at gcc dot gnu.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=bug-55145-4-UjQOMhVPCP@http.gcc.gnu.org/bugzilla/ \ --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).