Skip to content

[mlir] Align mlir::Block #106717

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
Aug 30, 2024
Merged

[mlir] Align mlir::Block #106717

merged 1 commit into from
Aug 30, 2024

Conversation

JoelWee
Copy link
Contributor

@JoelWee JoelWee commented Aug 30, 2024

This fixes an error from the LatticeAnchor PointerUnion with ProgramPoint in b6603e1

third_party/llvm/llvm-project/llvm/include/llvm/ADT/PointerIntPair.h:172:17: error: static assertion failed due to requirement '2U <= PointerUnionUIntTraits<mlir::GenericLatticeAnchor *, mlir::ProgramPoint, mlir::Value>::NumLowBitsAvailable': PointerIntPair with integer size too large for pointer
  172 |   static_assert(IntBits <= PtrTraits::NumLowBitsAvailable,

This fixes the error from the LatticeAnchor PointerUnion with ProgramPoint
third_party/llvm/llvm-project/llvm/include/llvm/ADT/PointerIntPair.h:172:17: error: static assertion failed due to requirement '2U <= PointerUnionUIntTraits<mlir::GenericLatticeAnchor *, mlir::ProgramPoint, mlir::Value>::NumLowBitsAvailable': PointerIntPair with integer size too large for pointer
  172 |   static_assert(IntBits <= PtrTraits::NumLowBitsAvailable,
@llvmbot llvmbot added mlir:core MLIR Core Infrastructure mlir labels Aug 30, 2024
@llvmbot
Copy link
Member

llvmbot commented Aug 30, 2024

@llvm/pr-subscribers-mlir-core

@llvm/pr-subscribers-mlir

Author: None (JoelWee)

Changes

This fixes an error from the LatticeAnchor PointerUnion with ProgramPoint in b6603e1

third_party/llvm/llvm-project/llvm/include/llvm/ADT/PointerIntPair.h:172:17: error: static assertion failed due to requirement '2U &lt;= PointerUnionUIntTraits&lt;mlir::GenericLatticeAnchor *, mlir::ProgramPoint, mlir::Value&gt;::NumLowBitsAvailable': PointerIntPair with integer size too large for pointer
  172 |   static_assert(IntBits &lt;= PtrTraits::NumLowBitsAvailable,

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

1 Files Affected:

  • (modified) mlir/include/mlir/IR/Block.h (+2-2)
diff --git a/mlir/include/mlir/IR/Block.h b/mlir/include/mlir/IR/Block.h
index e4fddfcb7608e6..67825eb1704bbe 100644
--- a/mlir/include/mlir/IR/Block.h
+++ b/mlir/include/mlir/IR/Block.h
@@ -27,8 +27,8 @@ template <typename ValueRangeT>
 class ValueTypeRange;
 
 /// `Block` represents an ordered list of `Operation`s.
-class Block : public IRObjectWithUseList<BlockOperand>,
-              public llvm::ilist_node_with_parent<Block, Region> {
+class alignas(8) Block : public IRObjectWithUseList<BlockOperand>,
+                         public llvm::ilist_node_with_parent<Block, Region> {
 public:
   explicit Block() = default;
   ~Block();

@cota cota self-requested a review August 30, 2024 15:56
@JoelWee JoelWee merged commit a2615ad into llvm:main Aug 30, 2024
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mlir:core MLIR Core Infrastructure mlir
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants