Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions CMakePresets.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,22 @@
"rhs": ""
}
},
{
"name": "default-mlir",
"displayName": "default with MLIR",
"inherits": "default",
"cacheVariables": {
"CXX_ENABLE_MLIR": "YES"
}
},
{
"name": "debug-mlir",
"displayName": "debug with MLIR",
"inherits": "debug",
"cacheVariables": {
"CXX_ENABLE_MLIR": "YES"
}
},
{
"name": "emscripten-mlir",
"displayName": "emscripten with MLIR",
Expand Down
6 changes: 3 additions & 3 deletions src/mlir/cxx/mlir/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ target_compile_definitions(cxx-mlir PUBLIC CXX_WITH_MLIR)
add_dependencies(cxx-mlir MLIRCxxOpsIncGen)

if (CMAKE_CXX_COMPILER_ID MATCHES "Clang|GNU")

target_compile_options(cxx-mlir PRIVATE
-Wno-unused-variable
-Wno-covered-switch-default
-Wno-unused-but-set-variable
$<$<COMPILE_LANGUAGE:CXX>:-Wno-all -Wno-extra -Wno-covered-switch-default>
)

endif()
9 changes: 9 additions & 0 deletions src/mlir/cxx/mlir/cxx_dialect.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,17 @@

#pragma once

#if defined(__clang__) || defined(__GNUC__)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif

#include <mlir/Bytecode/BytecodeOpInterface.h>

#if defined(__clang__) || defined(__GNUC__)
#pragma GCC diagnostic pop
#endif

#include <cxx/mlir/CxxOpsDialect.h.inc>

#define GET_TYPEDEF_CLASSES
Expand Down