Introduce a ShapeUtil::ForEachIndexWithStatus, change index type to ArraySlice
authorSanjoy Das <sanjoy@google.com>
Wed, 28 Feb 2018 19:07:10 +0000 (11:07 -0800)
committerTensorFlower Gardener <gardener@tensorflow.org>
Wed, 28 Feb 2018 19:11:26 +0000 (11:11 -0800)
commit39a43c4f1d73b0210795d2003b127d3ffa284e98
treeafcd8b44aa94a459325b34f6c11d0b4ec4e6fee3
parent12d8142dc1bb914fa3ff0a9029e9b6b71e36b9f5
Introduce a ShapeUtil::ForEachIndexWithStatus, change index type to ArraySlice

This is not used yet, but I need it in a later CL.  I don't specifically need
the argument to be an ArraySlice, but it seemed cleaner than taking a const ref
to a vector.

No functional change intended.

PiperOrigin-RevId: 187352376
tensorflow/compiler/xla/literal_util.cc
tensorflow/compiler/xla/literal_util.h
tensorflow/compiler/xla/literal_util_test.cc
tensorflow/compiler/xla/service/hlo_evaluator.cc
tensorflow/compiler/xla/shape_util.h
tensorflow/compiler/xla/shape_util_test.cc