Files
Michael Gottesman a70733c222 [loadable-by-address] Update debug variable type when rewriting alloc_stack
The LoadableByAddress pass rewrites alloc_stack instructions when their element
type changes (e.g., a function parameter convention changes from @guaranteed to
@in_guaranteed for large/opaque types). However, it was passing the original
SILDebugVariable info through unchanged. When the VarInfo has an explicit Type
field set this creates a mismatch between the SSA type and the debug type,
causing a SIL verifier failure.

In this patch, I just change the pass to update the alloc_stack as
appropriate. I verified that this cannot happen with debug_value since we do not
store the extra type info in it if we have an object typed thing. Since
loadable_by_address only changes objects -> addresses, it can never happen.

rdar://164268891
2026-02-20 10:46:39 -08:00
..
2025-05-05 13:50:51 -07:00
2025-04-19 09:55:06 -07:00
2025-08-14 23:06:49 -07:00