Skip to content

Rename @isolated in the SIL sense to @sil_isolated #71333

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion include/swift/AST/TypeAttr.def
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ SIMPLE_SIL_TYPE_ATTR(yield_many, YieldMany)
SIMPLE_SIL_TYPE_ATTR(captures_generics, CapturesGenerics)
// Used at the SIL level to mark a type as moveOnly.
SIMPLE_SIL_TYPE_ATTR(moveOnly, MoveOnly)
SIMPLE_SIL_TYPE_ATTR(isolated, Isolated)
SIMPLE_SIL_TYPE_ATTR(sil_isolated, SILIsolated)

// SIL metatype attributes.
SIMPLE_SIL_TYPE_ATTR(thin, Thin)
Expand Down
2 changes: 1 addition & 1 deletion lib/AST/ASTPrinter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8087,7 +8087,7 @@ void SILParameterInfo::print(ASTPrinter &Printer,

if (options.contains(SILParameterInfo::Isolated)) {
options -= SILParameterInfo::Isolated;
Printer << "@isolated ";
Printer << "@sil_isolated ";
}

// If we did not handle a case in Options, this code was not updated
Expand Down
2 changes: 1 addition & 1 deletion lib/ASTGen/Sources/ASTGen/TypeAttrs.swift
Original file line number Diff line number Diff line change
Expand Up @@ -102,11 +102,11 @@ extension ASTGenVisitor {
.inGuaranteed,
.inout,
.inoutAliasable,
.isolated,
.moveOnly,
.objCMetatype,
.out,
.owned,
.silIsolated,
.silUnmanaged,
.silUnowned,
.silWeak,
Expand Down
2 changes: 1 addition & 1 deletion lib/Sema/TypeCheckType.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4432,7 +4432,7 @@ SILParameterInfo TypeResolver::resolveSILParameter(
parameterOptions |= SILParameterInfo::NotDifferentiable;
return true;

case TypeAttrKind::Isolated:
case TypeAttrKind::SILIsolated:
parameterOptions |= SILParameterInfo::Isolated;
return true;

Expand Down
4 changes: 2 additions & 2 deletions test/Distributed/Runtime/distributed_actor_self_calls.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ distributed actor Philosopher {
distributed func think() {
}

// CHECK: sil hidden [ossa] @$s28distributed_actor_self_calls11PhilosopherC10stopEatingyyF : $@convention(method) (@isolated @guaranteed Philosopher) -> () {
// CHECK: sil hidden [ossa] @$s28distributed_actor_self_calls11PhilosopherC10stopEatingyyF : $@convention(method) (@sil_isolated @guaranteed Philosopher) -> () {
func stopEating() { // NOTE: marking this async solves the issue; we find the async context then
self.think()

Expand All @@ -25,7 +25,7 @@ distributed actor Philosopher {
// trying to get the async context to call the async thunk would fail here.
//
// CHECK: // function_ref Philosopher.think()
// CHECK-NEXT: [[E:%[0-9]+]] = function_ref @$s28distributed_actor_self_calls11PhilosopherC5thinkyyF : $@convention(method) (@isolated @guaranteed Philosopher) -> ()
// CHECK-NEXT: [[E:%[0-9]+]] = function_ref @$s28distributed_actor_self_calls11PhilosopherC5thinkyyF : $@convention(method) (@sil_isolated @guaranteed Philosopher) -> ()
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ distributed actor MyDistActor {
}

// CHECK-LABEL: // MyDistActor.init(system_async_fail:cond:)
// CHECK: sil hidden{{.*}} @$s14default_deinit11MyDistActorC17system_async_fail4condACSg015FakeDistributedE7Systems0jE6SystemV_SbtYacfc : $@convention(method) @async (@owned FakeActorSystem, Bool, @isolated @owned MyDistActor) -> @owned Optional<MyDistActor> {
// CHECK: sil hidden{{.*}} @$s14default_deinit11MyDistActorC17system_async_fail4condACSg015FakeDistributedE7Systems0jE6SystemV_SbtYacfc : $@convention(method) @async (@owned FakeActorSystem, Bool, @sil_isolated @owned MyDistActor) -> @owned Optional<MyDistActor> {
// CHECK: bb0([[SYSTEM:%[0-9]+]] : $FakeActorSystem, [[COND:%[0-9]+]] : $Bool, [[SELF:%[0-9]+]] : $MyDistActor):
// CHECK: cond_br {{%[0-9]+}}, [[SUCCESS_BB:bb[0-9]+]], [[FAIL_BB:bb[0-9]+]]

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ distributed actor MyDistActor {
}

// CHECK-LABEL: // MyDistActor.init(system_async_fail_throws:cond:)
// CHECK: sil hidden @$s14default_deinit11MyDistActorC24system_async_fail_throws4condACSg015FakeDistributedE7Systems0kE6SystemV_SbtYaKcfc : $@convention(method) @async (@owned FakeActorSystem, Bool, @isolated @owned MyDistActor) -> (@owned Optional<MyDistActor>, @error any Error) {
// CHECK: sil hidden @$s14default_deinit11MyDistActorC24system_async_fail_throws4condACSg015FakeDistributedE7Systems0kE6SystemV_SbtYaKcfc : $@convention(method) @async (@owned FakeActorSystem, Bool, @sil_isolated @owned MyDistActor) -> (@owned Optional<MyDistActor>, @error any Error) {
// CHECK: bb0([[SYSTEM:%[0-9]+]] : $FakeActorSystem, [[COND:%[0-9]+]] : $Bool, [[SELF:%[0-9]+]] : $MyDistActor):
// CHECK: cond_br {{%[0-9]+}}, [[SUCCESS_BB:bb[0-9]+]], [[FAIL_BB:bb[0-9]+]]

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ distributed actor MyDistActor {
self.localOnlyField = SomeClass()
}

// CHECK: sil hidden @$s14default_deinit11MyDistActorC12system_async4condAC015FakeDistributedE7Systems0iE6SystemV_SbtYacfc : $@convention(method) @async (@owned FakeActorSystem, Bool, @isolated @owned MyDistActor) -> @owned MyDistActor {
// CHECK: sil hidden @$s14default_deinit11MyDistActorC12system_async4condAC015FakeDistributedE7Systems0iE6SystemV_SbtYacfc : $@convention(method) @async (@owned FakeActorSystem, Bool, @sil_isolated @owned MyDistActor) -> @owned MyDistActor {
// CHECK: bb0([[SYSTEM:%[0-9]+]] : $FakeActorSystem, [[COND:%[0-9]+]] : $Bool, [[SELF:%[0-9]+]] : $MyDistActor):
// CHECK: builtin "initializeDefaultActor"([[SELF]] : $MyDistActor)
// CHECK: [[SYS_FIELD:%[0-9]+]] = ref_element_addr [[SELF]] : $MyDistActor, #MyDistActor.actorSystem
Expand Down
2 changes: 1 addition & 1 deletion test/Distributed/SIL/distributed_thunk.swift
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ extension DA {
// CHECK: function_ref @swift_distributed_actor_is_remote

// Call the actor function
// CHECK: function_ref @$s17distributed_thunk2DAC1fyyF : $@convention(method) (@isolated @guaranteed DA) -> ()
// CHECK: function_ref @$s17distributed_thunk2DAC1fyyF : $@convention(method) (@sil_isolated @guaranteed DA) -> ()

distributed func f() { }
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ extension DA {

// CHECK-SKIP-ALL-NOT: s38distributed_thunk_skip_function_bodies2DAC13inlinableFuncyyF

// CHECK-SKIP-NONINLINE-LABEL: sil [serialized] [distributed] [ossa] @$s38distributed_thunk_skip_function_bodies2DAC13inlinableFuncyyF : $@convention(method) (@isolated @guaranteed DA) -> () {
// CHECK-SKIP-NONINLINE-LABEL: sil [serialized] [distributed] [ossa] @$s38distributed_thunk_skip_function_bodies2DAC13inlinableFuncyyF : $@convention(method) (@sil_isolated @guaranteed DA) -> () {
// CHECK-SKIP-NONINLINE: function_ref @$s38distributed_thunk_skip_function_bodies9blackHoleyyxlF
// CHECK-SKIP-NONINLINE: } // end sil function '$s38distributed_thunk_skip_function_bodies2DAC13inlinableFuncyyF'
@inlinable public distributed func inlinableFunc() {
Expand Down
2 changes: 1 addition & 1 deletion test/Distributed/distributed_actor_to_actor.swift
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import Distributed
// Make sure there is no runtime record of the protocol descriptor.
// CHECK-IR-NOT: $sxScA11DistributedHc

// CHECK-SIL-LABEL: sil hidden @$s021distributed_actor_to_B011getAnyActor0aF0ScA_pxYi_t11Distributed0gF0RzlF : $@convention(thin) <τ_0_0 where τ_0_0 : DistributedActor> (@isolated @guaranteed τ_0_0) -> @owned any Actor
// CHECK-SIL-LABEL: sil hidden @$s021distributed_actor_to_B011getAnyActor0aF0ScA_pxYi_t11Distributed0gF0RzlF : $@convention(thin) <τ_0_0 where τ_0_0 : DistributedActor> (@sil_isolated @guaranteed τ_0_0) -> @owned any Actor
func getAnyActor(distributedActor: isolated some DistributedActor) -> any Actor {
// CHECK-SIL: [[EXISTENTIAL:%.*]] = init_existential_ref %0 : $τ_0_0 : $τ_0_0, $any Actor
// CHECK-SIL-NEXT: strong_retain [[EXISTENTIAL]] : $any Actor
Expand Down
2 changes: 1 addition & 1 deletion test/IRGen/distributed_func_indirect_in_parameter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public struct LargeValue : Codable {
distributed actor D {
typealias ActorSystem = LocalTestingDistributedActorSystem

// CHECK: sil hidden [distributed] @takeLarge : $@convention(method) (@in_guaranteed LargeValue, @isolated @guaranteed D) -> () {
// CHECK: sil hidden [distributed] @takeLarge : $@convention(method) (@in_guaranteed LargeValue, @sil_isolated @guaranteed D) -> () {
@_silgen_name("takeLarge")
distributed func takeLarge(_ l: LargeValue) {}
}
4 changes: 2 additions & 2 deletions test/SIL/Parser/isolated_parameters.sil
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ import Swift
public protocol AnyActor: AnyObject, Sendable {}
public protocol Actor : AnyActor {}

// CHECK-LABEL: sil @$sScAsE14assumeIsolated_4file4lineqd__qd__xYiKXE_s12StaticStringVSutKlFTwB : $@convention(method) <τ_0_0 where τ_0_0 : Actor><τ_1_0> (@guaranteed @noescape @callee_guaranteed @substituted <τ_0_0, τ_0_1 where τ_0_0 : AnyObject> (@isolated @guaranteed τ_0_0) -> (@out τ_0_1, @error any Error) for <τ_0_0, τ_1_0>, StaticString, UInt, @guaranteed τ_0_0) -> (@out τ_1_0, @error any Error)
// CHECK-LABEL: sil @$sScAsE14assumeIsolated_4file4lineqd__qd__xYiKXE_s12StaticStringVSutKlFTwB : $@convention(method) <τ_0_0 where τ_0_0 : Actor><τ_1_0> (@guaranteed @noescape @callee_guaranteed @substituted <τ_0_0, τ_0_1 where τ_0_0 : AnyObject> (@sil_isolated @guaranteed τ_0_0) -> (@out τ_0_1, @error any Error) for <τ_0_0, τ_1_0>, StaticString, UInt, @guaranteed τ_0_0) -> (@out τ_1_0, @error any Error)

sil @$sScAsE14assumeIsolated_4file4lineqd__qd__xYiKXE_s12StaticStringVSutKlFTwB : $@convention(method) <τ_0_0 where τ_0_0 : Actor><τ_1_0> (@guaranteed @noescape @callee_guaranteed @substituted <τ_0_0, τ_0_1 where τ_0_0 : AnyObject> (@isolated @guaranteed τ_0_0) -> (@out τ_0_1, @error any Error) for <τ_0_0, τ_1_0>, StaticString, UInt, @guaranteed τ_0_0) -> (@out τ_1_0, @error any Error)
sil @$sScAsE14assumeIsolated_4file4lineqd__qd__xYiKXE_s12StaticStringVSutKlFTwB : $@convention(method) <τ_0_0 where τ_0_0 : Actor><τ_1_0> (@guaranteed @noescape @callee_guaranteed @substituted <τ_0_0, τ_0_1 where τ_0_0 : AnyObject> (@sil_isolated @guaranteed τ_0_0) -> (@out τ_0_1, @error any Error) for <τ_0_0, τ_1_0>, StaticString, UInt, @guaranteed τ_0_0) -> (@out τ_1_0, @error any Error)
4 changes: 2 additions & 2 deletions test/SIL/Serialization/isolated_parameters.sil
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ public protocol AnyActor: AnyObject, Sendable {}
public protocol Actor : AnyActor {}


// CHECK-LABEL: sil [serialized] [ossa] @assumeIsolated : $@convention(method) <τ_0_0 where τ_0_0 : Actor> (@isolated @guaranteed τ_0_0) -> () {
// CHECK-LABEL: sil [serialized] [ossa] @assumeIsolated : $@convention(method) <τ_0_0 where τ_0_0 : Actor> (@sil_isolated @guaranteed τ_0_0) -> () {

sil [serialized] [ossa] @assumeIsolated : $@convention(method) <τ_0_0 where τ_0_0 : Actor> (@isolated @guaranteed τ_0_0) -> () {
sil [serialized] [ossa] @assumeIsolated : $@convention(method) <τ_0_0 where τ_0_0 : Actor> (@sil_isolated @guaranteed τ_0_0) -> () {
bb0(%0 : @guaranteed $τ_0_0):
unreachable
}
2 changes: 1 addition & 1 deletion test/SILGen/async_conversion.swift
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ actor A: P2 {
actor AnActor {
func isolatedMethod(_ i: Int) {}

// CHECK-LABEL: sil hidden [ossa] @$s4test7AnActorC6calleryyYaF : $@convention(method) @async (@isolated @guaranteed AnActor) -> () {
// CHECK-LABEL: sil hidden [ossa] @$s4test7AnActorC6calleryyYaF : $@convention(method) @async (@sil_isolated @guaranteed AnActor) -> () {
func caller() async {
// CHECK: hop_to_executor {{..*}} : $AnActor
// [[F:%.*]] = function_ref @$s4test7AnActorC6calleryyYaFySicACYicfu_ : $@convention(thin) (@guaranteed AnActor) -> @owned @callee_guaranteed (Int) -> ()
Expand Down
4 changes: 2 additions & 2 deletions test/SILGen/async_initializer.swift
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ enum MyEnum {
}

actor MyActor {
// CHECK-DAG: sil hidden [ossa] @$s12initializers7MyActorCACyYacfc : $@convention(method) @async (@isolated @owned MyActor) -> @owned MyActor
// CHECK-DAG: sil hidden [ossa] @$s12initializers7MyActorCACyYacfc : $@convention(method) @async (@sil_isolated @owned MyActor) -> @owned MyActor
init() async {}
}

Expand Down Expand Up @@ -166,7 +166,7 @@ actor SomeActor {
// The implicit check-not covers that for us. The hops are inserted later.
init() async {}

// CHECK-LABEL: sil hidden [ossa] @$s12initializers9SomeActorC10someMethodyyYaF : $@convention(method) @async (@isolated @guaranteed SomeActor) -> () {
// CHECK-LABEL: sil hidden [ossa] @$s12initializers9SomeActorC10someMethodyyYaF : $@convention(method) @async (@sil_isolated @guaranteed SomeActor) -> () {
// CHECK: hop_to_executor {{%[0-9]+}} : $SomeActor
// CHECK: } // end sil function '$s12initializers9SomeActorC10someMethodyyYaF'
func someMethod() async {}
Expand Down
10 changes: 5 additions & 5 deletions test/SILGen/effectful_properties.swift
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,12 @@ enum E {
}

actor A {
// CHECK-DAG: sil hidden [transparent] [ossa] @$s9accessors1AC10normalPropSivg : $@convention(method) (@isolated @guaranteed A) -> Int {
// CHECK-DAG: sil hidden [transparent] [ossa] @$s9accessors1AC10normalPropSivg : $@convention(method) (@sil_isolated @guaranteed A) -> Int {
var normalProp : Int = 0
// CHECK-DAG: sil hidden [ossa] @$s9accessors1AC12computedPropSivg : $@convention(method) (@isolated @guaranteed A) -> Int {
// CHECK-DAG: sil hidden [ossa] @$s9accessors1AC12computedPropSivg : $@convention(method) (@sil_isolated @guaranteed A) -> Int {
var computedProp : Int { get { 0 } }

// CHECK-LABEL: sil hidden [ossa] @$s9accessors1AC9asyncPropSivg : $@convention(method) @async (@isolated @guaranteed A) -> Int {
// CHECK-LABEL: sil hidden [ossa] @$s9accessors1AC9asyncPropSivg : $@convention(method) @async (@sil_isolated @guaranteed A) -> Int {
// CHECK: bb0([[SELF:%[0-9]+]] : @guaranteed $A):
// CHECK: hop_to_executor [[SELF]] : $A
// CHECK: } // end sil function '$s9accessors1AC9asyncPropSivg'
Expand All @@ -51,7 +51,7 @@ actor A {

// CHECK-LABEL: sil hidden [ossa] @$s9accessors19testImplicitlyAsync1aSiAA1AC_tYaF : $@convention(thin) @async (@guaranteed A) -> Int {
// CHECK: hop_to_executor
// CHECK: apply {{%[0-9]+}}({{%[0-9]+}}) : $@convention(method) (@isolated @guaranteed A) -> Int
// CHECK: apply {{%[0-9]+}}({{%[0-9]+}}) : $@convention(method) (@sil_isolated @guaranteed A) -> Int
// CHECK: hop_to_executor
// CHECK: } // end sil function '$s9accessors19testImplicitlyAsync1aSiAA1AC_tYaF'
func testImplicitlyAsync(a : A) async -> Int {
Expand All @@ -60,7 +60,7 @@ func testImplicitlyAsync(a : A) async -> Int {


// CHECK-LABEL: sil hidden [ossa] @$s9accessors15testNormalAsync1aSiAA1AC_tYaF : $@convention(thin) @async (@guaranteed A) -> Int {
// CHECK: apply {{%[0-9]+}}({{%[0-9]+}}) : $@convention(method) @async (@isolated @guaranteed A) -> Int
// CHECK: apply {{%[0-9]+}}({{%[0-9]+}}) : $@convention(method) @async (@sil_isolated @guaranteed A) -> Int
// CHECK: } // end sil function '$s9accessors15testNormalAsync1aSiAA1AC_tYaF'
func testNormalAsync(a : A) async -> Int {
return await a.asyncProp
Expand Down
12 changes: 6 additions & 6 deletions test/SILGen/foreach_async.swift
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,9 @@ struct AsyncLazySequence<S: Sequence>: AsyncSequence {
// CHECK: [[NEXT_RESULT:%.*]] = alloc_stack $Optional<Int>
// CHECK: [[ACTOR:%.*]] = enum $Optional<any Actor>, #Optional.none!enumelt
// CHECK: [[MUTATION:%.*]] = begin_access
// CHECK: [[WITNESS_METHOD:%.*]] = function_ref @$sScIsE4nexty7ElementQzSgScA_pSgYiYa7FailureQzYKF : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure)
// CHECK: [[WITNESS_METHOD:%.*]] = function_ref @$sScIsE4nexty7ElementQzSgScA_pSgYiYa7FailureQzYKF : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@sil_isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure)
// CHECK: [[ERROR_SLOT:%[0-9]+]] = alloc_stack $Never
// CHECK: try_apply [[WITNESS_METHOD]]<AsyncLazySequence<[Int]>.Iterator>([[NEXT_RESULT]], [[ERROR_SLOT]], [[ACTOR]], [[MUTATION]]) : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure), normal [[NORMAL_BB:bb[0-2]+]], error [[ERROR_BB:bb[0-9]+]]
// CHECK: try_apply [[WITNESS_METHOD]]<AsyncLazySequence<[Int]>.Iterator>([[NEXT_RESULT]], [[ERROR_SLOT]], [[ACTOR]], [[MUTATION]]) : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@sil_isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure), normal [[NORMAL_BB:bb[0-2]+]], error [[ERROR_BB:bb[0-9]+]]
// CHECK: [[NORMAL_BB]](
// CHECK: end_access [[MUTATION]]
// CHECK: switch_enum [[IND_VAR:%.*]] : $Optional<Int>, case #Optional.some!enumelt: [[SOME_BB:bb[0-9]+]], case #Optional.none!enumelt: [[NONE_BB:bb[0-9]+]]
Expand Down Expand Up @@ -115,9 +115,9 @@ func trivialStruct(_ xx: AsyncLazySequence<[Int]>) async {
// CHECK: [[NEXT_RESULT:%.*]] = alloc_stack $Optional<Int>
// CHECK: [[ACTOR:%.*]] = enum $Optional<any Actor>, #Optional.none!enumelt
// CHECK: [[MUTATION:%.*]] = begin_access
// CHECK: [[WITNESS_METHOD:%.*]] = function_ref @$sScIsE4nexty7ElementQzSgScA_pSgYiYa7FailureQzYKF : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure)
// CHECK: [[WITNESS_METHOD:%.*]] = function_ref @$sScIsE4nexty7ElementQzSgScA_pSgYiYa7FailureQzYKF : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@sil_isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure)
// CHECK: [[ERROR_SLOT:%[0-9]+]] = alloc_stack $Never
// CHECK: try_apply [[WITNESS_METHOD]]<AsyncLazySequence<[Int]>.Iterator>([[NEXT_RESULT]], [[ERROR_SLOT]], [[ACTOR]], [[MUTATION]]) : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure), normal [[NORMAL_BB:bb[0-2]+]], error [[ERROR_BB:bb[0-9]+]]
// CHECK: try_apply [[WITNESS_METHOD]]<AsyncLazySequence<[Int]>.Iterator>([[NEXT_RESULT]], [[ERROR_SLOT]], [[ACTOR]], [[MUTATION]]) : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@sil_isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure), normal [[NORMAL_BB:bb[0-2]+]], error [[ERROR_BB:bb[0-9]+]]
// CHECK: [[NORMAL_BB]](
// CHECK: end_access [[MUTATION]]
// CHECK: switch_enum [[IND_VAR:%.*]] : $Optional<Int>, case #Optional.some!enumelt: [[SOME_BB:bb[0-9]+]], case #Optional.none!enumelt: [[NONE_BB:bb[0-9]+]]
Expand Down Expand Up @@ -175,9 +175,9 @@ func trivialStructBreak(_ xx: AsyncLazySequence<[Int]>) async {
// CHECK: [[NEXT_RESULT:%.*]] = alloc_stack $Optional<Int>
// CHECK: [[ACTOR:%.*]] = enum $Optional<any Actor>, #Optional.none!enumelt
// CHECK: [[MUTATION:%.*]] = begin_access
// CHECK: [[WITNESS_METHOD:%.*]] = function_ref @$sScIsE4nexty7ElementQzSgScA_pSgYiYa7FailureQzYKF : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure)
// CHECK: [[WITNESS_METHOD:%.*]] = function_ref @$sScIsE4nexty7ElementQzSgScA_pSgYiYa7FailureQzYKF : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@sil_isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure)
// CHECK: [[ERROR_SLOT:%[0-9]+]] = alloc_stack $Never
// CHECK: try_apply [[WITNESS_METHOD]]<AsyncLazySequence<[Int]>.Iterator>([[NEXT_RESULT]], [[ERROR_SLOT]], [[ACTOR]], [[MUTATION]]) : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure), normal [[NORMAL_BB:bb[0-2]+]], error [[ERROR_BB:bb[0-9]+]]
// CHECK: try_apply [[WITNESS_METHOD]]<AsyncLazySequence<[Int]>.Iterator>([[NEXT_RESULT]], [[ERROR_SLOT]], [[ACTOR]], [[MUTATION]]) : $@convention(method) @async <τ_0_0 where τ_0_0 : AsyncIteratorProtocol> (@sil_isolated @guaranteed Optional<any Actor>, @inout τ_0_0) -> (@out Optional<τ_0_0.Element>, @error_indirect τ_0_0.Failure), normal [[NORMAL_BB:bb[0-2]+]], error [[ERROR_BB:bb[0-9]+]]
// CHECK: [[NORMAL_BB]](
// CHECK: end_access [[MUTATION]]
// CHECK: switch_enum [[IND_VAR:%.*]] : $Optional<Int>, case #Optional.some!enumelt: [[SOME_BB:bb[0-9]+]], case #Optional.none!enumelt: [[NONE_BB:bb[0-9]+]]
Expand Down
Loading