Skip to content

LLVM ERROR: Don't know how to widen the operands for INSERT_SUBVECTOR #124255

@abhishek-kaushik22

Description

@abhishek-kaushik22
define <8 x i32> @foo(<8 x i32> %a, <2 x i32> %b) {
  %result = tail call <8 x i32> @llvm.vector.insert.v8i32.v2i32(<8 x i32> %a, <2 x i32> %b, i64 0)
  ret <8 x i32> %result
}

https://godbolt.org/z/x6qnfPM7W

We get a fatal error in DAGTypeLegalizer::WidenVecOp_INSERT_SUBVECTOR for this seemingly simple code.
I'm not sure how this could be fixed. Can we just replace the INSERT_SUBVECTOR with a series of INSERT_VECTOR_ELT nodes?

There's also #102016 for AArch that also looks like the same problem as this one.

Metadata

Metadata

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions