[llvm] 2b25e40 - [MLGO] Switch test to invoke pytype through python
Aiden Grossman via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 26 13:47:34 PST 2024
Author: Aiden Grossman
Date: 2024-01-26T21:46:21Z
New Revision: 2b25e40a887e835c3c8d7e61feaaaaab1ed2c367
URL: https://github.com/llvm/llvm-project/commit/2b25e40a887e835c3c8d7e61feaaaaab1ed2c367
DIFF: https://github.com/llvm/llvm-project/commit/2b25e40a887e835c3c8d7e61feaaaaab1ed2c367.diff
LOG: [MLGO] Switch test to invoke pytype through python
Currently this test is assuming that ~/.local/bin (or wherever the
Python binaries are installed to) is on the path. This is not a valid
assumption in most cases, and it also means we might not find the
version of pytype associated with the Python interpreter being used to
test LLVM, which could create some inconsistencies. This patch fixes
that by invoking pytype through the Python interpreter passed to lit.
Added:
Modified:
llvm/utils/mlgo-utils/tests/pytype.test
Removed:
################################################################################
diff --git a/llvm/utils/mlgo-utils/tests/pytype.test b/llvm/utils/mlgo-utils/tests/pytype.test
index e2d620472305f1..b9d6b5f58094ae 100644
--- a/llvm/utils/mlgo-utils/tests/pytype.test
+++ b/llvm/utils/mlgo-utils/tests/pytype.test
@@ -1,4 +1,4 @@
# REQUIRES: system-linux, has-pytype
-# RUN: pytype %S/../mlgo
-# RUN: pytype %S/../tests
+# RUN: %python -m pytype %S/../mlgo
+# RUN: %python -m pytype %S/../tests
More information about the llvm-commits
mailing list