Add heuristic on picking NHWC layout for (V100, fp16) convolutions.
authorA. Unique TensorFlower <gardener@tensorflow.org>
Fri, 25 May 2018 00:48:21 +0000 (17:48 -0700)
committerTensorFlower Gardener <gardener@tensorflow.org>
Fri, 25 May 2018 00:50:57 +0000 (17:50 -0700)
commitf6066436884476d7bc32cf2ad6cfc8d9c52b5482
tree1a6aece3e70ab0c0bddc758f401a12cab67e8bd1
parent0c940ff33add2e8481cc1a5a166d8af72a5a21f9
Add heuristic on picking NHWC layout for (V100, fp16) convolutions.

Also move AlgorithmPicker after layout assignment, as now
cudnn_convolution_runner will return failures on invalid input layouts.

Also add a backend debug option to switch the layout heuristic. By default
it has the old behavior (all NCHW).

PiperOrigin-RevId: 197983747
13 files changed:
tensorflow/compiler/xla/layout_util.cc
tensorflow/compiler/xla/layout_util.h
tensorflow/compiler/xla/service/gpu/BUILD
tensorflow/compiler/xla/service/gpu/cudnn_convolution_runner.cc
tensorflow/compiler/xla/service/gpu/gpu_compiler.cc
tensorflow/compiler/xla/service/gpu/gpu_layout_assignment.cc
tensorflow/compiler/xla/service/gpu/gpu_layout_assignment.h
tensorflow/compiler/xla/service/gpu/gpu_layout_assignment_test.cc
tensorflow/compiler/xla/service/gpu/gpu_options.cc [new file with mode: 0644]
tensorflow/compiler/xla/service/gpu/gpu_options.h [new file with mode: 0644]
tensorflow/compiler/xla/service/gpu/stream_executor_util.cc [new file with mode: 0644]
tensorflow/compiler/xla/service/gpu/stream_executor_util.h [new file with mode: 0644]
tensorflow/compiler/xla/tests/BUILD