torch-mlir/test
Sean Silva c4123d4d4d Add npcomp-verify-backend-contract pass.
This pass verifies that a given module satisfies the contract that we
have for backends. This is phrased as an "allowlist", because we want to
keep this interface tight. Also, this gives much better diagnostics than
a backend randomly crashing or failing to compile would (though they
could still be improved).

This was especially painful because if we had
`tensor<?x!numpy.any_dtype>` slip through, at some point RefBackend
would convert it to a memref type and trip the "verify type invariants"
assertion which gives no location or anything and crashed the process,
which was very unpleasant.

We implement this with the dialect conversion framework, which works
reasonably well and was quick to put together and familiar, but is still
very "op oriented". We probably want to make this hand-rolled
eventually, especially the error reporting (the most useful kind of
error for a dialect conversion user is not necessarily the best for this
use case). Also, in production, these error will go to users, and need
to be surfaced carefully such as "the compiler needs a type annotation
on this function parameter" which in general requires some special
analysis, wordsmithing, and overall awareness of the e2e use case (such
as how much we can lean into certain source locations) to provide a
meaningful user-level diagnostic.

Also, add `inline` to the current frontend lowering pass pipeline to
allow slightly more complicated programs that otherwise would fail on
shape inference.
2021-04-20 12:00:35 -07:00
..
Backend Add npcomp-verify-backend-contract pass. 2021-04-20 12:00:35 -07:00
CAPI Add prim::Print and fix prim::CallMethod 2021-02-10 15:15:56 -08:00
Conversion Add `aten.mm` to linalg lowering. 2021-04-16 12:03:31 -07:00
Dialect Add `aten.mm` to linalg lowering. 2021-04-16 12:03:31 -07:00
Python Bump llvm-project to be7352c00d51f4358db3a23ed6a077f7cb48eafd 2021-01-21 11:16:55 -08:00
RefBackend Bump llvm-project to 0524a09cc7e1a0797982feacf505825231efbee7 2021-03-23 14:29:05 -07:00
npcomp-run-mlir [refbackrt] Scalar arg support 2021-03-23 13:16:44 -07:00
CMakeLists.txt Sever C++ level depend on IREE and rebase on exe and python interface. 2020-11-16 21:32:56 -08:00
lit.cfg.py Enable building using LLVM_EXTERNAL_PROJECTS. (#152) 2021-01-26 11:43:43 -07:00
lit.site.cfg.py.in Enable building using LLVM_EXTERNAL_PROJECTS. (#152) 2021-01-26 11:43:43 -07:00