@@ -3770,10 +3770,11 @@ This is the case, e.g. for conditionally initialized objects.
37703770The optional ``lexical `` attribute specifies that the storage corresponds to a
37713771local variable in the Swift source.
37723772
3773- The optional ``moveable_value_debuginfo `` attribute specifies that when
3774- emitting debug info, the code generator can not assume that the value in the
3775- alloc_stack can be semantically valid over the entire function frame when
3776- emitting debug info.
3773+ The optional ``moveable_value_debuginfo `` attribute specifies that when emitting
3774+ debug info, the code generator can not assume that the value in the alloc_stack
3775+ can be semantically valid over the entire function frame when emitting debug
3776+ info. NOTE: This is implicitly set to true if the alloc_stack's type is
3777+ noncopyable. This is just done to make SIL less verbose.
37773778
37783779The memory is not retainable. To allocate a retainable box for a value
37793780type, use ``alloc_box ``.
@@ -3886,10 +3887,11 @@ Releasing a box is undefined behavior if the box's value is uninitialized.
38863887To deallocate a box whose value has not been initialized, ``dealloc_box ``
38873888should be used.
38883889
3889- The optional ``moveable_value_debuginfo `` attribute specifies that when
3890- emitting debug info, the code generator can not assume that the value in the
3891- alloc_stack can be semantically valid over the entire function frame when
3892- emitting debug info.
3890+ The optional ``moveable_value_debuginfo `` attribute specifies that when emitting
3891+ debug info, the code generator can not assume that the value in the alloc_stack
3892+ can be semantically valid over the entire function frame when emitting debug
3893+ info. NOTE: This is implicitly set to true if the alloc_stack's type is
3894+ noncopyable. This is just done to make SIL less verbose.
38933895
38943896alloc_global
38953897````````````
@@ -4163,7 +4165,10 @@ debug_value
41634165
41644166::
41654167
4166- sil-instruction ::= debug_value '[poison]'? '[moveable_value_debuginfo]'? '[trace]'? sil-operand (',' debug-var-attr)* advanced-debug-var-attr* (',' 'expr' debug-info-expr)?
4168+ sil-instruction ::= debug_value sil-debug-value-option* sil-operand (',' debug-var-attr)* advanced-debug-var-attr* (',' 'expr' debug-info-expr)?
4169+ sil-debug-value-option ::= [poison]
4170+ sil-debug-value-option ::= [moveable_value_debuginfo]
4171+ sil-debug-value-option ::= [trace]
41674172
41684173 debug_value %1 : $Int
41694174
@@ -4172,10 +4177,12 @@ specified operand. The declaration in question is identified by either the
41724177SILLocation attached to the debug_value instruction or the SILLocation specified
41734178in the advanced debug variable attributes.
41744179
4175- If the '[moveable_value_debuginfo]' flag is set, then one knows that the debug_value's operand is
4176- moved at some point of the program, so one can not model the debug_value using
4177- constructs that assume that the value is live for the entire function (e.x.:
4178- llvm.dbg.declare).
4180+ If the ``moveable_value_debuginfo `` flag is set, then one knows that the
4181+ debug_value's operand is moved at some point of the program, so one can not
4182+ model the debug_value using constructs that assume that the value is live for
4183+ the entire function (e.x.: llvm.dbg.declare). NOTE: This is implicitly set to
4184+ true if the alloc_stack's type is noncopyable. This is just done to make SIL
4185+ less verbose.
41794186
41804187::
41814188
0 commit comments