| 1 | #!/bin/sh |
| 2 | |
| 3 | # This dirty script eat td files :P |
| 4 | # https://github.com/tensorflow/tensorflow/tree/master/tensorflow/compiler/mlir/tensorflow/ir |
| 5 | |
| 6 | sed -i 's!tensorflow/compiler/mlir/tensorflow/ir/!!g' *.td tf_traits.h tf_types.h tf_types.cc tf_attributes.cc |
| 7 | |
| 8 | sed -i '/let hasCanonicalizer = 1;/d' *.td |
| 9 | sed -i '/let hasFolder = 1;/d' *.td |
| 10 | sed -i '/StringRef GetOptimalLayout(const RuntimeDevices& devices);/d' *.td |
| 11 | sed -i '/LogicalResult UpdateDataFormat(StringRef data_format);/d' *.td |
| 12 | sed -i '/LogicalResult FoldOperandsPermutation(ArrayRef<int64_t> permutation);/d' *.td |
| 13 | sed -i '/Optional<ContractionFusion> GetContractionFusion();/d' *.td |