[flang-commits] [flang] 2d83014 - Fix flang test after MLIR API changes
Mehdi Amini via flang-commits
flang-commits at lists.llvm.org
Wed Aug 19 10:22:05 PDT 2020
Author: Mehdi Amini
Date: 2020-08-19T17:21:38Z
New Revision: 2d83014c469153b4e79bb85d110b026d9f3c5664
URL: https://github.com/llvm/llvm-project/commit/2d83014c469153b4e79bb85d110b026d9f3c5664
DIFF: https://github.com/llvm/llvm-project/commit/2d83014c469153b4e79bb85d110b026d9f3c5664.diff
LOG: Fix flang test after MLIR API changes
Added:
Modified:
flang/unittests/Lower/OpenMPLoweringTest.cpp
Removed:
################################################################################
diff --git a/flang/unittests/Lower/OpenMPLoweringTest.cpp b/flang/unittests/Lower/OpenMPLoweringTest.cpp
index ad6fe739d16b..dc002cef1a52 100644
--- a/flang/unittests/Lower/OpenMPLoweringTest.cpp
+++ b/flang/unittests/Lower/OpenMPLoweringTest.cpp
@@ -9,14 +9,15 @@
#include "gtest/gtest.h"
#include "mlir/Dialect/OpenMP/OpenMPDialect.h"
#include "mlir/IR/Builders.h"
+#include "mlir/InitAllDialects.h"
#include "flang/Parser/parse-tree.h"
#include "llvm/Frontend/OpenMP/OMPConstants.h"
class OpenMPLoweringTest : public testing::Test {
protected:
void SetUp() override {
- mlir::registerDialect<mlir::omp::OpenMPDialect>();
- mlir::registerAllDialects(&ctx);
+ ctx.loadDialect<mlir::omp::OpenMPDialect>();
+ mlir::registerAllDialects(ctx.getDialectRegistry());
mlirOpBuilder.reset(new mlir::OpBuilder(&ctx));
}
More information about the flang-commits
mailing list