Skip to content

Commit 861c3ae

Browse files
committed
conv:hltohlbi: Initalize conversion pass from hl to builtin dialect.
1 parent f7a27df commit 861c3ae

File tree

5 files changed

+408
-0
lines changed

5 files changed

+408
-0
lines changed

include/vast/Conversion/Passes.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,8 @@ namespace vast
5757

5858
std::unique_ptr< mlir::Pass > createHLToLLFuncPass();
5959

60+
std::unique_ptr< mlir::Pass > createHLToHLBI();
61+
6062
// Generate the code for registering passes.
6163
#define GEN_PASS_REGISTRATION
6264
#include "vast/Conversion/Passes.h.inc"

include/vast/Conversion/Passes.td

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,4 +155,16 @@ def HLEmitLazyRegions : Pass<"vast-hl-to-lazy-regions", "mlir::ModuleOp"> {
155155
];
156156
}
157157

158+
def HLToHLBI : Pass<"vast-hl-to-hl-builtin", "mlir::ModuleOp"> {
159+
let summary = "Transform hl operations that have builtin attribute to specialized dialect.";
160+
let description = [{
161+
This pass is still a work in progress.
162+
}];
163+
164+
let constructor = "vast::createHLToHLBI()";
165+
let dependentDialects = [
166+
"vast::hlbi::BuiltinDialect"
167+
];
168+
}
169+
158170
#endif // VAST_CONVERSION_PASSES_TD

lib/vast/Conversion/FromHL/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,5 @@ add_vast_conversion_library(HighLevelConversionPasses
77
ToLLGEPs.cpp
88
ToLLVars.cpp
99
ToLLFunc.cpp
10+
ToHLBI.cpp
1011
)

0 commit comments

Comments
 (0)