File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed
Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -2441,6 +2441,16 @@ void CodeGenTileLangCUDA::VisitStmt_(const EvaluateNode *op) {
24412441 stream << " " << vid_global_barrier_expect_ << " = 0;\n " ;
24422442 PrintIndent ();
24432443 stream << " }\n " ;
2444+ }
2445+ if (call && (call->op .same_as (tvm::tl::device_assert ()))) {
2446+ std::string cond = PrintExpr (call->args [0 ]);
2447+ this ->PrintIndent ();
2448+ stream << " device_assert(" << cond << " );\n " ;
2449+ } else if (call && call->op .same_as (tvm::tl::device_assert_with_msg ())) {
2450+ std::string cond = PrintExpr (call->args [0 ]);
2451+ std::string msg_expr = PrintExpr (call->args [1 ]);
2452+ this ->PrintIndent ();
2453+ stream << " device_assert_with_msg(" << cond << " , " << msg_expr << " );\n " ;
24442454 } else {
24452455 CodeGenC::VisitStmt_ (op);
24462456 }
You can’t perform that action at this time.
0 commit comments