#include <dmlc/logging.h> #include <gtest/gtest.h> #include <tvm/tvm.h> #include <tvm/ir_pass.h> TEST(SimplePasses, HasSideEffect) { using namespace tvm; auto n = var("n"); Array<Expr> shape; shape.push_back(n); auto A = placeholder(shape, Float(32), "A"); CHECK(!tvm::ir::HasSideEffect(A[0])); } int main(int argc, char ** argv) { testing::InitGoogleTest(&argc, argv); testing::FLAGS_gtest_death_test_style = "threadsafe"; return RUN_ALL_TESTS(); }