Skip to content

Conversation

@RoboTux
Copy link
Contributor

@RoboTux RoboTux commented Jul 3, 2025

Fix the following compile error when building libMLIRDialectUtils.a
only:

In file included from mlir/include/mlir/Dialect/Utils/ReshapeOpsUtils.h:17,
from mlir/lib/Dialect/Utils/ReshapeOpsUtils.cpp:9:
mlir/include/mlir/Dialect/Arith/IR/Arith.h:28:10:
fatal error: mlir/Dialect/Arith/IR/ArithOpsDialect.h.inc: No such file or directory

ArithDialect dependency is now needed since
0515449 to create arith.muli op.

Fix the following compile error when building libMLIRDialectUtils.a
only:

In file included from mlir/include/mlir/Dialect/Utils/ReshapeOpsUtils.h:17,
                 from mlir/lib/Dialect/Utils/ReshapeOpsUtils.cpp:9:
mlir/include/mlir/Dialect/Arith/IR/Arith.h:28:10:
fatal error: mlir/Dialect/Arith/IR/ArithOpsDialect.h.inc: No such file or directory
@llvmbot llvmbot added the mlir label Jul 3, 2025
@llvmbot
Copy link
Member

llvmbot commented Jul 3, 2025

@llvm/pr-subscribers-mlir

Author: Thomas Preud'homme (RoboTux)

Changes

Fix the following compile error when building libMLIRDialectUtils.a
only:

In file included from mlir/include/mlir/Dialect/Utils/ReshapeOpsUtils.h:17,
from mlir/lib/Dialect/Utils/ReshapeOpsUtils.cpp:9:
mlir/include/mlir/Dialect/Arith/IR/Arith.h:28:10:
fatal error: mlir/Dialect/Arith/IR/ArithOpsDialect.h.inc: No such file or directory


Full diff: https://github.com/llvm/llvm-project/pull/146834.diff

1 Files Affected:

  • (modified) mlir/lib/Dialect/Utils/CMakeLists.txt (+1)
diff --git a/mlir/lib/Dialect/Utils/CMakeLists.txt b/mlir/lib/Dialect/Utils/CMakeLists.txt
index a0096e5f299d5..f5bb687ae071a 100644
--- a/mlir/lib/Dialect/Utils/CMakeLists.txt
+++ b/mlir/lib/Dialect/Utils/CMakeLists.txt
@@ -6,6 +6,7 @@ add_mlir_library(MLIRDialectUtils
 
   DEPENDS
   MLIRDialectUtilsIncGen
+  MLIRArithDialect
 
   LINK_LIBS PUBLIC
   MLIRIR

@RoboTux RoboTux requested review from hanhanW and qedawkins July 3, 2025 09:12
@RoboTux RoboTux merged commit 7763002 into llvm:main Jul 3, 2025
10 of 11 checks passed
@RoboTux RoboTux deleted the fix_utils_dep branch July 3, 2025 12:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants