diff --git a/.jenkins/pytorch/build.sh b/.jenkins/pytorch/build.sh index 4c1ddc024fa..e808d83cbcf 100755 --- a/.jenkins/pytorch/build.sh +++ b/.jenkins/pytorch/build.sh @@ -68,8 +68,13 @@ fi pip_install -r requirements.txt || true # Enable LLVM dependency for TensorExpr testing -export USE_LLVM=/opt/llvm -export LLVM_DIR=/opt/llvm/lib/cmake/llvm +if [[ "$BUILD_ENVIRONMENT" == *rocm* ]]; then + export USE_LLVM=/opt/rocm/llvm + export LLVM_DIR=/opt/rocm/llvm/lib/cmake/llvm +else + export USE_LLVM=/opt/llvm + export LLVM_DIR=/opt/llvm/lib/cmake/llvm +fi # TODO: Don't install this here if ! which conda; then diff --git a/.jenkins/pytorch/test.sh b/.jenkins/pytorch/test.sh index ea1654d69e9..a2a7f17fbbf 100755 --- a/.jenkins/pytorch/test.sh +++ b/.jenkins/pytorch/test.sh @@ -329,6 +329,14 @@ test_libtorch() { test_aot_compilation() { echo "Testing Ahead of Time compilation" + ln -sf "$TORCH_LIB_DIR"/libc10* "$TORCH_BIN_DIR" + ln -sf "$TORCH_LIB_DIR"/libtorch* "$TORCH_BIN_DIR" + + # Make test_reports directory + # NB: the ending test_libtorch must match the current function name for the current + # test reporting process (in print_test_stats.py) to function as expected. + TEST_REPORTS_DIR=test/test-reports/cpp-unittest/test_aot_compilation + mkdir -p $TEST_REPORTS_DIR if [ -f "$TORCH_BIN_DIR"/test_mobile_nnc ]; then "$TORCH_BIN_DIR"/test_mobile_nnc --gtest_output=xml:$TEST_REPORTS_DIR/test_mobile_nnc.xml; fi # shellcheck source=test/mobile/nnc/test_aot_compile.sh if [ -f "$TORCH_BIN_DIR"/aot_model_compiler_test ]; then source test/mobile/nnc/test_aot_compile.sh; fi diff --git a/test/run_test.py b/test/run_test.py index d28e21e177e..9651f7f7a74 100755 --- a/test/run_test.py +++ b/test/run_test.py @@ -247,7 +247,6 @@ ROCM_BLOCKLIST = [ "distributed/_shard/test_replicated_tensor", "test_determination", "test_jit_legacy", - "test_openmp", ] RUN_PARALLEL_BLOCKLIST = [