Skip to content

[mlir] Remove bytecode reader & writer header from interface. #98920

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
Jul 15, 2024

Conversation

jpienaar
Copy link
Member

Flagged some additional headers missing in process.

Inspired by #98676

Flagged some additional headers missing in process.

Inspired by llvm#98676
@llvmbot
Copy link
Member

llvmbot commented Jul 15, 2024

@llvm/pr-subscribers-mlir-core
@llvm/pr-subscribers-mlir

@llvm/pr-subscribers-mlir-openmp

Author: Jacques Pienaar (jpienaar)

Changes

Flagged some additional headers missing in process.

Inspired by #98676


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

5 Files Affected:

  • (modified) mlir/include/mlir/Bytecode/BytecodeOpInterface.h (-2)
  • (modified) mlir/include/mlir/Bytecode/BytecodeReaderConfig.h (+2-2)
  • (modified) mlir/lib/Bytecode/Writer/IRNumbering.cpp (+1)
  • (modified) mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp (+1)
  • (modified) mlir/lib/Target/LLVMIR/DebugImporter.h (+1)
diff --git a/mlir/include/mlir/Bytecode/BytecodeOpInterface.h b/mlir/include/mlir/Bytecode/BytecodeOpInterface.h
index c9c60608fa5b9..98f1fee7f9d3a 100644
--- a/mlir/include/mlir/Bytecode/BytecodeOpInterface.h
+++ b/mlir/include/mlir/Bytecode/BytecodeOpInterface.h
@@ -15,8 +15,6 @@
 #define MLIR_BYTECODE_BYTECODEOPINTERFACE_H
 
 #include "mlir/Bytecode/BytecodeImplementation.h"
-#include "mlir/Bytecode/BytecodeReader.h"
-#include "mlir/Bytecode/BytecodeWriter.h"
 #include "mlir/IR/OpDefinition.h"
 
 /// Include the generated interface declarations.
diff --git a/mlir/include/mlir/Bytecode/BytecodeReaderConfig.h b/mlir/include/mlir/Bytecode/BytecodeReaderConfig.h
index 47be732fa3880..c473b5779130f 100644
--- a/mlir/include/mlir/Bytecode/BytecodeReaderConfig.h
+++ b/mlir/include/mlir/Bytecode/BytecodeReaderConfig.h
@@ -1,4 +1,4 @@
-//===- BytecodeReader.h - MLIR Bytecode Reader ------------------*- C++ -*-===//
+//===- BytecodeReaderConfig.h - MLIR Bytecode Reader Config -----*- C++ -*-===//
 //
 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
 // See https://llvm.org/LICENSE.txt for license information.
@@ -6,7 +6,7 @@
 //
 //===----------------------------------------------------------------------===//
 //
-// This header defines interfaces to read MLIR bytecode files/streams.
+// This header config for reading MLIR bytecode files/streams.
 //
 //===----------------------------------------------------------------------===//
 
diff --git a/mlir/lib/Bytecode/Writer/IRNumbering.cpp b/mlir/lib/Bytecode/Writer/IRNumbering.cpp
index d2144dd7f3348..1bc02e1721573 100644
--- a/mlir/lib/Bytecode/Writer/IRNumbering.cpp
+++ b/mlir/lib/Bytecode/Writer/IRNumbering.cpp
@@ -9,6 +9,7 @@
 #include "IRNumbering.h"
 #include "mlir/Bytecode/BytecodeImplementation.h"
 #include "mlir/Bytecode/BytecodeOpInterface.h"
+#include "mlir/Bytecode/BytecodeWriter.h"
 #include "mlir/Bytecode/Encoding.h"
 #include "mlir/IR/AsmState.h"
 #include "mlir/IR/BuiltinTypes.h"
diff --git a/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp b/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp
index a7a0af231af33..f5ec5a476ad8f 100644
--- a/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp
+++ b/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp
@@ -33,6 +33,7 @@
 #include <cstddef>
 #include <iterator>
 #include <optional>
+#include <variant>
 
 #include "mlir/Dialect/OpenMP/OpenMPOpsDialect.cpp.inc"
 #include "mlir/Dialect/OpenMP/OpenMPOpsEnums.cpp.inc"
diff --git a/mlir/lib/Target/LLVMIR/DebugImporter.h b/mlir/lib/Target/LLVMIR/DebugImporter.h
index 4a2bf35c160e1..0e040891ba6c0 100644
--- a/mlir/lib/Target/LLVMIR/DebugImporter.h
+++ b/mlir/lib/Target/LLVMIR/DebugImporter.h
@@ -18,6 +18,7 @@
 #include "mlir/IR/BuiltinOps.h"
 #include "mlir/IR/MLIRContext.h"
 #include "mlir/Support/CyclicReplacerCache.h"
+#include "llvm/ADT/MapVector.h"
 #include "llvm/IR/DebugInfoMetadata.h"
 
 namespace mlir {

@llvmbot
Copy link
Member

llvmbot commented Jul 15, 2024

@llvm/pr-subscribers-flang-openmp

Author: Jacques Pienaar (jpienaar)

Changes

Flagged some additional headers missing in process.

Inspired by #98676


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

5 Files Affected:

  • (modified) mlir/include/mlir/Bytecode/BytecodeOpInterface.h (-2)
  • (modified) mlir/include/mlir/Bytecode/BytecodeReaderConfig.h (+2-2)
  • (modified) mlir/lib/Bytecode/Writer/IRNumbering.cpp (+1)
  • (modified) mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp (+1)
  • (modified) mlir/lib/Target/LLVMIR/DebugImporter.h (+1)
diff --git a/mlir/include/mlir/Bytecode/BytecodeOpInterface.h b/mlir/include/mlir/Bytecode/BytecodeOpInterface.h
index c9c60608fa5b9..98f1fee7f9d3a 100644
--- a/mlir/include/mlir/Bytecode/BytecodeOpInterface.h
+++ b/mlir/include/mlir/Bytecode/BytecodeOpInterface.h
@@ -15,8 +15,6 @@
 #define MLIR_BYTECODE_BYTECODEOPINTERFACE_H
 
 #include "mlir/Bytecode/BytecodeImplementation.h"
-#include "mlir/Bytecode/BytecodeReader.h"
-#include "mlir/Bytecode/BytecodeWriter.h"
 #include "mlir/IR/OpDefinition.h"
 
 /// Include the generated interface declarations.
diff --git a/mlir/include/mlir/Bytecode/BytecodeReaderConfig.h b/mlir/include/mlir/Bytecode/BytecodeReaderConfig.h
index 47be732fa3880..c473b5779130f 100644
--- a/mlir/include/mlir/Bytecode/BytecodeReaderConfig.h
+++ b/mlir/include/mlir/Bytecode/BytecodeReaderConfig.h
@@ -1,4 +1,4 @@
-//===- BytecodeReader.h - MLIR Bytecode Reader ------------------*- C++ -*-===//
+//===- BytecodeReaderConfig.h - MLIR Bytecode Reader Config -----*- C++ -*-===//
 //
 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
 // See https://llvm.org/LICENSE.txt for license information.
@@ -6,7 +6,7 @@
 //
 //===----------------------------------------------------------------------===//
 //
-// This header defines interfaces to read MLIR bytecode files/streams.
+// This header config for reading MLIR bytecode files/streams.
 //
 //===----------------------------------------------------------------------===//
 
diff --git a/mlir/lib/Bytecode/Writer/IRNumbering.cpp b/mlir/lib/Bytecode/Writer/IRNumbering.cpp
index d2144dd7f3348..1bc02e1721573 100644
--- a/mlir/lib/Bytecode/Writer/IRNumbering.cpp
+++ b/mlir/lib/Bytecode/Writer/IRNumbering.cpp
@@ -9,6 +9,7 @@
 #include "IRNumbering.h"
 #include "mlir/Bytecode/BytecodeImplementation.h"
 #include "mlir/Bytecode/BytecodeOpInterface.h"
+#include "mlir/Bytecode/BytecodeWriter.h"
 #include "mlir/Bytecode/Encoding.h"
 #include "mlir/IR/AsmState.h"
 #include "mlir/IR/BuiltinTypes.h"
diff --git a/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp b/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp
index a7a0af231af33..f5ec5a476ad8f 100644
--- a/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp
+++ b/mlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp
@@ -33,6 +33,7 @@
 #include <cstddef>
 #include <iterator>
 #include <optional>
+#include <variant>
 
 #include "mlir/Dialect/OpenMP/OpenMPOpsDialect.cpp.inc"
 #include "mlir/Dialect/OpenMP/OpenMPOpsEnums.cpp.inc"
diff --git a/mlir/lib/Target/LLVMIR/DebugImporter.h b/mlir/lib/Target/LLVMIR/DebugImporter.h
index 4a2bf35c160e1..0e040891ba6c0 100644
--- a/mlir/lib/Target/LLVMIR/DebugImporter.h
+++ b/mlir/lib/Target/LLVMIR/DebugImporter.h
@@ -18,6 +18,7 @@
 #include "mlir/IR/BuiltinOps.h"
 #include "mlir/IR/MLIRContext.h"
 #include "mlir/Support/CyclicReplacerCache.h"
+#include "llvm/ADT/MapVector.h"
 #include "llvm/IR/DebugInfoMetadata.h"
 
 namespace mlir {

@jpienaar jpienaar merged commit f1ac772 into llvm:main Jul 15, 2024
13 checks passed
yuxuanchen1997 pushed a commit that referenced this pull request Jul 25, 2024
Flagged some additional headers missing in process.

Inspired by #98676
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.

2 participants