Skip to content

Commit da3357e

Browse files
Automated rollback of commit 31c0857
PiperOrigin-RevId: 213764810
1 parent 31c0857 commit da3357e

File tree

5 files changed

+0
-62
lines changed

5 files changed

+0
-62
lines changed

tensorflow/compiler/aot/tests/BUILD

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ test_suite(
2525
":test_graph_tfmatmul_test",
2626
":test_graph_tfmatmulandadd_test",
2727
":test_graph_tfsplits_test",
28-
":test_graph_tftop_k_test",
2928
":tfcompile_test",
3029
],
3130
)
@@ -43,7 +42,6 @@ py_binary(
4342
"//tensorflow/python:control_flow_ops",
4443
"//tensorflow/python:framework_for_generated_wrappers",
4544
"//tensorflow/python:math_ops",
46-
"//tensorflow/python:nn_ops",
4745
"//tensorflow/python:platform",
4846
"//tensorflow/python:session",
4947
"//tensorflow/python:training",
@@ -68,7 +66,6 @@ genrule(
6866
"test_graph_tfmatmul.pb",
6967
"test_graph_tfmatmulandadd.pb",
7068
"test_graph_tfsplits.pb",
71-
"test_graph_tftop_k.pb",
7269
],
7370
# Set CUDA_VISIBLE_DEVICES='' to prevent the code we launch from using any
7471
# GPUs which might be present. This is important because builds may run
@@ -211,17 +208,6 @@ tf_library(
211208
],
212209
)
213210

214-
tf_library(
215-
name = "test_graph_tftop_k",
216-
testonly = 1,
217-
config = "test_graph_tftop_k.config.pbtxt",
218-
cpp_class = "TopKComp",
219-
graph = "test_graph_tftop_k.pb",
220-
tags = [
221-
"manual",
222-
],
223-
)
224-
225211
tf_cc_test(
226212
name = "tfcompile_test",
227213
srcs = ["tfcompile_test.cc"],
@@ -240,7 +226,6 @@ tf_cc_test(
240226
":test_graph_tfmatmulandadd",
241227
":test_graph_tfmatmulandadd_with_profiling",
242228
":test_graph_tfsplits",
243-
":test_graph_tftop_k",
244229
"//tensorflow/compiler/xla:shape_util",
245230
"//tensorflow/compiler/xla:test",
246231
"//tensorflow/compiler/xla:xla_data_proto",

tensorflow/compiler/aot/tests/make_test_graphs.py

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@
3131
from tensorflow.python.ops import array_ops
3232
from tensorflow.python.ops import control_flow_ops
3333
from tensorflow.python.ops import math_ops
34-
from tensorflow.python.ops import nn_ops
3534
from tensorflow.python.ops import variables
3635
from tensorflow.python.platform import app
3736
from tensorflow.python.training import saver as saver_lib
@@ -143,12 +142,6 @@ def tfsplits(_):
143142
array_ops.identity(y, name='result')
144143

145144

146-
def tftop_k(_):
147-
x = array_ops.placeholder(dtypes.int32, shape=[5], name='x')
148-
output = nn_ops.top_k(x, 2, name='values')
149-
array_ops.identity(output[1], name='indices')
150-
151-
152145
def write_graph(build_graph, out_dir):
153146
"""Build a graph using build_graph and write it out."""
154147
g = ops.Graph()
@@ -170,7 +163,6 @@ def main(_):
170163
write_graph(tfmatmul, FLAGS.out_dir)
171164
write_graph(tfmatmulandadd, FLAGS.out_dir)
172165
write_graph(tfsplits, FLAGS.out_dir)
173-
write_graph(tftop_k, FLAGS.out_dir)
174166

175167

176168
if __name__ == '__main__':

tensorflow/compiler/aot/tests/test_graph_tftop_k.config.pbtxt

Lines changed: 0 additions & 13 deletions
This file was deleted.

tensorflow/compiler/aot/tests/tfcompile_test.cc

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ limitations under the License.
2929
#include "tensorflow/compiler/aot/tests/test_graph_tfmatmulandadd.h"
3030
#include "tensorflow/compiler/aot/tests/test_graph_tfmatmulandadd_with_profiling.h"
3131
#include "tensorflow/compiler/aot/tests/test_graph_tfsplits.h"
32-
#include "tensorflow/compiler/aot/tests/test_graph_tftop_k.h"
3332
#include "tensorflow/compiler/xla/service/hlo_profile_printer.h"
3433
#include "tensorflow/compiler/xla/shape_util.h"
3534
#include "tensorflow/compiler/xla/test.h"
@@ -449,30 +448,6 @@ TEST(TFCompileTest, Splits) {
449448
EXPECT_NEAR(expected[3], fn.result0(1, 1), 1e4);
450449
}
451450

452-
TEST(TFCompileTest, TopK) {
453-
Eigen::ThreadPool tp(1);
454-
Eigen::ThreadPoolDevice device(&tp, tp.NumThreads());
455-
456-
TopKComp fn;
457-
458-
fn.set_thread_pool(&device);
459-
// x = [4, 1, 4, 4, 3]
460-
fn.arg0(0) = 4;
461-
fn.arg0(1) = 1;
462-
fn.arg0(2) = 4;
463-
fn.arg0(3) = 4;
464-
fn.arg0(4) = 3;
465-
466-
EXPECT_TRUE(fn.Run());
467-
EXPECT_EQ(fn.error_msg(), "");
468-
const int32 expected_values[] = {4, 4};
469-
const int32 expected_indices[] = {0, 2};
470-
EXPECT_EQ(expected_values[0], fn.result0(0));
471-
EXPECT_EQ(expected_values[1], fn.result0(1));
472-
EXPECT_EQ(expected_indices[0], fn.result1(0));
473-
EXPECT_EQ(expected_indices[1], fn.result1(1));
474-
}
475-
476451
TEST(TFCompileTest, AssertEqAndReturnDiff) {
477452
// Assert is converted into a no-op in XLA, so there is no failure even if the
478453
// two args are different.

tensorflow/compiler/aot/tfcompile.bzl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,6 @@ def tf_library(
273273
"//tensorflow/compiler/tf2xla/kernels:index_ops_kernel_argmax_float_1d",
274274
"//tensorflow/compiler/tf2xla/kernels:index_ops_kernel_argmax_float_2d",
275275
"//tensorflow/compiler/xla/service/cpu:runtime_conv2d",
276-
"//tensorflow/compiler/xla/service/cpu:runtime_key_value_sort",
277276
"//tensorflow/compiler/xla/service/cpu:runtime_matmul",
278277
"//tensorflow/compiler/xla/service/cpu:runtime_single_threaded_conv2d",
279278
"//tensorflow/compiler/xla/service/cpu:runtime_single_threaded_matmul",

0 commit comments

Comments
 (0)