| [CI] : Use llvm's python requirements.txt for common py packages. (#4291) Fixes https://github.com/llvm/torch-mlir-release/issues/17 by reusing the common package versions from LLVM's python requirements in torch-mlir's requirement.txt file. Successful build after the change on torch-mlir-release side: https://github.com/sahas3/torch-mlir-release/actions/runs/16911191818 | 10 个月前 |
| Bump the manylinux image used by build_linux_packages.sh (#4376) The current manylinux image ships GCC 10, which has recently started failing to compile torch-mlir (*), see failing CI job: * https://github.com/llvm/torch-mlir-release/actions/runs/19329445043/job/55288631613). This PR bumps manylinux to the next version which happens to bump GCC from 10 to 14. This fixes the build issue. While there may be narrower fixes, the image we use is also quite dated, so updating it is a reasonable path. (*) More specifically, StablehloOptimizationPasses inside the StableHLO submodule. | 8 个月前 |
| Update docs and .env file to reflect PYTHONPATH variability (#4332) This updates the docs and build_tools/write_env_file.sh to correctly identify the PYTHONPATH based on in-tree vs. out-of-tree builds. Additionally, I've updated various build configure commands to include a directive to align Python with Python3, since having conflicting versions of python can cause issues when not explicitly setting both to the same python executable. Resolves https://github.com/llvm/torch-mlir/issues/4331 --------- Signed-off-by: zjgarvey <zjgarvey@gmail.com> | 9 个月前 |
| Drop revert on LLVM c0b42ec05344707d94805ec795a7bc8d33a09594 (#4368) This is a follow-up to #4358. Remove the revert by fixing all deprecated usages of OpBuilder::create, as requested in https://github.com/llvm/llvm-project/commit/c0b42ec05344707d94805ec795a7bc8d33a09594 --------- Signed-off-by: Yu-Zhewen <zhewenyu@amd.com> | 8 个月前 |
| [Torch] Canonicalize pool ops with single int tuple params. (#4250) Fixes https://github.com/llvm/torch-mlir/issues/3885 by repeating the single int to match with expected spatial dims. | 8 个月前 |
| [Torch] Canonicalize pool ops with single int tuple params. (#4250) Fixes https://github.com/llvm/torch-mlir/issues/3885 by repeating the single int to match with expected spatial dims. | 8 个月前 |
| [Torch] Canonicalize pool ops with single int tuple params. (#4250) Fixes https://github.com/llvm/torch-mlir/issues/3885 by repeating the single int to match with expected spatial dims. | 8 个月前 |
| [TORCH] Modified fx_importer to support hop_while_loop (#4338) This PR adds support for emitting graphs for Pytorch HOPs, beginning with torch._higher_order_ops.while_loop. The proposed change is to modify the import_program to call function _import_all_child_modules, which recursively imports the stateless graph for all the children modules. Since HOP operator graphs are stateless graphs with no mutation, it is correct to import them as stateless graphs, although the method import_stateless_graph is marked as "deprecated". --------- Signed-off-by: Keshav Vinayak Jha <keshavvinayakjha@gmail.com> | 8 个月前 |
| [Torch] Canonicalize pool ops with single int tuple params. (#4250) Fixes https://github.com/llvm/torch-mlir/issues/3885 by repeating the single int to match with expected spatial dims. | 8 个月前 |
| Link necessary op interface implementations (#3364) This patch adds two memref passes to torch-mlir-opt, which already occur in the pass pipeline torch-backend-to-linalg-on-tensors-backend-pipeline. Additionally, necessary op interface external models are included to address issue #3352. | 2 年前 |
| [CI] Address miscellaneous Bazel / Clang build failures (#4344) - Adds an explicit dependency for headers used in TorchMLIRInitAll - Addresses a std::accumulate usage issue: https://godbolt.org/z/xs441Ebfe Signed-off-by: Artem Gindinson <gindinson@roofline.ai> | 8 个月前 |
| Add stub numpy dialect. | 6 年前 |
| Add .git-blame-ignore-revs to allow ignoring sweeping formatting changes (#2823) This allows the following command to be used to ignore sweeping formatting changes. git blame --ignore-revs-file .git-blame-ignore-revs <file_of_interest> | 2 年前 |
| [Pipeline] Use dedicated simplification pipeline for TorchDynamo frontend (#3376) Discord Thread: https://discord.com/channels/636084430946959380/1238330633328005243 ## Context: [This](https://github.com/llvm/torch-mlir/blob/main/python/torch_mlir/fx.py#L61) was updated to support e2e tests for the TorchDynamo frontend in Torch-MLIR, where we run FX decompositions and import the FX IR to generate Torch dialect, followed by torch-function-to-torch-backend-pipeline, skipping only the shape/type refinement for now. However, we should be able to skip many of the torch simplification passes, as depicted in the [frontend roadmap](https://github.com/llvm/torch-mlir/blob/main/docs/images/roadmap_frontend.png). Based on IREE's TorchDynamo [pipeline](https://github.com/iree-org/iree/blob/main/compiler/plugins/input/Torch/InputConversion/Passes.cpp#L29), the only two passes we seem to require are: ReduceOpVariantsPass and DecomposeComplexOpsPass. This is inline with our findings as well based on initial exploration. This PR creates a dedicated frontend simplification pipeline for TorchDynamo / FX Importer which calls only ReduceOpVariantsPass and DecomposeComplexOpsPass. We rely on the e2e fx_importer tests to ensure we're not regressing by removing many of the passes that were historically needed for TorchScript. One notable change here is that we do not call the LowerToBackendContractPass anymore, which used to call TorchSimplificationPipeline iteratively until VerifyBackendContract was clean. Some of this was required for the shape/type refinement to converge, which seems a non-issue for Dynamo frontend. Do we anticipate this (the iterative invocation of TorchSimplificationPipeline followed by VerifyBackendContract) to be worth retaining in the Dynamo frontend pipeline? If so, I can make those changes, PLMK. | 2 年前 |
| Drop revert on LLVM c0b42ec05344707d94805ec795a7bc8d33a09594 (#4368) This is a follow-up to #4358. Remove the revert by fixing all deprecated usages of OpBuilder::create, as requested in https://github.com/llvm/llvm-project/commit/c0b42ec05344707d94805ec795a7bc8d33a09594 --------- Signed-off-by: Yu-Zhewen <zhewenyu@amd.com> | 8 个月前 |
| [NFC] Update black version (#3256) * Update black version to support 3.11/3.12 * Reformat code | 2 年前 |
| Add .yamllint and disable some annoying recurring warnings on every pr (#3224) | 2 年前 |
| Add CITATION file (#2371) | 2 年前 |
| Integrate LLVM at 1506ba95d7c3dca1abff0190550945f6cc263a99 (#4230) Update LLVM to https://github.com/llvm/llvm-project/commit/1506ba95d7c3dca1abff0190550945f6cc263a99. --------- Signed-off-by: Vivek Khandelwal <vivekkhandelwal1424@gmail.com> Co-authored-by: https://github.com/penguin-wwy | 1 年前 |
| Dual license the torch-mlir project. This commit (with approval from all contributors) dual licenses the torch-mlir project under both the standard LLVM license and the standard PyTorch license. This will facilitate moving code between torch-mlir and the two upstream projects. The standard file comment is now: // This file is licensed under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // Also available under a BSD-style license. See LICENSE. See LICENSE in the project root for the terms of both licenses. | 4 年前 |
| [torch-mlir][doc] remove MPACT as example (#3930) Per Stella's request | 1 年前 |
| [CI] : Pin back ninja to older version on windows. (#4378) Windows build is failing https://github.com/llvm/torch-mlir/actions/runs/19180245913/job/54834980057#step:8:6030 LINK: command "C:\PROGRA~1\MICROS~2\2022\ENTERP~1\VC\Tools\MSVC\1444~1.352\bin\Hostx64\x64\link.exe /nologo @CMakeFiles\TorchMLIRAggregateCAPI.rsp /out:tools\torch-mlir\python_packages\torch_mlir\torch_mlir\_mlir_libs\TorchMLIRAggregateCAPI.dll /implib:tools\torch-mlir\python_packages\torch_mlir\torch_mlir\_mlir_libs\TorchMLIRAggregateCAPI.lib /pdb:tools\torch-mlir\python_packages\torch_mlir\torch_mlir\_mlir_libs\TorchMLIRAggregateCAPI.pdb /dll /version:0.0 /machine:x64 /INCREMENTAL:NO /DEF:tools\torch-mlir\python\CMakeFiles\TorchMLIRAggregateCAPI.dir\.\exports.def /MANIFEST:EMBED,ID=2" failed (exit code 1181) with the following output: LINK : fatal error LNK1181: cannot open input file 'LIRAggregateCAPI.dir\D_\a\torch-mlir\torch-mlir\externals\llvm-project\llvm\resources\windows_version_resource.rc.res' due to the ninja issue mentioned in https://github.com/ninja-build/ninja/issues/2616 Pinning back to older ninja version on windows. | 8 个月前 |
| Switch to pre-commit for lint checks. (#3200) Users can run via pre-commit run or set up a hook as described in the instructions: https://pre-commit.com/ The CI is set to only run pre-commit on files changed in the patch. We will run with --all-files in a separate patch. | 2 年前 |
| Handle pytorch pybind11 changes and bump nightly pins (#4352) I think this is the simplest approach, for now, to resolve https://github.com/llvm/torch-mlir/issues/4343 It would be good to eventually finish https://github.com/llvm/torch-mlir/pull/4348 ; however, it became a bit too much to rework the generated sources scripts in a timely fashion. See also another parallel attempt to address the ci problems: #4345 This PR modifies the Cmake pytorch configure function to simply not set any TORCH_CXX_FLAGS whenever pytorch is missing the old PYBIND_BUILD_ABI tag. I think whatever compiler flags we were pushing through to make pybind think we are GCC and to use a specific ABI version is just completely unnecessary now. I was worried we might need to update our pybind version in the requirements, but it appears to not be relevant. Additionally, nightly pins are updated and small fixes are made to resolve misc failures in tests after the bump. --------- Signed-off-by: zjgarvey <zjgarvey@gmail.com> | 9 个月前 |
| Handle pytorch pybind11 changes and bump nightly pins (#4352) I think this is the simplest approach, for now, to resolve https://github.com/llvm/torch-mlir/issues/4343 It would be good to eventually finish https://github.com/llvm/torch-mlir/pull/4348 ; however, it became a bit too much to rework the generated sources scripts in a timely fashion. See also another parallel attempt to address the ci problems: #4345 This PR modifies the Cmake pytorch configure function to simply not set any TORCH_CXX_FLAGS whenever pytorch is missing the old PYBIND_BUILD_ABI tag. I think whatever compiler flags we were pushing through to make pybind think we are GCC and to use a specific ABI version is just completely unnecessary now. I was worried we might need to update our pybind version in the requirements, but it appears to not be relevant. Additionally, nightly pins are updated and small fixes are made to resolve misc failures in tests after the bump. --------- Signed-off-by: zjgarvey <zjgarvey@gmail.com> | 9 个月前 |
| python: separate build- and test-related pip dependencies (#1874) We want to ensure that pip packages required for building torch-mlir should be included in the dependencies of torch-mlir, but we don't want the pip packages required for _testing_ of torch-mlir to be included among the dependencies. To be able to specify and install one set of dependencies and not the other, this patch separates the pip packages into two files: build-requirements.txt and test-requirements.txt. This patch also updates references to the requirements.txt file so that CI builds that run end-to-end tests install test-related pip dependencies while everything else (including WHL builds) sticks to just the build-related pip dependencies. Despite this change, this patch should not affect a torch-mlir developer's workflow. More precisely, since this patch makes the top-level requirements.txt file refer to both build-requirements.txt and test-requirements.txt files, a torch-mlir developer should be able to continue referring to the requirements.txt file without any impact. | 3 年前 |
| [wheel] set MLIR_BINDINGS_PYTHON_NB_DOMAIN correctly (#4385) See https://github.com/llvm/lighthouse/issues/14 | 8 个月前 |
| Bump Onnx Version to 1.16.1 (#3515) This commit adds the support for new data types: uint4, and int4 and uint8 tensor protos. Also, it moves some tests from failing to crashing. Fixes https://github.com/llvm/torch-mlir/issues/3507 Signed-Off By: Vivek Khandelwal <vivekkhandelwal1424@gmail.com> | 2 年前 |
| Handle pytorch pybind11 changes and bump nightly pins (#4352) I think this is the simplest approach, for now, to resolve https://github.com/llvm/torch-mlir/issues/4343 It would be good to eventually finish https://github.com/llvm/torch-mlir/pull/4348 ; however, it became a bit too much to rework the generated sources scripts in a timely fashion. See also another parallel attempt to address the ci problems: #4345 This PR modifies the Cmake pytorch configure function to simply not set any TORCH_CXX_FLAGS whenever pytorch is missing the old PYBIND_BUILD_ABI tag. I think whatever compiler flags we were pushing through to make pybind think we are GCC and to use a specific ABI version is just completely unnecessary now. I was worried we might need to update our pybind version in the requirements, but it appears to not be relevant. Additionally, nightly pins are updated and small fixes are made to resolve misc failures in tests after the bump. --------- Signed-off-by: zjgarvey <zjgarvey@gmail.com> | 9 个月前 |
| Add ARM64 release builds (#2159) Creates a build_linux_arm64 job that builds the release on an arm64 self-hosted runner. Drop Python 3.10 support Pass TM_TORCH_VERSION to choose the Stable PyTorch version (since arm64 doesn't have nightly builds) Borrows nightly / stable Pytorch switch from the WIP https://github.com/llvm/torch-mlir/pull/2038 | 3 年前 |