[PATCH] D80764: [mlir] Add test to check if standalone dialect is registered

Marius Brehler via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 28 15:25:44 PDT 2020


marbre created this revision.
marbre added reviewers: Kayjukh, stephenneuendorffer.
Herald added subscribers: llvm-commits, jurahul, frgossen, grosul1, Joonsoo, liufengdb, lucyrfox, mgester, arpith-jacob, nicolasvasilache, antiagainst, shauheen, jpienaar, rriddle, mehdi_amini.
Herald added a project: LLVM.

Add a test to check if the standalone dialect is registered within standalone-opt. Similar to the mlir-opt commandline.mlir test.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D80764

Files:
  mlir/examples/standalone/test/Standalone/standalone-opt.mlir
  mlir/test/Examples/standalone/test.toy


Index: mlir/test/Examples/standalone/test.toy
===================================================================
--- mlir/test/Examples/standalone/test.toy
+++ mlir/test/Examples/standalone/test.toy
@@ -1,4 +1,4 @@
 # RUN: %cmake %mlir_src_root/examples/standalone -DCMAKE_CXX_COMPILER=%host_cxx -DCMAKE_C_COMPILER=%host_cc -DMLIR_DIR=%llvm_lib_dir/cmake/mlir ; %cmake --build . --target check-standalone | tee %t | FileCheck %s
 
-# CHECK: Expected Passes: 2
+# CHECK: Expected Passes: 3
 # UNSUPPORTED: windows, android
Index: mlir/examples/standalone/test/Standalone/standalone-opt.mlir
===================================================================
--- /dev/null
+++ mlir/examples/standalone/test/Standalone/standalone-opt.mlir
@@ -0,0 +1,3 @@
+// RUN: standalone-opt --show-dialects | FileCheck %s
+// CHECK: Registered Dialects:
+// CHECK: standalone


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D80764.267055.patch
Type: text/x-patch
Size: 863 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200528/65dd6623/attachment.bin>


More information about the llvm-commits mailing list