Projects
Factory:RISC-V:ROCm
rocMLIR
_service:tar_scm:rocmlir.spec
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:tar_scm:rocmlir.spec of Package rocMLIR
%global upstreamname rocMLIR %define debug_package %{nil} %global rocm_release 6.3 %global rocm_patch 0 %global rocm_version %{rocm_release}.%{rocm_patch} %global toolchain rocm # hipcc does not support some clang flags %global build_cxxflags %(echo %{optflags} | sed -e 's/-fstack-protector-strong/-Xarch_host -fstack-protector-strong/' -e 's/-fcf-protection/-Xarch_host -fcf-protection/') # $gpu will be evaluated in the loops below %global _vpath_builddir %{_vendor}-%{_target_os}-build-${gpu} %bcond_with debug %if %{with debug} %global build_type DEBUG %else %global build_type RelWithDebInfo %endif # It is necessary to use this with a local build # export QA_RPATHS=0xff %bcond_with test %if %{with test} %global build_test ON %else %global build_test OFF %endif # Option to test suite for testing on real HW: %bcond_with check Name: rocmlir Version: %{rocm_version} Release: 1 Summary: rocMLIR is for a MLIR-based convolution and GEMM kernel generator targetting AMD hardware. Url: https://github.com/ROCm/rocMLIR License: MIT and BSD Source0: %{url}/archive/rocm-%{version}.tar.gz#/%{upstreamname}-%{version}.tar.gz Patch0: 0001-Fix-build-on-riscv64.patch BuildRequires: git BuildRequires: cmake BuildRequires: rocm-cmake BuildRequires: rocm-comgr-devel BuildRequires: rocm-compilersupport-macros BuildRequires: rocm-hip-devel BuildRequires: rocm-runtime-devel BuildRequires: rocm-rpm-macros BuildRequires: rocm-rpm-macros-modules BuildRequires: rocblas-devel BuildRequires: ninja-build Requires: rocm-rpm-macros-modules # Only x86_64 works right now: ExclusiveArch: x86_64 riscv64 %description rocMLIR is for a MLIR-based convolution and GEMM kernel generator targetting AMD hardware. This generator is mainly used from MIGraphX, but it can be used on a standalone basis. (The ability to use this code via torch-mlir is being investigated as well.) %package devel Summary: The rocRAND development package Requires: %{name}%{?_isa} = %{version}-%{release} %description devel The rocRAND development package. %if %{with test} %package test Summary: Tests for %{name} Requires: %{name}%{?_isa} = %{version}-%{release} %description test %{summary} %endif %prep %autosetup -p1 -n %{upstreamname}-rocm-%{version} %build for gpu in %{rocm_gpu_list} do module load rocm/$gpu mkdir %{_target_platform}-$gpu pushd %{_target_platform}-$gpu # We can't compile all the targets at once export ROCM_GPUS='gfx1030;gfx1100' %cmake -G Ninja .. \ -DCMAKE_BUILD_TYPE=%build_type \ -DAMDGPU_TARGETS=${ROCM_GPUS} \ -DCMAKE_INSTALL_LIBDIR=$ROCM_LIB \ -DCMAKE_INSTALL_BINDIR=$ROCM_BIN \ -DCMAKE_C_FLAGS="-Wno-gnu-line-marker" \ -DBUILD_FAT_LIBROCKCOMPILER=ON \ -DCMAKE_CXX_FLAGS="-Wno-gnu-line-marker -Wno-narrowing" \ -DBUILD_SHARED_LIBS:BOOL=OFF \ -DBUILD_TEST=%build_test popd ninja -C %{_target_platform}-$gpu %{?_smp_mflags} -v module purge done %install for gpu in %{rocm_gpu_list} do DESTDIR=%{buildroot} ninja -C %{_target_platform}-$gpu install done echo s@%{buildroot}@@ > br.sed find %{buildroot}/usr/lib -name '*.a' | sed -f br.sed > %{name}.files find %{buildroot}/usr/lib -name '*.o' | sed -f br.sed >> %{name}.files find %{buildroot}%{_libdir} -name '*.cmake' | sed -f br.sed > %{name}.devel %if %{with test} find %{buildroot} -name 'test_*' | sed -f br.sed > %{name}.test find %{buildroot} -name '*RAND' | sed -f br.sed >> %{name}.test %endif %check %if %{with test} %if %{with check} # Assumes default %ctest %endif %endif %files -f %{name}.files %license %{_docdir}/%{name}/LICENSE %files devel -f %{name}.devel %{_includedir}/%{name} %if %{with test} %files test -f %{name}.test %endif %changelog * Mon Dec 23 2024 misaka00251 <liuxin@iscas.ac.cn> - 6.3.0-1 - Update to 6.3.0 * Mon Dec 16 2024 QiuWenjian <wenjian.oerv@isrc.iscas.ac.cn> - 6.2.4-1 - Upgraded to 6.2.4 * Thu Dec 11 2024 QiuWenjian <wenjian.oerv@isrc.iscas.ac.cn> - 6.2.2-2 - Fix compile error * Tue Nov 26 2024 misaka00251 <liuxin@iscas.ac.cn> - 6.2.2-1 - Init package
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.
浙ICP备2022010568号-2