summaryrefslogtreecommitdiff
path: root/llvm-core/mlir
diff options
context:
space:
mode:
authorroot <root@alpha.trunkmasters.com>2026-08-30 03:04:44 -0500
committerroot <root@alpha.trunkmasters.com>2026-08-30 03:04:44 -0500
commitacb1593a8b3f287b06b8e2073eff6a70f02e2c4f (patch)
tree950eb19e1852de9b256fb61d164281c48f3d296c /llvm-core/mlir
parent675018c33e0383ac7d40ba2922d90d811382accc (diff)
downloadbaldeagleos-repo-acb1593a8b3f287b06b8e2073eff6a70f02e2c4f.tar.gz
baldeagleos-repo-acb1593a8b3f287b06b8e2073eff6a70f02e2c4f.tar.xz
baldeagleos-repo-acb1593a8b3f287b06b8e2073eff6a70f02e2c4f.zip
Adding metadata
Diffstat (limited to 'llvm-core/mlir')
-rw-r--r--llvm-core/mlir/Manifest5
-rw-r--r--llvm-core/mlir/mlir-23.1.0.9999.ebuild232
-rw-r--r--llvm-core/mlir/mlir-23.1.0.ebuild3
-rw-r--r--llvm-core/mlir/mlir-23.1.0_pre20260724.ebuild232
-rw-r--r--llvm-core/mlir/mlir-23.1.0_rc2.ebuild232
-rw-r--r--llvm-core/mlir/mlir-23.1.0_rc3.ebuild232
6 files changed, 2 insertions, 934 deletions
diff --git a/llvm-core/mlir/Manifest b/llvm-core/mlir/Manifest
index f16f924a7146..0b726514e16a 100644
--- a/llvm-core/mlir/Manifest
+++ b/llvm-core/mlir/Manifest
@@ -3,10 +3,5 @@ DIST llvm-project-21.1.8.src.tar.xz 158958576 BLAKE2B 0d3d4ee920f8e5db50e9815261
DIST llvm-project-21.1.8.src.tar.xz.sig 119 BLAKE2B cffc1825f5778a3e3c128ec3e856ff6ee50687319d621cdf42e895abf67e05cc51cb7493308e2b506ab60dbdbaca7aa75eb9f78d91d42c81f9682a36f4042e9d SHA512 10f58eff58ed6e701d0f123b15e68c82ab8cbdf99b1c86c0d83e3b8553e90ea51055e30327e8e442ded57c8f503e2a2de9ee075e9c28b5ba815a0f8922f8671c
DIST llvm-project-22.1.8.src.tar.xz 167061596 BLAKE2B 092204f62e0f0364a041c737eb2c25fd073cb5689663d6ccd5a9e4e1743d6d80822360d59b64bff7b4d7872a68a79e899bf2f75f384e55c7d313a79243576f03 SHA512 2615b20ba08534f83ab8ecc7b5ba43b5f1dfcf9cdb2534a32fcdbf0ccdd9a008b46276e45ef26ed9377f65b5e4ae89ea798f3863fd034484b5715140f3a7b35c
DIST llvm-project-22.1.8.src.tar.xz.sig 119 BLAKE2B 2ce93472036e68782252991e4a8bdbeeec8706a56022220083a38a42ef18714a7894c41aaa04dc0d03f18601d8bfc1a5a030ed0ef0f0d64a662eae9843a4b362 SHA512 99a457b5b1fb409a5fe72b59ebd4ddae5cade3e5f2493e33b44d4f4b4625f7a1743f80106efb1134668842b15ea3400ce2c29263bec8ff986e05040910125e15
-DIST llvm-project-23.1.0-rc2.src.tar.xz 179079292 BLAKE2B 59b4ae719ca496b29e37c1150d2953062d00d696e847d16710b6719c63246cccfb50c6f6bf33e7723e2e3757c8b1cae51a3c6a6787b6d45c808c78902ac01c97 SHA512 9ca8d0aa34f2910abc06edb832831c1a66209e7e78cffabcc52113fe0d6d96af57f4f67788ae23026c0f3b91dc8f6224cb46dfa0f1bcc41a1f60cbad5ec1623d
-DIST llvm-project-23.1.0-rc2.src.tar.xz.sig 466 BLAKE2B c7acaa7f8833286cd0037c4c31ba8a1bb20f4a09b62979c7df9f69993728406b1a42db62d2ab2a34c526c0bdae1bc027074a623142420d2fc264c3f83e3c0f7b SHA512 7e2db57ed17efe3bf36c476049973b760af60c8a9302992a17e050e7a61db7b92df0b6c06f26989c61ce2e4682e7604bfdd0f063e322a726923e857890cedc8c
-DIST llvm-project-23.1.0-rc3.src.tar.xz 179126732 BLAKE2B f0843aacbf9ebd57929dbba0436773775dc121223ae3a81d1c30bd5a3ccba136359b9e483d2be58546dc6bf468743711d5057f8b1486e5ba4d59a96136426c3c SHA512 0c9bdf4c75784269bd4560d94126e667d1d145da2f6db4d94f437b2388880f3dcb52f85c0580d78e2597b141511a4b7ddadfc31f83b690d5cd383e84330ce247
-DIST llvm-project-23.1.0-rc3.src.tar.xz.sig 466 BLAKE2B c7bd61c1cab2bdb4c8026aa095f7543e7c2f50520531f3ca6bd8c0cb78b2a7770d39723cec6effe9366c260d01b0db2bfd072281790b63b7d0d8b48339f51c42 SHA512 751f602d29235d4ce58a0d38c23f360977cb9e978e04399b3032053e7168903a721d307f001864b73fef8f567023eebe8f4fdbf4124667789d0afaff57b01d7d
DIST llvm-project-23.1.0.src.tar.xz 179140728 BLAKE2B 9253189469c70b1e7e326851635934fab85bf64139f1dcd44721ab261c097c9980276d48eac705b999cde0a024a362191c719646956504364534585dbf57d643 SHA512 f87a6084a4b4ddbf155949bb0a9d95592e665683d03db59c65002520634db57bb0b9e90011cbdf1dfc72bf2c649cebc5c546a1de4811c3bfc0b89620b1669061
DIST llvm-project-23.1.0.src.tar.xz.sig 119 BLAKE2B 6bd4f681aa0926b3a8e896993fcb238749a5b29dd26f6637e5543699334c0818223d9c798da35515f27fd197cc7de370cc70de3e1bb6721e6c7cac3050879fc7 SHA512 3b1ffaf6fbc6ed08c1d0523b565fb63cbde1a76344bb3ed1a53722482927c03e2652859ef44de962ce90bdb7c5711db63f8d98559bc86cb58294a1cfc62e4b4f
-DIST llvm-project-bb9934d4dfef9033ded36d26827dbb6d3ac1dd92.tar.gz 277566365 BLAKE2B 401320655d19b3d430d15a48e2daf1f00567ef87fd2d1f86c3d505a1b2f5920db6cbfa620bf1b0561cd318d6046830d5b19fe0e7b58647863372c6c96526526c SHA512 354b901ca80227abe6b0514eeba437f237ea2658dd1927bb6e1d3b0b298bdb0dfdb7855c0f359eea4977dd344f6d0f6d1ce486ea0100d4a5615a9139ef198fca
diff --git a/llvm-core/mlir/mlir-23.1.0.9999.ebuild b/llvm-core/mlir/mlir-23.1.0.9999.ebuild
deleted file mode 100644
index b93f132d90ae..000000000000
--- a/llvm-core/mlir/mlir-23.1.0.9999.ebuild
+++ /dev/null
@@ -1,232 +0,0 @@
-# Copyright 1999-2026 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{13..14} )
-inherit cmake llvm.org multilib-minimal python-any-r1
-
-DESCRIPTION="Multi-Level Intermediate Representation (library only)"
-HOMEPAGE="https://mlir.llvm.org/"
-
-LICENSE="Apache-2.0-with-LLVM-exceptions"
-SLOT="${LLVM_MAJOR}/${LLVM_SOABI}"
-IUSE="+debug test"
-RESTRICT="!test? ( test )"
-
-DEPEND="
- ~llvm-core/llvm-${PV}[debug=,${MULTILIB_USEDEP}]
-"
-RDEPEND="
- ${DEPEND}
-"
-BDEPEND="
- ${PYTHON_DEPS}
- llvm-core/llvm:${LLVM_MAJOR}
- test? (
- $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]')
- )
-"
-
-LLVM_COMPONENTS=( mlir cmake )
-# tablegen tests use *.td files there
-LLVM_TEST_COMPONENTS=( llvm/include )
-llvm.org_set_globals
-
-python_check_deps() {
- if use test; then
- python_has_version "dev-python/lit[${PYTHON_USEDEP}]"
- fi
-}
-
-src_prepare() {
- llvm.org_src_prepare
-
- # https://github.com/llvm/llvm-project/issues/120902
- sed -i -e '/LINK_LIBS/s:PUBLIC:PRIVATE:' \
- lib/ExecutionEngine/CMakeLists.txt || die
-
- # this test is completely unpredictable, no clue why
- rm test/mlir-pdll-lsp-server/view-output.test || die
-}
-
-check_distribution_components() {
- if [[ ${CMAKE_MAKEFILE_GENERATOR} == ninja ]]; then
- local all_targets=() my_targets=() l
- cd "${BUILD_DIR}" || die
-
- while read -r l; do
- if [[ ${l} == install-*-stripped:* ]]; then
- l=${l#install-}
- l=${l%%-stripped*}
-
- case ${l} in
- # meta-targets
- mlir-libraries|distribution)
- continue
- ;;
- # dylib
- MLIR)
- ;;
- # installed test libraries
- MLIRTestAnalysis|MLIRTestDialect|MLIRTestIR)
- ;;
- MLIROpenACCTestPasses)
- ;;
- # static libraries
- MLIR*)
- continue
- ;;
- esac
-
- all_targets+=( "${l}" )
- fi
- done < <(${NINJA} -t targets all)
-
- while read -r l; do
- my_targets+=( "${l}" )
- done < <(get_distribution_components $"\n")
-
- local add=() remove=()
- for l in "${all_targets[@]}"; do
- if ! has "${l}" "${my_targets[@]}"; then
- add+=( "${l}" )
- fi
- done
- for l in "${my_targets[@]}"; do
- if ! has "${l}" "${all_targets[@]}"; then
- remove+=( "${l}" )
- fi
- done
-
- if [[ ${#add[@]} -gt 0 || ${#remove[@]} -gt 0 ]]; then
- eqawarn "get_distribution_components() is outdated!"
- eqawarn " Add: ${add[*]}"
- eqawarn "Remove: ${remove[*]}"
- fi
- cd - >/dev/null || die
- fi
-}
-
-get_distribution_components() {
- local sep=${1-;}
-
- local out=(
- mlir-cmake-exports
- mlir-headers
-
- # the dylib
- MLIR
-
- # shared libraries
- mlir_apfloat_wrappers
- mlir_arm_runner_utils
- mlir_arm_sme_abi_stubs
- mlir_async_runtime
- mlir_c_runner_utils
- mlir_float16_utils
- mlir_runner_utils
-
- # test libraries required by flang
- MLIROpenACCTestPasses
- MLIRTestAnalysis
- MLIRTestDialect
- MLIRTestIR
- )
-
- if multilib_is_native_abi; then
- out+=(
- # tools
- mlir-linalg-ods-yaml-gen
- mlir-lsp-server
- mlir-opt
- mlir-pdll
- mlir-pdll-lsp-server
- mlir-query
- mlir-reduce
- mlir-rewrite
- mlir-runner
- mlir-tblgen
- mlir-translate
- tblgen-lsp-server
- tblgen-to-irdl
- )
- fi
-
- printf "%s${sep}" "${out[@]}"
-}
-
-multilib_src_configure() {
- local mycmakeargs=(
- -DCMAKE_INSTALL_PREFIX="${EPREFIX}/usr/lib/llvm/${LLVM_MAJOR}"
- -DLLVM_ROOT="${ESYSROOT}/usr/lib/llvm/${LLVM_MAJOR}"
-
- -DBUILD_SHARED_LIBS=OFF
- # this controls building libMLIR.so
- -DLLVM_BUILD_LLVM_DYLIB=ON
- -DMLIR_BUILD_MLIR_C_DYLIB=OFF
- -DMLIR_LINK_MLIR_DYLIB=ON
- -DMLIR_INCLUDE_TESTS=ON
- -DMLIR_INCLUDE_INTEGRATION_TESTS=OFF
- -DLLVM_DISTRIBUTION_COMPONENTS=$(get_distribution_components)
- # this enables installing mlir-tblgen and mlir-pdll
- -DLLVM_BUILD_UTILS=ON
-
- -DPython3_EXECUTABLE="${PYTHON}"
-
- -DLLVM_BUILD_TOOLS=ON
- # TODO
- -DMLIR_ENABLE_CUDA_RUNNER=0
- -DMLIR_ENABLE_ROCM_RUNNER=0
- -DMLIR_ENABLE_SYCL_RUNNER=0
- -DMLIR_ENABLE_SPIRV_CPU_RUNNER=0
- -DMLIR_ENABLE_VULKAN_RUNNER=0
- -DMLIR_ENABLE_BINDINGS_PYTHON=0
- -DMLIR_INSTALL_AGGREGATE_OBJECTS=OFF
- )
- use test && mycmakeargs+=(
- -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit"
- -DLLVM_LIT_ARGS="$(get_lit_flags)"
- )
-
- # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844
- use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG"
- cmake_src_configure
-
- multilib_is_native_abi && check_distribution_components
-}
-
-multilib_src_compile() {
- cmake_build distribution
-}
-
-multilib_src_test() {
- local known_xfail=()
-
- case ${ABI} in
- arm|ppc|x86)
- known_xfail+=(
- # MLIR is full of 64-bit assumptions, sigh
- # https://github.com/llvm/llvm-project/issues/124541
- Dialect/Bufferization/Transforms/one-shot-bufferize-pass-statistics.mlir
- Dialect/LLVMIR/sroa-statistics.mlir
- Dialect/Linalg/vectorize-tensor-extract.mlir
- Dialect/MemRef/mem2reg-statistics.mlir
- Dialect/Tensor/fold-tensor-subset-ops.mlir
- Dialect/Tensor/tracking-listener.mlir
- Pass/pipeline-stats-nested.mlir
- Pass/pipeline-stats.mlir
- )
- ;;
- esac
-
- # respect TMPDIR!
- local -x LIT_PRESERVES_TMP=1
- local -x LIT_XFAIL="${known_xfail[*]}"
- LIT_XFAIL=${LIT_XFAIL// /;}
- cmake_build check-mlir
-}
-
-multilib_src_install() {
- DESTDIR=${D} cmake_build install-distribution
-}
diff --git a/llvm-core/mlir/mlir-23.1.0.ebuild b/llvm-core/mlir/mlir-23.1.0.ebuild
index b93f132d90ae..cee43b8d806a 100644
--- a/llvm-core/mlir/mlir-23.1.0.ebuild
+++ b/llvm-core/mlir/mlir-23.1.0.ebuild
@@ -11,7 +11,8 @@ HOMEPAGE="https://mlir.llvm.org/"
LICENSE="Apache-2.0-with-LLVM-exceptions"
SLOT="${LLVM_MAJOR}/${LLVM_SOABI}"
-IUSE="+debug test"
+KEYWORDS="~amd64 ~arm64"
+IUSE="debug test"
RESTRICT="!test? ( test )"
DEPEND="
diff --git a/llvm-core/mlir/mlir-23.1.0_pre20260724.ebuild b/llvm-core/mlir/mlir-23.1.0_pre20260724.ebuild
deleted file mode 100644
index b93f132d90ae..000000000000
--- a/llvm-core/mlir/mlir-23.1.0_pre20260724.ebuild
+++ /dev/null
@@ -1,232 +0,0 @@
-# Copyright 1999-2026 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{13..14} )
-inherit cmake llvm.org multilib-minimal python-any-r1
-
-DESCRIPTION="Multi-Level Intermediate Representation (library only)"
-HOMEPAGE="https://mlir.llvm.org/"
-
-LICENSE="Apache-2.0-with-LLVM-exceptions"
-SLOT="${LLVM_MAJOR}/${LLVM_SOABI}"
-IUSE="+debug test"
-RESTRICT="!test? ( test )"
-
-DEPEND="
- ~llvm-core/llvm-${PV}[debug=,${MULTILIB_USEDEP}]
-"
-RDEPEND="
- ${DEPEND}
-"
-BDEPEND="
- ${PYTHON_DEPS}
- llvm-core/llvm:${LLVM_MAJOR}
- test? (
- $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]')
- )
-"
-
-LLVM_COMPONENTS=( mlir cmake )
-# tablegen tests use *.td files there
-LLVM_TEST_COMPONENTS=( llvm/include )
-llvm.org_set_globals
-
-python_check_deps() {
- if use test; then
- python_has_version "dev-python/lit[${PYTHON_USEDEP}]"
- fi
-}
-
-src_prepare() {
- llvm.org_src_prepare
-
- # https://github.com/llvm/llvm-project/issues/120902
- sed -i -e '/LINK_LIBS/s:PUBLIC:PRIVATE:' \
- lib/ExecutionEngine/CMakeLists.txt || die
-
- # this test is completely unpredictable, no clue why
- rm test/mlir-pdll-lsp-server/view-output.test || die
-}
-
-check_distribution_components() {
- if [[ ${CMAKE_MAKEFILE_GENERATOR} == ninja ]]; then
- local all_targets=() my_targets=() l
- cd "${BUILD_DIR}" || die
-
- while read -r l; do
- if [[ ${l} == install-*-stripped:* ]]; then
- l=${l#install-}
- l=${l%%-stripped*}
-
- case ${l} in
- # meta-targets
- mlir-libraries|distribution)
- continue
- ;;
- # dylib
- MLIR)
- ;;
- # installed test libraries
- MLIRTestAnalysis|MLIRTestDialect|MLIRTestIR)
- ;;
- MLIROpenACCTestPasses)
- ;;
- # static libraries
- MLIR*)
- continue
- ;;
- esac
-
- all_targets+=( "${l}" )
- fi
- done < <(${NINJA} -t targets all)
-
- while read -r l; do
- my_targets+=( "${l}" )
- done < <(get_distribution_components $"\n")
-
- local add=() remove=()
- for l in "${all_targets[@]}"; do
- if ! has "${l}" "${my_targets[@]}"; then
- add+=( "${l}" )
- fi
- done
- for l in "${my_targets[@]}"; do
- if ! has "${l}" "${all_targets[@]}"; then
- remove+=( "${l}" )
- fi
- done
-
- if [[ ${#add[@]} -gt 0 || ${#remove[@]} -gt 0 ]]; then
- eqawarn "get_distribution_components() is outdated!"
- eqawarn " Add: ${add[*]}"
- eqawarn "Remove: ${remove[*]}"
- fi
- cd - >/dev/null || die
- fi
-}
-
-get_distribution_components() {
- local sep=${1-;}
-
- local out=(
- mlir-cmake-exports
- mlir-headers
-
- # the dylib
- MLIR
-
- # shared libraries
- mlir_apfloat_wrappers
- mlir_arm_runner_utils
- mlir_arm_sme_abi_stubs
- mlir_async_runtime
- mlir_c_runner_utils
- mlir_float16_utils
- mlir_runner_utils
-
- # test libraries required by flang
- MLIROpenACCTestPasses
- MLIRTestAnalysis
- MLIRTestDialect
- MLIRTestIR
- )
-
- if multilib_is_native_abi; then
- out+=(
- # tools
- mlir-linalg-ods-yaml-gen
- mlir-lsp-server
- mlir-opt
- mlir-pdll
- mlir-pdll-lsp-server
- mlir-query
- mlir-reduce
- mlir-rewrite
- mlir-runner
- mlir-tblgen
- mlir-translate
- tblgen-lsp-server
- tblgen-to-irdl
- )
- fi
-
- printf "%s${sep}" "${out[@]}"
-}
-
-multilib_src_configure() {
- local mycmakeargs=(
- -DCMAKE_INSTALL_PREFIX="${EPREFIX}/usr/lib/llvm/${LLVM_MAJOR}"
- -DLLVM_ROOT="${ESYSROOT}/usr/lib/llvm/${LLVM_MAJOR}"
-
- -DBUILD_SHARED_LIBS=OFF
- # this controls building libMLIR.so
- -DLLVM_BUILD_LLVM_DYLIB=ON
- -DMLIR_BUILD_MLIR_C_DYLIB=OFF
- -DMLIR_LINK_MLIR_DYLIB=ON
- -DMLIR_INCLUDE_TESTS=ON
- -DMLIR_INCLUDE_INTEGRATION_TESTS=OFF
- -DLLVM_DISTRIBUTION_COMPONENTS=$(get_distribution_components)
- # this enables installing mlir-tblgen and mlir-pdll
- -DLLVM_BUILD_UTILS=ON
-
- -DPython3_EXECUTABLE="${PYTHON}"
-
- -DLLVM_BUILD_TOOLS=ON
- # TODO
- -DMLIR_ENABLE_CUDA_RUNNER=0
- -DMLIR_ENABLE_ROCM_RUNNER=0
- -DMLIR_ENABLE_SYCL_RUNNER=0
- -DMLIR_ENABLE_SPIRV_CPU_RUNNER=0
- -DMLIR_ENABLE_VULKAN_RUNNER=0
- -DMLIR_ENABLE_BINDINGS_PYTHON=0
- -DMLIR_INSTALL_AGGREGATE_OBJECTS=OFF
- )
- use test && mycmakeargs+=(
- -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit"
- -DLLVM_LIT_ARGS="$(get_lit_flags)"
- )
-
- # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844
- use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG"
- cmake_src_configure
-
- multilib_is_native_abi && check_distribution_components
-}
-
-multilib_src_compile() {
- cmake_build distribution
-}
-
-multilib_src_test() {
- local known_xfail=()
-
- case ${ABI} in
- arm|ppc|x86)
- known_xfail+=(
- # MLIR is full of 64-bit assumptions, sigh
- # https://github.com/llvm/llvm-project/issues/124541
- Dialect/Bufferization/Transforms/one-shot-bufferize-pass-statistics.mlir
- Dialect/LLVMIR/sroa-statistics.mlir
- Dialect/Linalg/vectorize-tensor-extract.mlir
- Dialect/MemRef/mem2reg-statistics.mlir
- Dialect/Tensor/fold-tensor-subset-ops.mlir
- Dialect/Tensor/tracking-listener.mlir
- Pass/pipeline-stats-nested.mlir
- Pass/pipeline-stats.mlir
- )
- ;;
- esac
-
- # respect TMPDIR!
- local -x LIT_PRESERVES_TMP=1
- local -x LIT_XFAIL="${known_xfail[*]}"
- LIT_XFAIL=${LIT_XFAIL// /;}
- cmake_build check-mlir
-}
-
-multilib_src_install() {
- DESTDIR=${D} cmake_build install-distribution
-}
diff --git a/llvm-core/mlir/mlir-23.1.0_rc2.ebuild b/llvm-core/mlir/mlir-23.1.0_rc2.ebuild
deleted file mode 100644
index b93f132d90ae..000000000000
--- a/llvm-core/mlir/mlir-23.1.0_rc2.ebuild
+++ /dev/null
@@ -1,232 +0,0 @@
-# Copyright 1999-2026 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{13..14} )
-inherit cmake llvm.org multilib-minimal python-any-r1
-
-DESCRIPTION="Multi-Level Intermediate Representation (library only)"
-HOMEPAGE="https://mlir.llvm.org/"
-
-LICENSE="Apache-2.0-with-LLVM-exceptions"
-SLOT="${LLVM_MAJOR}/${LLVM_SOABI}"
-IUSE="+debug test"
-RESTRICT="!test? ( test )"
-
-DEPEND="
- ~llvm-core/llvm-${PV}[debug=,${MULTILIB_USEDEP}]
-"
-RDEPEND="
- ${DEPEND}
-"
-BDEPEND="
- ${PYTHON_DEPS}
- llvm-core/llvm:${LLVM_MAJOR}
- test? (
- $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]')
- )
-"
-
-LLVM_COMPONENTS=( mlir cmake )
-# tablegen tests use *.td files there
-LLVM_TEST_COMPONENTS=( llvm/include )
-llvm.org_set_globals
-
-python_check_deps() {
- if use test; then
- python_has_version "dev-python/lit[${PYTHON_USEDEP}]"
- fi
-}
-
-src_prepare() {
- llvm.org_src_prepare
-
- # https://github.com/llvm/llvm-project/issues/120902
- sed -i -e '/LINK_LIBS/s:PUBLIC:PRIVATE:' \
- lib/ExecutionEngine/CMakeLists.txt || die
-
- # this test is completely unpredictable, no clue why
- rm test/mlir-pdll-lsp-server/view-output.test || die
-}
-
-check_distribution_components() {
- if [[ ${CMAKE_MAKEFILE_GENERATOR} == ninja ]]; then
- local all_targets=() my_targets=() l
- cd "${BUILD_DIR}" || die
-
- while read -r l; do
- if [[ ${l} == install-*-stripped:* ]]; then
- l=${l#install-}
- l=${l%%-stripped*}
-
- case ${l} in
- # meta-targets
- mlir-libraries|distribution)
- continue
- ;;
- # dylib
- MLIR)
- ;;
- # installed test libraries
- MLIRTestAnalysis|MLIRTestDialect|MLIRTestIR)
- ;;
- MLIROpenACCTestPasses)
- ;;
- # static libraries
- MLIR*)
- continue
- ;;
- esac
-
- all_targets+=( "${l}" )
- fi
- done < <(${NINJA} -t targets all)
-
- while read -r l; do
- my_targets+=( "${l}" )
- done < <(get_distribution_components $"\n")
-
- local add=() remove=()
- for l in "${all_targets[@]}"; do
- if ! has "${l}" "${my_targets[@]}"; then
- add+=( "${l}" )
- fi
- done
- for l in "${my_targets[@]}"; do
- if ! has "${l}" "${all_targets[@]}"; then
- remove+=( "${l}" )
- fi
- done
-
- if [[ ${#add[@]} -gt 0 || ${#remove[@]} -gt 0 ]]; then
- eqawarn "get_distribution_components() is outdated!"
- eqawarn " Add: ${add[*]}"
- eqawarn "Remove: ${remove[*]}"
- fi
- cd - >/dev/null || die
- fi
-}
-
-get_distribution_components() {
- local sep=${1-;}
-
- local out=(
- mlir-cmake-exports
- mlir-headers
-
- # the dylib
- MLIR
-
- # shared libraries
- mlir_apfloat_wrappers
- mlir_arm_runner_utils
- mlir_arm_sme_abi_stubs
- mlir_async_runtime
- mlir_c_runner_utils
- mlir_float16_utils
- mlir_runner_utils
-
- # test libraries required by flang
- MLIROpenACCTestPasses
- MLIRTestAnalysis
- MLIRTestDialect
- MLIRTestIR
- )
-
- if multilib_is_native_abi; then
- out+=(
- # tools
- mlir-linalg-ods-yaml-gen
- mlir-lsp-server
- mlir-opt
- mlir-pdll
- mlir-pdll-lsp-server
- mlir-query
- mlir-reduce
- mlir-rewrite
- mlir-runner
- mlir-tblgen
- mlir-translate
- tblgen-lsp-server
- tblgen-to-irdl
- )
- fi
-
- printf "%s${sep}" "${out[@]}"
-}
-
-multilib_src_configure() {
- local mycmakeargs=(
- -DCMAKE_INSTALL_PREFIX="${EPREFIX}/usr/lib/llvm/${LLVM_MAJOR}"
- -DLLVM_ROOT="${ESYSROOT}/usr/lib/llvm/${LLVM_MAJOR}"
-
- -DBUILD_SHARED_LIBS=OFF
- # this controls building libMLIR.so
- -DLLVM_BUILD_LLVM_DYLIB=ON
- -DMLIR_BUILD_MLIR_C_DYLIB=OFF
- -DMLIR_LINK_MLIR_DYLIB=ON
- -DMLIR_INCLUDE_TESTS=ON
- -DMLIR_INCLUDE_INTEGRATION_TESTS=OFF
- -DLLVM_DISTRIBUTION_COMPONENTS=$(get_distribution_components)
- # this enables installing mlir-tblgen and mlir-pdll
- -DLLVM_BUILD_UTILS=ON
-
- -DPython3_EXECUTABLE="${PYTHON}"
-
- -DLLVM_BUILD_TOOLS=ON
- # TODO
- -DMLIR_ENABLE_CUDA_RUNNER=0
- -DMLIR_ENABLE_ROCM_RUNNER=0
- -DMLIR_ENABLE_SYCL_RUNNER=0
- -DMLIR_ENABLE_SPIRV_CPU_RUNNER=0
- -DMLIR_ENABLE_VULKAN_RUNNER=0
- -DMLIR_ENABLE_BINDINGS_PYTHON=0
- -DMLIR_INSTALL_AGGREGATE_OBJECTS=OFF
- )
- use test && mycmakeargs+=(
- -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit"
- -DLLVM_LIT_ARGS="$(get_lit_flags)"
- )
-
- # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844
- use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG"
- cmake_src_configure
-
- multilib_is_native_abi && check_distribution_components
-}
-
-multilib_src_compile() {
- cmake_build distribution
-}
-
-multilib_src_test() {
- local known_xfail=()
-
- case ${ABI} in
- arm|ppc|x86)
- known_xfail+=(
- # MLIR is full of 64-bit assumptions, sigh
- # https://github.com/llvm/llvm-project/issues/124541
- Dialect/Bufferization/Transforms/one-shot-bufferize-pass-statistics.mlir
- Dialect/LLVMIR/sroa-statistics.mlir
- Dialect/Linalg/vectorize-tensor-extract.mlir
- Dialect/MemRef/mem2reg-statistics.mlir
- Dialect/Tensor/fold-tensor-subset-ops.mlir
- Dialect/Tensor/tracking-listener.mlir
- Pass/pipeline-stats-nested.mlir
- Pass/pipeline-stats.mlir
- )
- ;;
- esac
-
- # respect TMPDIR!
- local -x LIT_PRESERVES_TMP=1
- local -x LIT_XFAIL="${known_xfail[*]}"
- LIT_XFAIL=${LIT_XFAIL// /;}
- cmake_build check-mlir
-}
-
-multilib_src_install() {
- DESTDIR=${D} cmake_build install-distribution
-}
diff --git a/llvm-core/mlir/mlir-23.1.0_rc3.ebuild b/llvm-core/mlir/mlir-23.1.0_rc3.ebuild
deleted file mode 100644
index b93f132d90ae..000000000000
--- a/llvm-core/mlir/mlir-23.1.0_rc3.ebuild
+++ /dev/null
@@ -1,232 +0,0 @@
-# Copyright 1999-2026 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-PYTHON_COMPAT=( python3_{13..14} )
-inherit cmake llvm.org multilib-minimal python-any-r1
-
-DESCRIPTION="Multi-Level Intermediate Representation (library only)"
-HOMEPAGE="https://mlir.llvm.org/"
-
-LICENSE="Apache-2.0-with-LLVM-exceptions"
-SLOT="${LLVM_MAJOR}/${LLVM_SOABI}"
-IUSE="+debug test"
-RESTRICT="!test? ( test )"
-
-DEPEND="
- ~llvm-core/llvm-${PV}[debug=,${MULTILIB_USEDEP}]
-"
-RDEPEND="
- ${DEPEND}
-"
-BDEPEND="
- ${PYTHON_DEPS}
- llvm-core/llvm:${LLVM_MAJOR}
- test? (
- $(python_gen_any_dep 'dev-python/lit[${PYTHON_USEDEP}]')
- )
-"
-
-LLVM_COMPONENTS=( mlir cmake )
-# tablegen tests use *.td files there
-LLVM_TEST_COMPONENTS=( llvm/include )
-llvm.org_set_globals
-
-python_check_deps() {
- if use test; then
- python_has_version "dev-python/lit[${PYTHON_USEDEP}]"
- fi
-}
-
-src_prepare() {
- llvm.org_src_prepare
-
- # https://github.com/llvm/llvm-project/issues/120902
- sed -i -e '/LINK_LIBS/s:PUBLIC:PRIVATE:' \
- lib/ExecutionEngine/CMakeLists.txt || die
-
- # this test is completely unpredictable, no clue why
- rm test/mlir-pdll-lsp-server/view-output.test || die
-}
-
-check_distribution_components() {
- if [[ ${CMAKE_MAKEFILE_GENERATOR} == ninja ]]; then
- local all_targets=() my_targets=() l
- cd "${BUILD_DIR}" || die
-
- while read -r l; do
- if [[ ${l} == install-*-stripped:* ]]; then
- l=${l#install-}
- l=${l%%-stripped*}
-
- case ${l} in
- # meta-targets
- mlir-libraries|distribution)
- continue
- ;;
- # dylib
- MLIR)
- ;;
- # installed test libraries
- MLIRTestAnalysis|MLIRTestDialect|MLIRTestIR)
- ;;
- MLIROpenACCTestPasses)
- ;;
- # static libraries
- MLIR*)
- continue
- ;;
- esac
-
- all_targets+=( "${l}" )
- fi
- done < <(${NINJA} -t targets all)
-
- while read -r l; do
- my_targets+=( "${l}" )
- done < <(get_distribution_components $"\n")
-
- local add=() remove=()
- for l in "${all_targets[@]}"; do
- if ! has "${l}" "${my_targets[@]}"; then
- add+=( "${l}" )
- fi
- done
- for l in "${my_targets[@]}"; do
- if ! has "${l}" "${all_targets[@]}"; then
- remove+=( "${l}" )
- fi
- done
-
- if [[ ${#add[@]} -gt 0 || ${#remove[@]} -gt 0 ]]; then
- eqawarn "get_distribution_components() is outdated!"
- eqawarn " Add: ${add[*]}"
- eqawarn "Remove: ${remove[*]}"
- fi
- cd - >/dev/null || die
- fi
-}
-
-get_distribution_components() {
- local sep=${1-;}
-
- local out=(
- mlir-cmake-exports
- mlir-headers
-
- # the dylib
- MLIR
-
- # shared libraries
- mlir_apfloat_wrappers
- mlir_arm_runner_utils
- mlir_arm_sme_abi_stubs
- mlir_async_runtime
- mlir_c_runner_utils
- mlir_float16_utils
- mlir_runner_utils
-
- # test libraries required by flang
- MLIROpenACCTestPasses
- MLIRTestAnalysis
- MLIRTestDialect
- MLIRTestIR
- )
-
- if multilib_is_native_abi; then
- out+=(
- # tools
- mlir-linalg-ods-yaml-gen
- mlir-lsp-server
- mlir-opt
- mlir-pdll
- mlir-pdll-lsp-server
- mlir-query
- mlir-reduce
- mlir-rewrite
- mlir-runner
- mlir-tblgen
- mlir-translate
- tblgen-lsp-server
- tblgen-to-irdl
- )
- fi
-
- printf "%s${sep}" "${out[@]}"
-}
-
-multilib_src_configure() {
- local mycmakeargs=(
- -DCMAKE_INSTALL_PREFIX="${EPREFIX}/usr/lib/llvm/${LLVM_MAJOR}"
- -DLLVM_ROOT="${ESYSROOT}/usr/lib/llvm/${LLVM_MAJOR}"
-
- -DBUILD_SHARED_LIBS=OFF
- # this controls building libMLIR.so
- -DLLVM_BUILD_LLVM_DYLIB=ON
- -DMLIR_BUILD_MLIR_C_DYLIB=OFF
- -DMLIR_LINK_MLIR_DYLIB=ON
- -DMLIR_INCLUDE_TESTS=ON
- -DMLIR_INCLUDE_INTEGRATION_TESTS=OFF
- -DLLVM_DISTRIBUTION_COMPONENTS=$(get_distribution_components)
- # this enables installing mlir-tblgen and mlir-pdll
- -DLLVM_BUILD_UTILS=ON
-
- -DPython3_EXECUTABLE="${PYTHON}"
-
- -DLLVM_BUILD_TOOLS=ON
- # TODO
- -DMLIR_ENABLE_CUDA_RUNNER=0
- -DMLIR_ENABLE_ROCM_RUNNER=0
- -DMLIR_ENABLE_SYCL_RUNNER=0
- -DMLIR_ENABLE_SPIRV_CPU_RUNNER=0
- -DMLIR_ENABLE_VULKAN_RUNNER=0
- -DMLIR_ENABLE_BINDINGS_PYTHON=0
- -DMLIR_INSTALL_AGGREGATE_OBJECTS=OFF
- )
- use test && mycmakeargs+=(
- -DLLVM_EXTERNAL_LIT="${EPREFIX}/usr/bin/lit"
- -DLLVM_LIT_ARGS="$(get_lit_flags)"
- )
-
- # LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844
- use debug || local -x CPPFLAGS="${CPPFLAGS} -DNDEBUG"
- cmake_src_configure
-
- multilib_is_native_abi && check_distribution_components
-}
-
-multilib_src_compile() {
- cmake_build distribution
-}
-
-multilib_src_test() {
- local known_xfail=()
-
- case ${ABI} in
- arm|ppc|x86)
- known_xfail+=(
- # MLIR is full of 64-bit assumptions, sigh
- # https://github.com/llvm/llvm-project/issues/124541
- Dialect/Bufferization/Transforms/one-shot-bufferize-pass-statistics.mlir
- Dialect/LLVMIR/sroa-statistics.mlir
- Dialect/Linalg/vectorize-tensor-extract.mlir
- Dialect/MemRef/mem2reg-statistics.mlir
- Dialect/Tensor/fold-tensor-subset-ops.mlir
- Dialect/Tensor/tracking-listener.mlir
- Pass/pipeline-stats-nested.mlir
- Pass/pipeline-stats.mlir
- )
- ;;
- esac
-
- # respect TMPDIR!
- local -x LIT_PRESERVES_TMP=1
- local -x LIT_XFAIL="${known_xfail[*]}"
- LIT_XFAIL=${LIT_XFAIL// /;}
- cmake_build check-mlir
-}
-
-multilib_src_install() {
- DESTDIR=${D} cmake_build install-distribution
-}