view tests/mini/naked_asm4.d @ 1091:20d96c148b39

Fix for fmul/div/add/sub with no operands. Revert explicit ST0 definition since a typo had caused the need for that.
author Kelly Wilson <wilsonk cpsc.ucalgary.ca>
date Tue, 10 Mar 2009 18:34:19 -0600
parents 5e3bb0c3ea8b
children
line wrap: on
line source

void foo()
{
    version(X86)
    asm
    {
        naked;
        jmp pass;
        hlt;
pass:   ret;
    }
    else version(X86_64)
    asm
    {
        naked;
        jmp pass;
        hlt;
pass:   ret;
    }
    else static assert(0, "todo");
}

void main()
{
    foo();
}