[XLA/CPU] Fix some indexing bugs in the CPU driver, a tool for reproducing miscompiles in OSS with no dependencies
[XLA/CPU] Fix some indexing bugs in the CPU driver, a tool for reproducing miscompiles in OSS with no dependencies

There were quite a few bugs found and fixed due to the first "real" usage on a
large-ish input HLO, so I'm not listing them all in the description. Mostly
mismatches of "allocation_idx" and "param_idx".

PiperOrigin-RevId: 293717042
Change-Id: Ibf42377f3ff18720b387ddd6903d897d3a4dd4be

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