File tree Expand file tree Collapse file tree 1 file changed +34
-2
lines changed Expand file tree Collapse file tree 1 file changed +34
-2
lines changed Original file line number Diff line number Diff line change @@ -5222,13 +5222,45 @@ the operand (source) heap object. It need not be atomic with respect to
5222
5222
5223
5223
load_unowned
5224
5224
````````````
5225
+ ::
5226
+
5227
+ sil-instruction ::= 'load_unowned' '[take]'? sil-operand
5228
+
5229
+ %1 = load_unowned [take] %0 : $*@sil_unowned T
5230
+ // T must be a reference type
5231
+
5232
+ Increments the strong reference count of the object stored at ``%0 ``.
5233
+
5234
+ Decrements the unowned reference count of the object stored at ``%0 `` if
5235
+ ``[take] `` is specified. Additionally, the storage is invalidated.
5225
5236
5226
- TODO: Fill this in
5237
+ Requires that the strong reference count of the heap object stored at ``%0 `` is
5238
+ positive. Otherwise, traps.
5239
+
5240
+ This operation must be atomic with respect to the final ``strong_release `` on
5241
+ the operand (source) heap object. It need not be atomic with respect to
5242
+ ``store_unowned `` or ``load_unowned `` operations on the same address.
5227
5243
5228
5244
store_unowned
5229
5245
`````````````
5246
+ ::
5247
+
5248
+ sil-instruction ::= 'store_unowned' sil-value 'to' '[init]'? sil-operand
5249
+
5250
+ store_unowned %0 to [init] %1 : $*@sil_unowned T
5251
+ // T must be a reference type
5252
+
5253
+ Increments the unowned reference count of the object at ``%0 ``.
5254
+
5255
+ Decrements the unowned reference count of the object previously stored at ``%1 ``
5256
+ if ``[init] `` is not specified.
5257
+
5258
+ The storage must be initialized iff ``[init] `` is not specified.
5259
+
5260
+ This operation must be atomic with respect to the final ``strong_release `` on
5261
+ the operand (source) heap object. It need not be atomic with respect to
5262
+ ``store_unowned `` or ``load_unowned `` operations on the same address.
5230
5263
5231
- TODO: Fill this in
5232
5264
5233
5265
fix_lifetime
5234
5266
````````````
You can’t perform that action at this time.
0 commit comments