#include "rose.h"
#include <string>
Go to the source code of this file.
Namespaces | |
namespace | risc |
namespace | risc::tools |
Functions | |
bool | risc::tools::is_data_structure (SgType *type) |
This function checks if the passed type represents a data structure. | |
bool | risc::tools::is_builtin_type (SgType *type) |
This function checks if the passed type represents a C++ builtin type. | |
bool | risc::tools::class_types_are_identical (SgClassDefinition *cd1, SgClassDefinition *cd2) |
Compares two classes. | |
bool | risc::tools::is_func_name (const SgFunctionDeclaration *function, const std::string &name) |
Compares the function name with the given string. | |
void | risc::tools::print_indented (std::string s, unsigned indent) |
Prints a string with indention. | |
SgClassDefinition * | risc::tools::class_definition_of_variable (SgVariableDeclaration *var_decl) |
Determines the class defintion of varialbe It is expected that the type is SgClassType. | |
bool | risc::tools::is_builtin_function (SgFunctionDeclaration *func_decl) |
Checks if a given function is a C++ builtin function This function is taken/inspired from the Rose builtinFilter structure. | |
bool | risc::tools::all_cfg_branches_end_in_break (SgNode *node, int &break_counter) |
This function determines if all cfg branches in the statement 'node' will end in a break statement. The statement in end will be excluded. Some examples:. | |
bool | risc::tools::all_cfg_branches_end_in_continue (SgNode *node, int &continue_counter) |
This function determines if all cfg branches in the statement 'node' will end in a continue statement. The statement in end will be excluded. Some examples:. | |
SgStatement * | risc::tools::get_previous_stmt_in_basic_block (SgNode *node) |
This function determines the previous statement of the statement 'node' in the next surrounding basic block. If 'node' is the first statement, the return value will be NULL. | |
bool | risc::tools::is_conditional_break (SgScopeStatement const *const loop_stmt, SgBreakStmt const *const break_stmt) |
This function checks if a given break statement is unconditioned. | |
SgScopeStatement * | risc::tools::find_break_surrounding_scope (SgBreakStmt *break_stmt) |
This function finds the surrounding scope statement of a break. The break can be surrounded by a while, do while, for loop or by a switch statement. | |
bool | risc::tools::break_belongs_to_loop (SgScopeStatement *loop_stmt, SgBreakStmt const *const break_stmt) |
This function checks if a given break statement belongs to a given loop statements. | |
bool | risc::tools::is_located_in_rose_header (SgNode *node) |
SgMemberFunctionDeclaration * | risc::tools::get_constructor (SgClassDefinition *class_def) |
This function returns the constructor of class. For a module, primitive channel, and a hierarchical channel we expect exactly one constructor. So, we return the first SgFunctionDefinition which es a constructor. |