xla
xla copied to clipboard
Move `TopKKernel` behind `GpuKernelRegistry`.
Move TopKKernel behind GpuKernelRegistry.
- Moves
TopKlogic intobackends/gpu/runtimesince it's a runtime component. - Defines trait for the
TopKkernel instream_executor/gpu/ - Moves the implementations of this kernel into
stream_executor/{cuda|rocm}and registers them with the registry for eachxla::primitive_util::Type. - Makes
TopKretrieve the kernel by using the kernel registry. - Add the kernel implementations as dependencies to the
all_runtimetargets for CUDA and ROCm.