================
@@ -349,13 +347,30 @@ SPIRVGlobalRegistry::getOpTypeVector(uint32_t NumElems, 
SPIRVTypeInst ElemType,
 
   return createConstOrTypeAtFunctionEntry(
       MIRBuilder, [&](MachineIRBuilder &MIRBuilder) {
-        return MIRBuilder.buildInstr(SPIRV::OpTypeVector)
+        return MIRBuilder
+            .buildInstr(IsLongVector ? SPIRV::OpTypeVectorIdEXT
----------------
maarquitos14 wrote:

I'm hesitant that `IsLongVector` is the best name for this. If I read the spec 
correctly, a 1-element vector needs the extension. At the same time, I 
understand that this maps directly to the spec extension name, which is indeed 
`SPV_EXT_long_vector`. Maybe `IsLongVectorExt` instead?

https://github.com/llvm/llvm-project/pull/210279
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to