[Issue 1981] New: Internal error: ..\ztc\cgcod.c 1523 when using -O -inline -release

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed Apr 9 19:25:15 PDT 2008


http://d.puremagic.com/issues/show_bug.cgi?id=1981

           Summary: Internal error: ..\ztc\cgcod.c 1523 when using -O -
                    inline -release
           Product: D
           Version: 1.028
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla at digitalmars.com
        ReportedBy: sjguy at cs.unc.edu


I can only get it to happen with my full code base ~2,000 lines, if I can find
a smaller failure case I'll post it.  The problem seems to be very fragile.  If
I don't inline it goes away, if I don't use release mode it goes away, or if I
don't optimize it goes away...it only happens with all 3 options enabled.

Also if I switch from:
bool func(float2f s, float2f e){
    bool retval = false;
    retval |= foo(s, e, a, b);
    retval |= foo(s, e, b, c);
    retval |= foo(s, e, c, a);
    return retval;
}

To:
bool func(float2f s, float2f e){
    bool retval = false;
    retval = foo(s, e, c, a) || foo(s, e, b, c) || foo(s, e, a, b);
    return retval;
}

The problem goes away.
This may be related to: http://d.puremagic.com/issues/show_bug.cgi?id=1709


-- 



More information about the Digitalmars-d-bugs mailing list