Skip to content
Snippets Groups Projects
Commit 0565fcc8 authored by Yang Chen's avatar Yang Chen Committed by Tianqi Chen
Browse files

Added a helper function that dumps Node to stderr (#1703)

parent 8e7ff260
No related branches found
No related tags found
No related merge requests found
......@@ -230,6 +230,13 @@ using Domain = Array<Range>;
// print functions for expr
TVM_DLL std::ostream& operator<<(std::ostream& os, const NodeRef& n); // NOLINT(*)
/*!
* \brief Dump the node to stderr, used for debug purposes.
* \param node The input node
*/
TVM_DLL void Dump(const NodeRef& node);
// definition of Node.
/*!
* \brief An iteration variable representing an iteration
......
......@@ -47,6 +47,10 @@ std::ostream& operator<<(std::ostream& os, const NodeRef& n) { // NOLINT(*)
return os;
}
void Dump(const NodeRef& n) {
std::cerr << n << "\n";
}
Var var(const std::string& name_hint, Type t) {
return Var(name_hint, t);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment