Removes usage of VectorType::getNumElements identified by test located
at CodeGen/aarch64-sve-intrinsics/acle_sve_dot.c. This code explicitly
converts a potentially fixed length vector to scalable vector by
constructing the ElementCount = {getNumElements(), true}
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
llvm/lib/IR/Function.cpp | ||
---|---|---|
1080 | It's intentional. See EncodeFixedType in llvm/utils/TableGen/IntrinsicEmitter.cpp . Actually, Ty should always be a FixedVectorType here, I think; maybe we can just cast<FixedVectorType> here? |
llvm/lib/IR/Function.cpp | ||
---|---|---|
1080 | It's not super clear to me because the types and values don't line up exactly, but it seems like this all has to do with serialization, and in the stream there's something like: VALUE -> PREFIX SUFFIX PREFIX -> SCALABLE | SCALABLE -> [value that specifies if the following is actually a scalable vector] SUFFIX -> [value for a fixed width vector] ... seems like a bit of an abuse to me, but doing anything about it would involve changing the data layout. |
This behavior was introduced in D65930. It seems to me that this would have just returned the decoded type if it were expected that the decoded type would be scalable.