Skip to content
This repository was archived by the owner on Apr 23, 2021. It is now read-only.

Commit 71da5c2

Browse files
River707tensorflower-gardener
authored andcommitted
NFC: Remove unnecessarily guarded tablegen includes.
Support for including a file multiple times was added in tablegen, removing the need for these extra guards. This is because we already insert c/c++ style header guards within each of the specific .td files. PiperOrigin-RevId: 282076728
1 parent 50ddd71 commit 71da5c2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+12
-163
lines changed

examples/toy/Ch2/include/toy/Ops.td

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,7 @@
2222
#ifndef TOY_OPS
2323
#define TOY_OPS
2424

25-
#ifndef OP_BASE
2625
include "mlir/IR/OpBase.td"
27-
#endif // OP_BASE
2826

2927
// Provide a definition of the 'toy' dialect in the ODS framework so that we
3028
// can define our operations.

examples/toy/Ch3/include/toy/Ops.td

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,7 @@
2222
#ifndef TOY_OPS
2323
#define TOY_OPS
2424

25-
#ifndef OP_BASE
2625
include "mlir/IR/OpBase.td"
27-
#endif // OP_BASE
2826

2927
// Provide a definition of the 'toy' dialect in the ODS framework so that we
3028
// can define our operations.

examples/toy/Ch3/mlir/ToyCombine.td

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,7 @@
2323
#ifndef TOY_COMBINE
2424
#define TOY_COMBINE
2525

26-
#ifndef OP_BASE
2726
include "toy/Ops.td"
28-
#endif // OP_BASE
2927

3028
/// Note: The DRR definition used for defining patterns is shown below:
3129
///

examples/toy/Ch4/include/toy/Ops.td

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,8 @@
2222
#ifndef TOY_OPS
2323
#define TOY_OPS
2424

25-
#ifndef MLIR_CALLINTERFACES
2625
include "mlir/Analysis/CallInterfaces.td"
27-
#endif // MLIR_CALLINTERFACES
28-
29-
#ifndef SHAPE_INFERENCE_INTERFACE
3026
include "toy/ShapeInferenceInterface.td"
31-
#endif // SHAPE_INFERENCE_INTERFACE
3227

3328
// Provide a definition of the 'toy' dialect in the ODS framework so that we
3429
// can define our operations.

examples/toy/Ch4/include/toy/ShapeInferenceInterface.td

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,7 @@
2222
#ifndef SHAPE_INFERENCE_INTERFACE
2323
#define SHAPE_INFERENCE_INTERFACE
2424

25-
#ifndef OP_BASE
2625
include "mlir/IR/OpBase.td"
27-
#endif // OP_BASE
2826

2927
def ShapeInferenceOpInterface : OpInterface<"ShapeInference"> {
3028
let description = [{

examples/toy/Ch4/mlir/ToyCombine.td

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,7 @@
2323
#ifndef TOY_COMBINE
2424
#define TOY_COMBINE
2525

26-
#ifndef OP_BASE
2726
include "toy/Ops.td"
28-
#endif // OP_BASE
2927

3028
/// Note: The DRR definition used for defining patterns is shown below:
3129
///

examples/toy/Ch5/include/toy/Ops.td

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,8 @@
2222
#ifndef TOY_OPS
2323
#define TOY_OPS
2424

25-
#ifndef MLIR_CALLINTERFACES
2625
include "mlir/Analysis/CallInterfaces.td"
27-
#endif // MLIR_CALLINTERFACES
28-
29-
#ifndef SHAPE_INFERENCE_INTERFACE
3026
include "toy/ShapeInferenceInterface.td"
31-
#endif // SHAPE_INFERENCE_INTERFACE
3227

3328
// Provide a definition of the 'toy' dialect in the ODS framework so that we
3429
// can define our operations.

examples/toy/Ch5/include/toy/ShapeInferenceInterface.td

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,7 @@
2222
#ifndef SHAPE_INFERENCE_INTERFACE
2323
#define SHAPE_INFERENCE_INTERFACE
2424

25-
#ifndef OP_BASE
2625
include "mlir/IR/OpBase.td"
27-
#endif // OP_BASE
2826

2927
def ShapeInferenceOpInterface : OpInterface<"ShapeInference"> {
3028
let description = [{

examples/toy/Ch5/mlir/ToyCombine.td

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,7 @@
2323
#ifndef TOY_COMBINE
2424
#define TOY_COMBINE
2525

26-
#ifndef OP_BASE
2726
include "toy/Ops.td"
28-
#endif // OP_BASE
2927

3028
/// Note: The DRR definition used for defining patterns is shown below:
3129
///

examples/toy/Ch6/include/toy/Ops.td

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,8 @@
2222
#ifndef TOY_OPS
2323
#define TOY_OPS
2424

25-
#ifndef MLIR_CALLINTERFACES
2625
include "mlir/Analysis/CallInterfaces.td"
27-
#endif // MLIR_CALLINTERFACES
28-
29-
#ifndef SHAPE_INFERENCE_INTERFACE
3026
include "toy/ShapeInferenceInterface.td"
31-
#endif // SHAPE_INFERENCE_INTERFACE
3227

3328
// Provide a definition of the 'toy' dialect in the ODS framework so that we
3429
// can define our operations.

0 commit comments

Comments
 (0)