[Mlir-commits] [mlir] Added free-threading CPython mode support in MLIR Python bindings (PR #107103)
llvmlistbot at llvm.org
llvmlistbot at llvm.org
Wed Jan 8 02:57:14 PST 2025
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff 32bc029be6265838833623fdd88cc665d5658dc7 18656d9746b003ecf301853286e70e7b437bb828 --extensions h,cpp -- mlir/examples/standalone/python/StandaloneExtensionPybind11.cpp mlir/lib/Bindings/Python/Globals.h mlir/lib/Bindings/Python/IRCore.cpp mlir/lib/Bindings/Python/IRModule.cpp mlir/lib/Bindings/Python/IRModule.h mlir/lib/Bindings/Python/MainModule.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/mlir/lib/Bindings/Python/IRCore.cpp b/mlir/lib/Bindings/Python/IRCore.cpp
index 4d0027ffa1..463ebdebb3 100644
--- a/mlir/lib/Bindings/Python/IRCore.cpp
+++ b/mlir/lib/Bindings/Python/IRCore.cpp
@@ -275,7 +275,7 @@ struct PyGlobalDebugFlag {
});
}
- private:
+private:
static nb::ft_mutex mutex;
};
diff --git a/mlir/lib/Bindings/Python/MainModule.cpp b/mlir/lib/Bindings/Python/MainModule.cpp
index 9bf19f54bc..6f49431006 100644
--- a/mlir/lib/Bindings/Python/MainModule.cpp
+++ b/mlir/lib/Bindings/Python/MainModule.cpp
@@ -30,10 +30,8 @@ NB_MODULE(_mlir, m) {
.def_prop_rw("dialect_search_modules",
&PyGlobals::getDialectSearchPrefixes,
&PyGlobals::setDialectSearchPrefixes)
- .def(
- "append_dialect_search_prefix",
- &PyGlobals::addDialectSearchPrefix,
- "module_name"_a)
+ .def("append_dialect_search_prefix", &PyGlobals::addDialectSearchPrefix,
+ "module_name"_a)
.def(
"_check_dialect_module_loaded",
[](PyGlobals &self, const std::string &dialectNamespace) {
``````````
</details>
https://github.com/llvm/llvm-project/pull/107103
More information about the Mlir-commits
mailing list