Closed MahdiBM closed 6 months ago
I am getting a similar crash
SIL verification failed: init_existential_ref operand must be lowered to the right abstraction level for the existential
$LayeredCache<Value>
$LayeredCache<τ_0_0>
Verifying instruction:
%17 = copy_value %15 : $LayeredCache<Value> // user: %18
-> %18 = init_existential_ref %17 : $LayeredCache<Value> : $LayeredCache<τ_0_0>, $any Actor // user: %19
%19 = enum $Optional<any Actor>, #Optional.some!enumelt, %18 : $any Actor // user: %20
In function:
// LayeredCache.releaseLock(forKey:afterBackgroundTask:)
sil private [ossa] @$s13ARCFoundation12LayeredCacheC11releaseLock33_C01C6992E4474F9A4084CAA2F158DB96LL6forKey19afterBackgroundTaskySS_yyYactF : $@convention(method) <Value where Value : Sendable> (@guaranteed String, @guaranteed @async @callee_guaranteed () -> (), @sil_isolated @guaranteed LayeredCache<Value>) -> () {
// %0 "key" // users: %16, %3
// %1 "block" // users: %14, %4
// %2 "self" // users: %15, %5
bb0(%0 : @guaranteed $String, %1 : @guaranteed $@async @callee_guaranteed () -> (), %2 : @guaranteed $LayeredCache<Value>):
debug_value %0 : $String, let, name "key", argno 1 // id: %3
debug_value %1 : $@async @callee_guaranteed () -> (), let, name "block", argno 2 // id: %4
debug_value %2 : $LayeredCache<Value>, let, name "self", argno 3, implicit // id: %5
%6 = metatype $@thin Task<(), Never>.Type // user: %23
%7 = alloc_stack $Optional<TaskPriority> // users: %24, %23, %12, %8
%8 = init_enum_data_addr %7 : $*Optional<TaskPriority>, #Optional.some!enumelt // user: %11
%9 = metatype $@thin TaskPriority.Type // user: %11
// function_ref static TaskPriority.background.getter
%10 = function_ref @$sScP10backgroundScPvgZ : $@convention(method) (@thin TaskPriority.Type) -> @out TaskPriority // user: %11
%11 = apply %10(%8, %9) : $@convention(method) (@thin TaskPriority.Type) -> @out TaskPriority
inject_enum_addr %7 : $*Optional<TaskPriority>, #Optional.some!enumelt // id: %12
// function_ref closure #1 in LayeredCache.releaseLock(forKey:afterBackgroundTask:)
%13 = function_ref @$s13ARCFoundation12LayeredCacheC11releaseLock33_C01C6992E4474F9A4084CAA2F158DB96LL6forKey19afterBackgroundTaskySS_yyYactFyyYaYbcfU_ : $@convention(thin) @Sendable @async <τ_0_0 where τ_0_0 : Sendable> (@guaranteed Optional<any Actor>, @guaranteed @async @callee_guaranteed () -> (), @sil_isolated @guaranteed LayeredCache<τ_0_0>, @guaranteed String) -> @out () // user: %20
%14 = copy_value %1 : $@async @callee_guaranteed () -> () // user: %20
%15 = copy_value %2 : $LayeredCache<Value> // users: %20, %17
%16 = copy_value %0 : $String // user: %20
%17 = copy_value %15 : $LayeredCache<Value> // user: %18
%18 = init_existential_ref %17 : $LayeredCache<Value> : $LayeredCache<τ_0_0>, $any Actor // user: %19
%19 = enum $Optional<any Actor>, #Optional.some!enumelt, %18 : $any Actor // user: %20
%20 = partial_apply [callee_guaranteed] [isolated_any] %13<Value>(%19, %14, %15, %16) : $@convention(thin) @Sendable @async <τ_0_0 where τ_0_0 : Sendable> (@guaranteed Optional<any Actor>, @guaranteed @async @callee_guaranteed () -> (), @sil_isolated @guaranteed LayeredCache<τ_0_0>, @guaranteed String) -> @out () // user: %21
%21 = convert_function %20 : $@isolated(any) @Sendable @async @callee_guaranteed () -> @out () to $@isolated(any) @Sendable @async @callee_guaranteed @substituted <τ_0_0> () -> @out τ_0_0 for <()> // user: %23
// function_ref Task<>.init(priority:operation:)
%22 = function_ref @$sScTss5NeverORs_rlE8priority9operationScTyxABGScPSg_xyYaYbYAcntcfC : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Sendable, τ_0_1 == Never> (@in Optional<TaskPriority>, @owned @isolated(any) @Sendable @async @callee_guaranteed @substituted <τ_0_0> () -> @out τ_0_0 for <τ_0_0>, @thin Task<τ_0_0, Never>.Type) -> @owned Task<τ_0_0, Never> // user: %23
%23 = apply %22<(), Never>(%7, %21, %6) : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Sendable, τ_0_1 == Never> (@in Optional<TaskPriority>, @owned @isolated(any) @Sendable @async @callee_guaranteed @substituted <τ_0_0> () -> @out τ_0_0 for <τ_0_0>, @thin Task<τ_0_0, Never>.Type) -> @owned Task<τ_0_0, Never> // user: %25
dealloc_stack %7 : $*Optional<TaskPriority> // id: %24
destroy_value %23 : $Task<(), Never> // id: %25
%26 = tuple () // user: %27
return %26 : $() // id: %27
} // end sil function '$s13ARCFoundation12LayeredCacheC11releaseLock33_C01C6992E4474F9A4084CAA2F158DB96LL6forKey19afterBackgroundTaskySS_yyYactF'
I don't have a reproduction test but based on my local experiments, this appears to be started at commit https://github.com/apple/swift/commit/a86b76a3e9ebe352e8d250927c211445ac692c26 https://github.com/apple/swift/pull/72325 (reverting it appears to make it go away):
Here's a reduced test:
>cat C:\Users\hiroshi\tmp\Test.swift
public actor WaitableEvent2 {
public func signal() async {
}
}
public final actor Test<Value: Sendable> {
private var locks: [String /* cache key */: WaitableEvent2] = [:]
private func releaseLock(forKey key: String) async {
guard let event = locks.removeValue(forKey: key) else {
return
}
await event.signal()
}
private func releaseLock(forKey key: String, afterBackgroundTask block: @escaping () async -> Void) {
Task(priority: .background) {
await block()
await releaseLock(forKey: key)
}
}
}
>"S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swiftc.exe" C:\Users\hiroshi\tmp\Test.swift
error: compile command failed due to exception 3 (use -v to see invocation)
SIL verification failed: init_existential_ref operand must be lowered to the right abstraction level for the existential
$Test<Value>
$Test<τ_0_0>
Verifying instruction:
%17 = copy_value %15 : $Test<Value> // user: %18
-> %18 = init_existential_ref %17 : $Test<Value> : $Test<τ_0_0>, $any Actor // user: %19
%19 = enum $Optional<any Actor>, #Optional.some!enumelt, %18 : $any Actor // user: %20
In function:
// Test.releaseLock(forKey:afterBackgroundTask:)
sil private [ossa] @$s4TestAAC11releaseLock33_FD30D9FC47D6AC50355EEC3A2CA8155CLL6forKey19afterBackgroundTaskySS_yyYactF : $@convention(method) <Value where Value : Sendable> (@guaranteed String, @guaranteed @async @callee_guaranteed () -> (), @sil_isolated @guaranteed Test<Value>) -> () {
// %0 "key" // users: %16, %3
// %1 "block" // users: %14, %4
// %2 "self" // users: %15, %5
bb0(%0 : @guaranteed $String, %1 : @guaranteed $@async @callee_guaranteed () -> (), %2 : @guaranteed $Test<Value>):
debug_value %0 : $String, let, name "key", argno 1 // id: %3
debug_value %1 : $@async @callee_guaranteed () -> (), let, name "block", argno 2 // id: %4
debug_value %2 : $Test<Value>, let, name "self", argno 3, implicit // id: %5
%6 = metatype $@thin Task<(), Never>.Type // user: %23
%7 = alloc_stack $Optional<TaskPriority> // users: %24, %23, %12, %8
%8 = init_enum_data_addr %7 : $*Optional<TaskPriority>, #Optional.some!enumelt // user: %11
%9 = metatype $@thin TaskPriority.Type // user: %11
// function_ref static TaskPriority.background.getter
%10 = function_ref @$sScP10backgroundScPvgZ : $@convention(method) (@thin TaskPriority.Type) -> @out TaskPriority // user: %11
%11 = apply %10(%8, %9) : $@convention(method) (@thin TaskPriority.Type) -> @out TaskPriority
inject_enum_addr %7 : $*Optional<TaskPriority>, #Optional.some!enumelt // id: %12
// function_ref closure #1 in Test.releaseLock(forKey:afterBackgroundTask:)
%13 = function_ref @$s4TestAAC11releaseLock33_FD30D9FC47D6AC50355EEC3A2CA8155CLL6forKey19afterBackgroundTaskySS_yyYactFyyYaYbcfU_ : $@convention(thin) @Sendable @async <τ_0_0 where τ_0_0 : Sendable> (@guaranteed Optional<any Actor>, @guaranteed @async @callee_guaranteed () -> (), @sil_isolated @guaranteed Test<τ_0_0>, @guaranteed String) -> @out () // user: %20
%14 = copy_value %1 : $@async @callee_guaranteed () -> () // user: %20
%15 = copy_value %2 : $Test<Value> // users: %20, %17
%16 = copy_value %0 : $String // user: %20
%17 = copy_value %15 : $Test<Value> // user: %18
%18 = init_existential_ref %17 : $Test<Value> : $Test<τ_0_0>, $any Actor // user: %19
%19 = enum $Optional<any Actor>, #Optional.some!enumelt, %18 : $any Actor // user: %20
%20 = partial_apply [callee_guaranteed] [isolated_any] %13<Value>(%19, %14, %15, %16) : $@convention(thin) @Sendable @async <τ_0_0 where τ_0_0 : Sendable> (@guaranteed Optional<any Actor>, @guaranteed @async @callee_guaranteed () -> (), @sil_isolated @guaranteed Test<τ_0_0>, @guaranteed String) -> @out () // user: %21
%21 = convert_function %20 : $@isolated(any) @Sendable @async @callee_guaranteed () -> @out () to $@isolated(any) @Sendable @async @callee_guaranteed @substituted <τ_0_0> () -> @out τ_0_0 for <()> // user: %23
// function_ref Task<>.init(priority:operation:)
%22 = function_ref @$sScTss5NeverORs_rlE8priority9operationScTyxABGScPSg_xyYaYbYAcntcfC : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Sendable, τ_0_1 == Never> (@in Optional<TaskPriority>, @owned @isolated(any) @Sendable @async @callee_guaranteed @substituted <τ_0_0> () -> @out τ_0_0 for <τ_0_0>, @thin Task<τ_0_0, Never>.Type) -> @owned Task<τ_0_0, Never> // user: %23
%23 = apply %22<(), Never>(%7, %21, %6) : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Sendable, τ_0_1 == Never> (@in Optional<TaskPriority>, @owned @isolated(any) @Sendable @async @callee_guaranteed @substituted <τ_0_0> () -> @out τ_0_0 for <τ_0_0>, @thin Task<τ_0_0, Never>.Type) -> @owned Task<τ_0_0, Never> // user: %25
dealloc_stack %7 : $*Optional<TaskPriority> // id: %24
destroy_value %23 : $Task<(), Never> // id: %25
%26 = tuple () // user: %27
return %26 : $() // id: %27
} // end sil function '$s4TestAAC11releaseLock33_FD30D9FC47D6AC50355EEC3A2CA8155CLL6forKey19afterBackgroundTaskySS_yyYactF'
Please submit a bug report (https://swift.org/contributing/#reporting-bugs) and include the crash backtrace.
Stack dump:
0. Program arguments: "S:/Program Files/swift/Toolchains/0.0.0+Asserts/usr/bin/swift-frontend.exe" -frontend -c -primary-file C:\\Users\\hiroshi\\tmp\\Test.swift -target x86_64-unknown-windows-msvc -disable-objc-interop -sdk "S:\\Program Files\\Swift\\Platforms\\Windows.platform\\Developer\\SDKs\\Windows.sdk" -color-diagnostics -empty-abi-descriptor -resource-dir "S:\\Program Files\\swift\\Toolchains\\0.0.0+Asserts\\usr\\lib\\swift" -module-name Test -plugin-path "S:\\Program Files\\swift\\Toolchains\\0.0.0+Asserts\\usr\\bin" -plugin-path "S:\\Program Files\\swift\\Toolchains\\0.0.0+Asserts\\usr\\local\\bin" -o C:\\Users\\hiroshi\\AppData\\Local\\Temp\\TemporaryDirectory.6Na16N\\Test-1.o
1. Swift version 6.0-dev (LLVM c079606b0f5b8af, Swift 3b830bffb5aebae)
2. Compiling with effective version 5.10
3. While evaluating request ASTLoweringRequest(Lowering AST to SIL for file "C:\Users\hiroshi\tmp\Test.swift")
4. While silgen emitFunction SIL function "@$s4TestAAC11releaseLock33_FD30D9FC47D6AC50355EEC3A2CA8155CLL6forKey19afterBackgroundTaskySS_yyYactF".
for 'releaseLock(forKey:afterBackgroundTask:)' (at C:\Users\hiroshi\tmp\Test.swift:17:13)
5. While verifying SIL function "@$s4TestAAC11releaseLock33_FD30D9FC47D6AC50355EEC3A2CA8155CLL6forKey19afterBackgroundTaskySS_yyYactF".
for 'releaseLock(forKey:afterBackgroundTask:)' (at C:\Users\hiroshi\tmp\Test.swift:17:13)
Exception Code: 0x80000003
#0 0x00007ff7f655d175 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x739d175 (S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe+0x739d175)
#1 0x00007ff7f655d175
#2 0x00007ff7f655d175 (S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe+0x739d175)
#3 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x16db4dc S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x16e7c34
#4 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x1708f8b S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x170d54c
#5 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x170dc4b S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x16fdf99
#6 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xbf19ee S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xbe48cb
#7 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xbe79f9 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xbe3b65
#8 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xc34cd8 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xc2f02d
#9 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xc35118 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xbe7c97
#10 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xbe8424 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xbf30c6
#11 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xbddc02 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0xbf1721
#12 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x3beec1 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x3bd768
#13 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x3bdcde S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x3c022b
#14 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x2049eb S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x20458c
#15 0x00007ffcdf02e5f5 S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe 0x7413d68 (C:\Windows\System32\ucrtbase.dll+0x7e5f5)
#16 0x00007ffcdf02e5f5
#17 0x00007ffcdf02e5f5 (C:\Windows\System32\ucrtbase.dll+0x7e5f5)
0x00007FF7F655D175, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x739D175 byte(s), HandleAbort() + 0x5 byte(s)
0x00007FFCDF02E5F5, C:\Windows\System32\ucrtbase.dll(0x00007FFCDEFB0000) + 0x7E5F5 byte(s), raise() + 0x1E5 byte(s)
0x00007FFCDF02F601, C:\Windows\System32\ucrtbase.dll(0x00007FFCDEFB0000) + 0x7F601 byte(s), abort() + 0x31 byte(s)
0x00007FF7F089B4DC, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x16DB4DC byte(s), ?_Tidy@?$_Func_class@X$$V@std@@IEAAXXZ() + 0x60C byte(s)
0x00007FF7F08A7C34, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x16E7C34 byte(s), ?begin@?$SmallVectorTemplateCommon@PEAVSILInstruction@swift@@X@llvm@@QEAAPEAPEAVSILInstruction@swift@@XZ() + 0xC334 byte(s)
0x00007FF7F08C8F8B, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x1708F8B byte(s), ?verifySILUndefMap@SILFunction@swift@@QEBAXXZ() + 0x1A7B byte(s)
0x00007FF7F08CD54C, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x170D54C byte(s), ?verifySILUndefMap@SILFunction@swift@@QEBAXXZ() + 0x603C byte(s)
0x00007FF7F08CDC4B, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x170DC4B byte(s), ?verifySILUndefMap@SILFunction@swift@@QEBAXXZ() + 0x673B byte(s)
0x00007FF7F08BDF99, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x16FDF99 byte(s), ?verify@SILFunction@swift@@QEBAXPEAVCalleeCache@2@_N11@Z() + 0xD9 byte(s)
0x00007FF7EFDB19EE, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xBF19EE byte(s), ?postEmitFunction@SILGenModule@Lowering@swift@@QEAAXUSILDeclRef@3@PEAVSILFunction@3@@Z() + 0x10E byte(s)
0x00007FF7EFDA48CB, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xBE48CB byte(s), ?emitFunctionDefinition@SILGenModule@Lowering@swift@@QEAAXUSILDeclRef@3@PEAVSILFunction@3@@Z() + 0xD3B byte(s)
0x00007FF7EFDA79F9, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xBE79F9 byte(s), ?emitOrDelayFunction@SILGenModule@Lowering@swift@@QEAAXUSILDeclRef@3@@Z() + 0x299 byte(s)
0x00007FF7EFDA3B65, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xBE3B65 byte(s), ?emitFunction@SILGenModule@Lowering@swift@@QEAAXPEAVFuncDecl@3@@Z() + 0x165 byte(s)
0x00007FF7EFDF4CD8, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xC34CD8 byte(s), ?visitFuncDecl@SILGenExtension@@QEAAXPEAVFuncDecl@swift@@@Z() + 0x168 byte(s)
0x00007FF7EFDEF02D, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xC2F02D byte(s), ?emitSelfConformanceWitnessTable@SILGenModule@Lowering@swift@@QEAAXPEAVProtocolDecl@3@@Z() + 0x1FD byte(s)
0x00007FF7EFDF5118, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xC35118 byte(s), ?visitNominalTypeDecl@SILGenModule@Lowering@swift@@QEAAXPEAVNominalTypeDecl@3@@Z() + 0x18 byte(s)
0x00007FF7EFDA7C97, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xBE7C97 byte(s), ?emitPropertyWrapperBackingInitializer@SILGenModule@Lowering@swift@@QEAAXPEAVVarDecl@3@@Z() + 0x247 byte(s)
0x00007FF7EFDA8424, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xBE8424 byte(s), ?evaluate@ASTLoweringRequest@swift@@AEBA?AV?$unique_ptr@VSILModule@swift@@U?$default_delete@VSILModule@swift@@@std@@@std@@AEAVEvaluator@2@UASTLoweringDescriptor@2@@Z() + 0x284 byte(s)
0x00007FF7EFDB30C6, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xBF30C6 byte(s), ?evaluateRequest@?$SimpleRequest@VASTLoweringRequest@swift@@$$A6A?AV?$unique_ptr@VSILModule@swift@@U?$default_delete@VSILModule@swift@@@std@@@std@@UASTLoweringDescriptor@2@@Z$08@swift@@SA?AV?$unique_ptr@VSILModule@swift@@U?$default_delete@VSILModule@swift@@@std@@@std@@AEBVASTLoweringRequest@2@AEAVEvaluator@2@@Z() + 0x36 byte(s)
0x00007FF7EFD9DC02, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xBDDC02 byte(s), ??$getResultUncached@VASTLoweringRequest@swift@@V<lambda_1>@?1???$evaluateOrFatal@VASTLoweringRequest@swift@@@2@YA?AV?$unique_ptr@VSILModule@swift@@U?$default_delete@VSILModule@swift@@@std@@@std@@AEAVEvaluator@2@V12@@Z@@Evaluator@swift@@AEAA?AV?$unique_ptr@VSILModule@swift@@U?$default_delete@VSILModule@swift@@@std@@@std@@AEBVASTLoweringRequest@1@V<lambda_1>@?1???$evaluateOrFatal@VASTLoweringRequest@swift@@@1@YA?AV23@AEAV01@V41@@Z@@Z() + 0x212 byte(s)
0x00007FF7EFDB1721, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0xBF1721 byte(s), ?performASTLowering@swift@@YA?AV?$unique_ptr@VSILModule@swift@@U?$default_delete@VSILModule@swift@@@std@@@std@@AEAVFileUnit@1@AEAVTypeConverter@Lowering@1@AEBVSILOptions@1@PEBVIRGenOptions@1@@Z() + 0x101 byte(s)
0x00007FF7EF57EEC1, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x3BEEC1 byte(s), ?performCompileStepsPostSema@swift@@YA_NAEAVCompilerInstance@1@AEAHPEAVFrontendObserver@1@@Z() + 0x561 byte(s)
0x00007FF7EF57D768, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x3BD768 byte(s), ?pbackfail@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAAHH@Z() + 0x508 byte(s)
0x00007FF7EF57DCDE, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x3BDCDE byte(s), ?pbackfail@?$basic_stringbuf@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@MEAAHH@Z() + 0xA7E byte(s)
0x00007FF7EF58022B, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x3C022B byte(s), ?performFrontend@swift@@YAHV?$ArrayRef@PEBD@llvm@@PEBDPEAXPEAVFrontendObserver@1@@Z() + 0x9DB byte(s)
0x00007FF7EF3C49EB, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x2049EB byte(s), ?push_back@?$SmallVectorTemplateBase@PEBD$00@llvm@@QEAAXPEBD@Z() + 0x15B byte(s)
0x00007FF7EF3C458C, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x20458C byte(s), ?mainEntry@swift@@YAHHPEAPEBD@Z() + 0xE3C byte(s)
0x00007FF7F65D3D68, S:\Program Files\swift\Toolchains\0.0.0+Asserts\usr\bin\swift-frontend.exe(0x00007FF7EF1C0000) + 0x7413D68 byte(s), __scrt_common_main_seh() + 0x10C byte(s), D:\a\_work\1\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl, line 288 + 0x22 byte(s)
0x00007FFCE0B0257D, C:\Windows\System32\KERNEL32.DLL(0x00007FFCE0AF0000) + 0x1257D byte(s), BaseThreadInitThunk() + 0x1D byte(s)
0x00007FFCE1C4AA58, C:\Windows\SYSTEM32\ntdll.dll(0x00007FFCE1BF0000) + 0x5AA58 byte(s), RtlUserThreadStart() + 0x28 byte(s)
With https://github.com/apple/swift/commit/a86b76a3e9ebe352e8d250927c211445ac692c26 locally reverted, the crash seems to disappear.
This was probably fixed by #72575; can you verify?
@rjmccall Yes it seems to fix the issue I get. Thanks!
My issue is fixed but I'll leave this issue open for @MahdiBM to verify
Thanks @hjyamauchi . It can take another 2 weeks or so considering I'm on vacation in a place with improper internet connection.
I can confirm this is resolved on the latest nightly main images.
Description
Compilation fails with a SIL crash on nightlies, asking for a bug report.
Reproduction
Stack dump
Expected behavior
No crash.
Environment
swiftlang/swift:nightly-main-jammy@sha256:6f58d9db1f633a480c93668bc5f0b94175fdb1189241fd72e5589f6707098b68
image.Additional information
No response