Skip to content

Commit 5d05f0a

Browse files
authored
Fix CPU tests for python 3.12 (#9443)
1 parent 66ad14f commit 5d05f0a

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

test/run_tests.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,9 @@ function run_torch_op_tests {
123123
run_test_without_functionalization "$_TEST_DIR/../../test/test_view_ops.py" "$@" -v TestViewOpsXLA
124124
run_test "$_TEST_DIR/../../test/test_torch.py" "$@" -v TestTorchDeviceTypeXLA
125125
run_dynamic "$_TEST_DIR/../../test/test_torch.py" "$@" -v TestDevicePrecisionXLA
126-
run_test "$_TEST_DIR/../../test/test_torch.py" "$@" -v TestTensorDeviceOpsXLA
126+
# TODO https://github.com/pytorch/xla/issues/9459: Investigate why this
127+
# doesn't run any tests.
128+
# run_test "$_TEST_DIR/../../test/test_torch.py" "$@" -v TestTensorDeviceOpsXLA
127129
run_test "$_TEST_DIR/../../test/test_indexing.py" "$@" -v TestIndexingXLA
128130
run_test "$_TEST_DIR/../../test/test_indexing.py" "$@" -v NumpyTestsXLA
129131
# run_dynamic "$_TEST_DIR/../../test/test_nn.py" "$@" -v TestNNDeviceTypeXLA

torch_xla/csrc/init_python_bindings.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2268,7 +2268,6 @@ void InitXlaModuleBindings(py::module m) {
22682268
[](const std::vector<at::Tensor>& tensors, const std::string& device,
22692269
const std::vector<std::string>& devices,
22702270
bool emit_bytecode) -> py::bytes {
2271-
NoGilSection nogil;
22722271
EmitMode mode = emit_bytecode ? EmitMode::kStableHloBytecode
22732272
: EmitMode::kStableHloReadable;
22742273
std::vector<XLATensorPtr> xtensors;

0 commit comments

Comments
 (0)