Generalize xla.is_flat to include any Mapping type, not just dict.
Generalize xla.is_flat to include any Mapping type, not just dict.

This allows custom mapping types to be returned from functions used with xla.compile.

PiperOrigin-RevId: 315497847
Change-Id: I6498c13aaba4b564b04a5fa2be29d6ce7ae31356

freedomtan/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,aam-at/tensorflow,aam-at/tensorflow,Intel-tensorflow/tensorflow,aam-at/tensorflow,aam-at/tensorflow,petewarden/tensorflow,frreiss/tensorflow-fred,petewarden/tensorflow,annarev/tensorflow,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow-pywrap_tf_optimizer,paolodedios/tensorflow,davidzchen/tensorflow,davidzchen/tensorflow,yongtang/tensorflow,aam-at/tensorflow,paolodedios/tensorflow,paolodedios/tensorflow,freedomtan/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,freedomtan/tensorflow,aldian/tensorflow,karllessard/tensorflow,sarvex/tensorflow,tensorflow/tensorflow-pywrap_saved_model,aldian/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,petewarden/tensorflow,aam-at/tensorflow,frreiss/tensorflow-fred,Intel-tensorflow/tensorflow,Intel-tensorflow/tensorflow,cxxgtxy/tensorflow,Intel-tensorflow/tensorflow,gautam1858/tensorflow,Intel-Corporation/tensorflow,karllessard/tensorflow,karllessard/tensorflow,tensorflow/tensorflow,frreiss/tensorflow-fred,annarev/tensorflow,frreiss/tensorflow-fred,Intel-tensorflow/tensorflow,tensorflow/tensorflow,freedomtan/tensorflow,tensorflow/tensorflow-pywrap_saved_model,yongtang/tensorflow,aam-at/tensorflow,davidzchen/tensorflow,cxxgtxy/tensorflow,annarev/tensorflow,yongtang/tensorflow,frreiss/tensorflow-fred,tensorflow/tensorflow-pywrap_tf_optimizer,tensorflow/tensorflow,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow-pywrap_saved_model,aam-at/tensorflow,yongtang/tensorflow,annarev/tensorflow,davidzchen/tensorflow,cxxgtxy/tensorflow,petewarden/tensorflow,Intel-tensorflow/tensorflow,gautam1858/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,frreiss/tensorflow-fred,sarvex/tensorflow,petewarden/tensorflow,sarvex/tensorflow,gautam1858/tensorflow,yongtang/tensorflow,gautam1858/tensorflow,aam-at/tensorflow,tensorflow/tensorflow,freedomtan/tensorflow,freedomtan/tensorflow,sarvex/tensorflow,karllessard/tensorflow,frreiss/tensorflow-fred,tensorflow/tensorflow-pywrap_tf_optimizer,cxxgtxy/tensorflow,cxxgtxy/tensorflow,cxxgtxy/tensorflow,yongtang/tensorflow,freedomtan/tensorflow,yongtang/tensorflow,Intel-tensorflow/tensorflow,aldian/tensorflow,annarev/tensorflow,gautam1858/tensorflow,tensorflow/tensorflow-pywrap_saved_model,gautam1858/tensorflow,aam-at/tensorflow,sarvex/tensorflow,aldian/tensorflow,Intel-Corporation/tensorflow,paolodedios/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,sarvex/tensorflow,freedomtan/tensorflow,gautam1858/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,paolodedios/tensorflow,gautam1858/tensorflow,petewarden/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,yongtang/tensorflow,paolodedios/tensorflow,Intel-Corporation/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,tensorflow/tensorflow,tensorflow/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,tensorflow/tensorflow-pywrap_tf_optimizer,freedomtan/tensorflow,sarvex/tensorflow,annarev/tensorflow,frreiss/tensorflow-fred,tensorflow/tensorflow-pywrap_tf_optimizer,karllessard/tensorflow,davidzchen/tensorflow,yongtang/tensorflow,Intel-Corporation/tensorflow,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow-pywrap_saved_model,annarev/tensorflow,gautam1858/tensorflow,frreiss/tensorflow-fred,paolodedios/tensorflow,annarev/tensorflow,annarev/tensorflow,petewarden/tensorflow,paolodedios/tensorflow,frreiss/tensorflow-fred,aldian/tensorflow,aldian/tensorflow,petewarden/tensorflow,Intel-Corporation/tensorflow,frreiss/tensorflow-fred,freedomtan/tensorflow,petewarden/tensorflow,tensorflow/tensorflow,tensorflow/tensorflow,frreiss/tensorflow-fred,tensorflow/tensorflow-experimental_link_static_libraries_once,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow-pywrap_tf_optimizer,annarev/tensorflow,aldian/tensorflow,tensorflow/tensorflow-pywrap_saved_model,Intel-Corporation/tensorflow,gautam1858/tensorflow,cxxgtxy/tensorflow,sarvex/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,karllessard/tensorflow,freedomtan/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,davidzchen/tensorflow,tensorflow/tensorflow-pywrap_saved_model,Intel-tensorflow/tensorflow,annarev/tensorflow,yongtang/tensorflow,karllessard/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,paolodedios/tensorflow,petewarden/tensorflow,karllessard/tensorflow,Intel-tensorflow/tensorflow,davidzchen/tensorflow,gautam1858/tensorflow,karllessard/tensorflow,karllessard/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,tensorflow/tensorflow,Intel-Corporation/tensorflow,petewarden/tensorflow,paolodedios/tensorflow,davidzchen/tensorflow,yongtang/tensorflow,freedomtan/tensorflow,paolodedios/tensorflow,Intel-tensorflow/tensorflow,davidzchen/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,tensorflow/tensorflow,cxxgtxy/tensorflow,aldian/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,davidzchen/tensorflow,Intel-tensorflow/tensorflow,aam-at/tensorflow,aam-at/tensorflow,davidzchen/tensorflow,karllessard/tensorflow,Intel-Corporation/tensorflow,gautam1858/tensorflow,petewarden/tensorflow,davidzchen/tensorflow,tensorflow/tensorflow