Skip to content

[mlir] add missing include to MemRefTransformOps.h #92361

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 24, 2024
Merged

Conversation

ftynse
Copy link
Member

@ftynse ftynse commented May 16, 2024

The ODS-generated code has the following:

::mlir::TypedValue<::mlir::transform::OperationType> getAlloca() {
  return ::llvm::cast<::mlir::TypedValue<::mlir::transform::OperationType>>(
      *getODSOperands(0).begin());
}

that may require the compiler seing the definition of OperationType so include the corresponding header.

The ODS-generated code has the following:

```
::mlir::TypedValue<::mlir::transform::OperationType> getAlloca() {
  return ::llvm::cast<::mlir::TypedValue<::mlir::transform::OperationType>>(
      *getODSOperands(0).begin());
}
```

that may require the compiler seing the definition of `OperationType` so
include the corresponding header.
@llvmbot
Copy link
Member

llvmbot commented May 16, 2024

@llvm/pr-subscribers-mlir

@llvm/pr-subscribers-mlir-memref

Author: Oleksandr "Alex" Zinenko (ftynse)

Changes

The ODS-generated code has the following:

::mlir::TypedValue&lt;::mlir::transform::OperationType&gt; getAlloca() {
  return ::llvm::cast&lt;::mlir::TypedValue&lt;::mlir::transform::OperationType&gt;&gt;(
      *getODSOperands(0).begin());
}

that may require the compiler seing the definition of OperationType so include the corresponding header.


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

1 Files Affected:

  • (modified) mlir/include/mlir/Dialect/MemRef/TransformOps/MemRefTransformOps.h (+1)
diff --git a/mlir/include/mlir/Dialect/MemRef/TransformOps/MemRefTransformOps.h b/mlir/include/mlir/Dialect/MemRef/TransformOps/MemRefTransformOps.h
index a87767acdd3b8..5ef901ade91d1 100644
--- a/mlir/include/mlir/Dialect/MemRef/TransformOps/MemRefTransformOps.h
+++ b/mlir/include/mlir/Dialect/MemRef/TransformOps/MemRefTransformOps.h
@@ -10,6 +10,7 @@
 #define MLIR_DIALECT_MEMREF_TRANSFORMOPS_MEMREFTRANSFORMOPS_H
 
 #include "mlir/Bytecode/BytecodeOpInterface.h"
+#include "mlir/Dialect/Transform/IR/TransformTypes.h"
 #include "mlir/Dialect/Transform/Interfaces/TransformInterfaces.h"
 #include "mlir/IR/OpImplementation.h"
 

Copy link
Collaborator

@qcolombet qcolombet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@ftynse ftynse merged commit e3ed9e3 into llvm:main May 24, 2024
7 checks passed
@ftynse ftynse deleted the split branch May 24, 2024 07:33
qiaojbao pushed a commit to GPUOpen-Drivers/llvm-project that referenced this pull request Jun 26, 2024
…02b412774

Local branch amd-gfx 15202b4 Revert blending-shuffle tests
Remote branch main e3ed9e3 [mlir] add missing include to MemRefTransformOps.h (llvm#92361)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants