Enable NNC tests vol. i. add test_tensorexpr.py tests [WIP] (#34897)

Summary:
This  PR add tensorexpr cpp tests to test_jit.py
Pull Request resolved: https://github.com/pytorch/pytorch/pull/34897

Differential Revision: D20630760

Pulled By: Krovatkin

fbshipit-source-id: 7d2f27aca6b1e23e3ffed1c765d8f590688118e3
This commit is contained in:
Nikolay Korovaiko
2020-03-25 17:20:03 -07:00
committed by Facebook GitHub Bot
parent ccc0e35275
commit f3a5081bd4
20 changed files with 783 additions and 546 deletions
+13
View File
@@ -1,5 +1,6 @@
#include <test/cpp/jit/tests.h>
#include <c10/util/Exception.h>
#include <test/cpp/tensorexpr/tests.h>
namespace torch {
namespace jit {
@@ -25,5 +26,17 @@ JIT_TEST_API void runJITCPPTests(bool runCuda) {
testTorchSaveError();
}
#undef JIT_TEST
#define JIT_TEST(name) test##name();
JIT_TEST_API void runTENSOREXPRCPPTests(bool runCuda) {
TH_FORALL_TENSOREXPR_TESTS(JIT_TEST)
if (runCuda) {
#ifdef USE_CUDA
TH_FORALL_TENSOREXPR_TESTS_CUDA(JIT_TEST)
#endif
}
}
#undef JIT_TEST
} // namespace jit
} // namespace torch