[svn r248] Fixed: labels in inline asm block now work for the normal case.

Fixed: inline asm blocks are now emitted as a single asm entity.
This commit is contained in:
Tomas Lindquist Olsen
2008-06-08 06:15:51 +02:00
parent 3e62d80b4f
commit fd8cec14e1
9 changed files with 235 additions and 85 deletions

View File

@@ -992,6 +992,17 @@ void LabelStatement::toIR(IRState* p)
Logger::println("LabelStatement::toIR(): %s", loc.toChars());
LOG_SCOPE;
// if it's an inline asm label, we don't create a basicblock, just emit it in the asm
if (p->inASM)
{
IRAsmStmt* a = new IRAsmStmt;
a->code = ".LDASM";
a->code += ident->toChars();
a->code += ":";
p->ASMs.push_back(a);
return;
}
assert(tf == NULL);
llvm::BasicBlock* oldend = gIR->scopeend();