How To Install mlir on Fedora 34

mlir is Multi-Level Intermediate Representation Overview Multi-Level Intermediate Representation Overview

Introduction

In this tutorial we learn how to install mlir on Fedora 34.

What is mlir

The MLIR project is a novel approach to building reusable and extensible compiler infrastructure. MLIR aims to address software fragmentation, improve compilation for heterogeneous hardware, significantly reduce the cost of building domain specific compilers, and aid in connecting existing compilers together. mlir 12.0.0 1.fc34 x86_64 1.7 M mlir-12.0.0-1.fc34.src.rpm updates Multi-Level Intermediate Representation Overview http ASL 2.0 with exceptions The MLIR project is a novel approach to building reusable and extensible compiler infrastructure. MLIR aims to address software fragmentation, improve compilation for heterogeneous hardware, significantly reduce the cost of building domain specific compilers, and aid in connecting existing compilers together.

We can use yum or dnf to install mlir on Fedora 34. In this tutorial we discuss both methods but you only need to choose one of method to install mlir.

Install mlir on Fedora 34 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

The output should look something like this:

Fedora 34 - x86_64                               20 kB/s | 6.6 kB     00:00
Fedora 34 openh264 (From Cisco) - x86_64        1.4 kB/s | 989  B     00:00
Fedora Modular 34 - x86_64                       68 kB/s | 6.5 kB     00:00
Fedora 34 - x86_64 - Updates                    3.5 kB/s | 6.2 kB     00:01
Fedora Modular 34 - x86_64 - Updates             17 kB/s | 5.9 kB     00:00
Metadata cache created.

After updating yum database, We can install mlir using dnf by running the following command:

sudo dnf -y install mlir

Install mlir on Fedora 34 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

The output should look something like this:

Fedora 34 - x86_64                               20 kB/s | 6.6 kB     00:00
Fedora 34 openh264 (From Cisco) - x86_64        1.4 kB/s | 989  B     00:00
Fedora Modular 34 - x86_64                       68 kB/s | 6.5 kB     00:00
Fedora 34 - x86_64 - Updates                    3.5 kB/s | 6.2 kB     00:01
Fedora Modular 34 - x86_64 - Updates             17 kB/s | 5.9 kB     00:00
Metadata cache created.

After updating yum database, We can install mlir using yum by running the following command:

sudo yum -y install mlir

How To Uninstall mlir on Fedora 34

To uninstall only the mlir package we can use the following command:

sudo dnf remove mlir

mlir Package Contents on Fedora 34

/usr/lib/.build-id
/usr/lib/.build-id/13
/usr/lib/.build-id/13/d1cae8e8984ca7fe653b18b91731dd251167e3
/usr/lib/.build-id/24
/usr/lib/.build-id/24/d77a260ad52d965753ae0eabbd97d25f748257
/usr/lib/.build-id/c6
/usr/lib/.build-id/c6/d0fde06e3a79b698c05fc4a66d8c18929b0620
/usr/lib/.build-id/f8
/usr/lib/.build-id/f8/7d1c8589c94c42a5c0cb7958b09968161b799e
/usr/lib64/libMLIRPublicAPI.so.12
/usr/lib64/libmlir_async_runtime.so.12
/usr/lib64/libmlir_c_runner_utils.so.12
/usr/lib64/libmlir_runner_utils.so.12
/usr/share/licenses/mlir
/usr/share/licenses/mlir/LICENSE.TXT
/usr/lib/.build-id
/usr/lib/.build-id/15
/usr/lib/.build-id/15/d32591ee729819cd3400141f5e614d0318d366
/usr/lib/.build-id/60
/usr/lib/.build-id/60/ba8f8d556c14eeedc80d22129c4df37ab623b5
/usr/lib/.build-id/86
/usr/lib/.build-id/86/5ab7beddb459b391af98a872322bec7f941af5
/usr/lib/.build-id/d3
/usr/lib/.build-id/d3/58be49cd0f31af2503d29161450c925ee4b1a4
/usr/lib64/libMLIRPublicAPI.so.12
/usr/lib64/libmlir_async_runtime.so.12
/usr/lib64/libmlir_c_runner_utils.so.12
/usr/lib64/libmlir_runner_utils.so.12
/usr/share/licenses/mlir
/usr/share/licenses/mlir/LICENSE.TXT
/usr/lib/.build-id
/usr/lib/.build-id/27
/usr/lib/.build-id/27/08f61904495d80b4102171ad8f6bf9f1d2cbff
/usr/lib/.build-id/86
/usr/lib/.build-id/86/0bbf090217f5b2c8273c0bba27d2e5b49d0447
/usr/lib/.build-id/a9
/usr/lib/.build-id/a9/c7fe73cb738b2f277caad0c74f572816693a9c
/usr/lib/.build-id/bb
/usr/lib/.build-id/bb/8461274c5ffb7ba18406265513e8587b59dbea
/usr/lib/libMLIRPublicAPI.so.12
/usr/lib/libmlir_async_runtime.so.12
/usr/lib/libmlir_c_runner_utils.so.12
/usr/lib/libmlir_runner_utils.so.12
/usr/share/licenses/mlir
/usr/share/licenses/mlir/LICENSE.TXT
/usr/lib/.build-id
/usr/lib/.build-id/30
/usr/lib/.build-id/30/e9ff8df2703a03f16bf6c2c7f2506779eaa05d
/usr/lib/.build-id/4a
/usr/lib/.build-id/4a/c9fbf319679281856c4895aa871cd326e35cde
/usr/lib/.build-id/77
/usr/lib/.build-id/77/13502e5ca7b4b3ff5f79fc41502ceaa2b40517
/usr/lib/.build-id/b8
/usr/lib/.build-id/b8/fb02abb9a1c9cb7a157c4386ae542fba55e1cf
/usr/lib/libMLIRPublicAPI.so.12
/usr/lib/libmlir_async_runtime.so.12
/usr/lib/libmlir_c_runner_utils.so.12
/usr/lib/libmlir_runner_utils.so.12
/usr/share/licenses/mlir
/usr/share/licenses/mlir/LICENSE.TXT

References

Summary

In this tutorial we learn how to install mlir on Fedora 34 using yum and dnf.