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

           Summary: Possibly unneded functions
           Product: D
           Version: D2
          Platform: x86
        OS/Version: Windows
            Status: NEW
          Severity: minor
          Priority: P2
         Component: DMD
        AssignedTo: nob...@puremagic.com
        ReportedBy: bearophile_h...@eml.cc


--- Comment #0 from bearophile_h...@eml.cc 2011-06-01 05:22:29 PDT ---
This is not a true bug, and I am not sure if this is right.

This 2 lines long D2 program:


void foo()() {}
void main() {}


Once compiled with DMD 2.053 (using no compiler switch, or using -O -release
-inline is the same), generates this asm too:


_D4test7__arrayZ    comdat
L0:     enter   4,0
        push    EAX
        mov ECX,offset FLAT:_D4test12__ModuleInfoZ
        push    ECX
        call    near ptr __d_array_bounds

_D4test8__assertFiZv    comdat
L0:     enter   4,0
        push    EAX
        mov ECX,offset FLAT:_D4test12__ModuleInfoZ
        push    ECX
        call    near ptr __d_assertm

_D4test15__unittest_failFiZv    comdat
L0:     enter   4,0
        push    EAX
        mov ECX,offset FLAT:_D4test12__ModuleInfoZ
        push    ECX
        call    near ptr __d_unittestm
        add ESP,8
        leave
        ret


Is unittest_fail needed in the asm of this program?

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to