public inbox for
help / color / mirror / Atom feed
From: Christian Szegedy <>
Subject: Re: c/10844: Wrong computation on nan initialized vectors.
Date: Mon, 19 May 2003 10:17:00 -0000	[thread overview]
Message-ID: <> (raw)

The following reply was made to PR c/10844; it has been noted by GNATS.

From: Christian Szegedy <>
Subject: Re: c/10844: Wrong computation on nan initialized vectors.
Date: Mon, 19 May 2003 12:05:19 +0200 wrote:
 >Synopsis: Wrong computation on nan initialized vectors.
 >State-Changed-From-To: open->feedback
 >State-Changed-By: cae
 >State-Changed-When: Sun May 18 17:49:33 2003
 >    I can't reproduce this. Could you tell us the compiler options used
 >    to compile the code, the output of gcc -v and the assemble code
 >    generated for the main function? Additionally your libc version might
 >    be of interest here.
 >        regards  Christian
 I just used "gcc -lm bug.c" to compile the code.
 I am at work, but I can reproduce the bug on my SuSe 8.0 box, with
 Reading specs from 
 Configured with: ../gcc-3.2/configure 
 Thread model: posix
 gcc version 3.2
 How can I determine the glibc version?
 The bug also occurs with the old 2.95 compiler.
 The assembler output is:
         .file   "bug.c"
         .section        .rodata
         .string ""
         .string "%lg\n"
         .align 2
 .globl main
         .type   main,@function
         pushl   %ebp
         movl    %esp, %ebp
         pushl   %esi
         pushl   %ebx
         subl    $32, %esp
         andl    $-16, %esp
         movl    $0, %eax
         subl    %eax, %esp
         movl    $10, -16(%ebp)
         movl    -16(%ebp), %eax
         sall    $3, %eax
         movl    %eax, (%esp)
         call    malloc
         movl    %eax, -20(%ebp)
         movl    $0, -12(%ebp)
         movl    -12(%ebp), %eax
         cmpl    -16(%ebp), %eax
         jl      .L5
         jmp     .L3
         movl    -12(%ebp), %eax
         leal    0(,%eax,8), %esi
         movl    -20(%ebp), %ebx
         movl    $.LC0, (%esp)
         call    nan
         pushl   %eax
         fildl   (%esp)
         leal    4(%esp), %esp
         fstpl   (%ebx,%esi)
         leal    -12(%ebp), %eax
         incl    (%eax)
         jmp     .L2
         movl    -20(%ebp), %eax
         movl    $0, (%eax)
         movl    $0, 4(%eax)
         movl    -20(%ebp), %edx
         movl    -20(%ebp), %eax
         fldl    (%eax)
         faddp   %st, %st(1)
         fstpl   (%edx)
         movl    $.LC2, (%esp)
         movl    -20(%ebp), %eax
         movl    4(%eax), %edx
         movl    (%eax), %eax
         movl    %eax, 4(%esp)
         movl    %edx, 8(%esp)
         call    printf
         movl    $0, %eax
         leal    -8(%ebp), %esp
         popl    %ebx
         popl    %esi
         popl    %ebp
         .size   main,.Lfe1-main
         .ident  "GCC: (GNU) 3.2"

             reply	other threads:[~2003-05-19 10:17 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-05-19 10:17 Christian Szegedy [this message]
  -- strict thread matches above, loose matches on Subject: below --
2003-05-19 15:06 Christian Szegedy
2003-05-19 12:01 ehrhardt
2003-05-18 17:49 ehrhardt
2003-05-18 17:26 szegedy

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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be 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).