Summary: Wrong code for expression involving 8 floats, only
                    with -O
           Product: D
           Version: D1 & D2
          Platform: Other
        OS/Version: Windows
            Status: NEW
          Severity: blocker
          Priority: P2
         Component: DMD

--- Comment #0 from Don <> 2011-08-16 04:33:20 PDT ---
Found this when I removed a reference to std.random from the DMD test suite.
This bug is in test22.d. It was originally described in:
but wasn't reduced correctly -- it has never been fixed.
It only applies when compiling with -O: the result is -nan.
real randx()
    return 1.2;

void test1()
    float x10=randx();
    float x11=randx();
    float x20=randx();
    float x21=randx();
    float y10=randx();
    float y11=randx();
    float y20=randx();
    float y21=randx();

    float tmp=(
    x20*x21 + y10*y10 + y10*y11 + y11*y11 + 
    y11*y20 + y20*y20 + y10*y21 + y11*y21 +
    assert(tmp > 0);

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to