[llvm] Emit debug type vector (PR #200056)
Manuel Carrasco via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 9 07:15:38 PDT 2026
================
@@ -370,6 +383,31 @@ void SPIRVNonSemanticDebugHandler::emitNonSemanticGlobalDebugInfo(
BasicTypeRegs[BT] = BTReg;
}
+ // Emit DebugTypeVector for each collected vector type. Skip vectors with
+ // non-scalar element types (not yet supported) and vectors with a
+ // non-constant subrange count (not yet supported).
+ for (const DICompositeType *VT : VectorTypes) {
+ const auto *BaseTy = dyn_cast_or_null<DIBasicType>(VT->getBaseType());
+ if (!BaseTy)
----------------
mgcarrasco wrote:
> Well, the thing is that dyn_cast_or_null will return null in two cases: when the base type is absent and when it's not a DIBasicType. I'd rather be able to separate the reasons why we're skipping. Skipping non-basic types is an intentional skip. As opposed to the map guard that handles valid types that are not yet emitted.
Would it be possible to add some tests to exercise those cases?
https://github.com/llvm/llvm-project/pull/200056
More information about the llvm-commits
mailing list