From ae1a6619dfdc8d1275ebd573e6a0510094043bc9 Mon Sep 17 00:00:00 2001 From: Jacques Pienaar Date: Thu, 3 Jan 2019 08:23:35 -0800 Subject: [PATCH] Include both TF and TFL ops.td in legalize patterns. Need to do some ifdef jumps with TableGen to avoid errors due to including the base multiple times. The way TableGen flags repeated includes is by way of checking the include directive this necessitates that the guards are on the includes as well as around the classes/defines. PiperOrigin-RevId: 227692030 --- mlir/include/mlir/IR/op_base.td | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/mlir/include/mlir/IR/op_base.td b/mlir/include/mlir/IR/op_base.td index b3a4d992ede3..369888052e3a 100644 --- a/mlir/include/mlir/IR/op_base.td +++ b/mlir/include/mlir/IR/op_base.td @@ -19,6 +19,10 @@ // //===----------------------------------------------------------------------===// +#ifdef OP_BASE +#else +#define OP_BASE + //===----------------------------------------------------------------------===// // Types. //===----------------------------------------------------------------------===// @@ -249,3 +253,4 @@ class Pattern resultOps> { // Form of a pattern which produces a single result. class Pat : Pattern; +#endif // OP_BASE