|
Intel SPMD Program Compiler
1.3.0
|
Interface class for statements in the ispc language. More...
#include <stmt.h>


Public Member Functions | |
| Stmt (SourcePos p) | |
| virtual void | EmitCode (FunctionEmitContext *ctx) const =0 |
| virtual void | Print (int indent) const =0 |
| virtual Stmt * | Optimize () |
| virtual Stmt * | TypeCheck ()=0 |
Interface class for statements in the ispc language.
This abstract base-class encapsulates methods that AST nodes for statements in the language must implement.
| virtual void Stmt::EmitCode | ( | FunctionEmitContext * | ctx | ) | const [pure virtual] |
Emit LLVM IR for the statement, using the FunctionEmitContext to create the necessary instructions.
Implemented in DeleteStmt, AssertStmt, PrintStmt, StmtList, LabeledStmt, GotoStmt, SwitchStmt, DefaultStmt, CaseStmt, ReturnStmt, UnmaskedStmt, ForeachUniqueStmt, ForeachActiveStmt, ForeachStmt, ContinueStmt, BreakStmt, ForStmt, DoStmt, IfStmt, DeclStmt, and ExprStmt.
Referenced by DoStmt::EmitCode(), ForStmt::EmitCode(), ForeachStmt::EmitCode(), ForeachActiveStmt::EmitCode(), ForeachUniqueStmt::EmitCode(), UnmaskedStmt::EmitCode(), CaseStmt::EmitCode(), DefaultStmt::EmitCode(), SwitchStmt::EmitCode(), LabeledStmt::EmitCode(), and lEmitIfStatements().
| Stmt * Stmt::Optimize | ( | ) | [virtual] |
Reimplemented in LabeledStmt, GotoStmt, and DeclStmt.
| virtual void Stmt::Print | ( | int | indent | ) | const [pure virtual] |
Print a representation of the statement (and any children AST nodes) to standard output. This method is used for debuggins.
Implemented in DeleteStmt, AssertStmt, PrintStmt, StmtList, LabeledStmt, GotoStmt, SwitchStmt, DefaultStmt, CaseStmt, ReturnStmt, UnmaskedStmt, ForeachUniqueStmt, ForeachActiveStmt, ForeachStmt, ContinueStmt, BreakStmt, ForStmt, DoStmt, IfStmt, DeclStmt, and ExprStmt.
Referenced by IfStmt::Print(), DoStmt::Print(), ForStmt::Print(), ForeachStmt::Print(), ForeachActiveStmt::Print(), ForeachUniqueStmt::Print(), UnmaskedStmt::Print(), CaseStmt::Print(), DefaultStmt::Print(), SwitchStmt::Print(), and LabeledStmt::Print().
| virtual Stmt* Stmt::TypeCheck | ( | ) | [pure virtual] |
Implemented in DeleteStmt, AssertStmt, PrintStmt, StmtList, LabeledStmt, GotoStmt, SwitchStmt, DefaultStmt, CaseStmt, ReturnStmt, UnmaskedStmt, ForeachUniqueStmt, ForeachActiveStmt, ForeachStmt, ContinueStmt, BreakStmt, ForStmt, DoStmt, IfStmt, DeclStmt, and ExprStmt.
1.7.5.1