Hit this IR produced by SPIRVVectorize: ```mlir %50 = math.sqrt %cst : f32 %67 = splat %50 : vector<1x2x2x4xf32> %68 = vector.extract_strided_slice %67 {offsets = [0, 0, 0, 0], sizes = [1, 1, 1, 4], strides = [1, 1, 1, 1]} : vector<1x2x2x4xf32> to vector<1x1x1x4xf32> %69 = divf %60, %68 : vector<1x1x1x4xf32> ``` that then fails to convert to SPIR-V (`failed to legalize operation 'std.splat'`). Repro: ``` iree-translate \ -iree-mlir-to-vm-bytecode-module \ -iree-hal-target-backends=vulkan-spirv \ -iree-input-type=mhlo \ tf_mid_level_input.mlir ``` [tf_mid_level_input.zip](https://github.com/google/iree/files/7334066/tf_mid_level_input.zip)
Activity
Workaround for #7323: extract_strided_slice canonicalization.
ThomasRaoux commentedon Oct 13, 2021
Canonicalization sent for review:
https://reviews.llvm.org/D111690
ThomasRaoux commentedon Oct 13, 2021
Fixed with:
llvm/llvm-project@cc83c24