Ejemplo n.º 1
0
GenTreeStmt* BasicBlock::lastTopLevelStmt()
{
    if (bbTreeList == nullptr)
        return nullptr;

    GenTreePtr stmt = lastStmt();

#ifndef LEGACY_BACKEND
    while ((stmt->gtFlags & GTF_STMT_TOP_LEVEL) == 0)
    {
        stmt = stmt->gtPrev;
    }
#endif // !LEGACY_BACKEND

    return stmt->AsStmt();
}
Ejemplo n.º 2
0
//------------------------------------------------------------------------
// BasicBlock::lastNode: Returns the last node in the block.
//
GenTree* BasicBlock::lastNode()
{
    return IsLIR() ? m_lastNode : lastStmt()->gtStmtExpr;
}