-
Notifications
You must be signed in to change notification settings - Fork 10.6k
Closed
Labels
FrontendArea → compiler: FrontendArea → compiler: FrontendSILGenArea → compiler: The SIL generation stageArea → compiler: The SIL generation stageassertion failureBug → crash: An assertion failureBug → crash: An assertion failurebugA deviation from expected or documented behavior. Also: expected but undesirable behavior.A deviation from expected or documented behavior. Also: expected but undesirable behavior.crashBug: A crash, i.e., an abnormal termination of softwareBug: A crash, i.e., an abnormal termination of softwaresource compatibility suiteFlag: An issue that surfaced in the source compatibility suiteFlag: An issue that surfaced in the source compatibility suiteswift 6.0
Description
Description
BricBrac & Kitura are failing to build due to an assertion error
error: compile command failed due to signal 6 (use -v to see invocation)
Assertion failed: (index < getNumSILArguments()), function getSILArgumentConvention, file SILArgument.cpp, line 89.
Please submit a bug report (https://swift.org/contributing/#reporting-bugs) and include the crash backtrace.
Stack dump:
0. Program arguments: <Ommited>
system-modules
1. Apple Swift version 5.11-dev (LLVM 26ea15ae72ba6e9, Swift 29acda513617147)
2. Compiling with effective version 4.1.50
3. While evaluating request ASTLoweringRequest(Lowering AST to SIL for file "swift-source-compat-suite/project_cache/Kitura/Tests/KituraTests/TestRequests.swift")
4. While silgen emitFunction SIL function "@$s11KituraTests12TestRequestsC17testParameterExityyF".
for 'testParameterExit()' (at swift-source-compat-suite/project_cache/Kitura/Tests/KituraTests/TestRequests.swift:369:5)
5. While silgen closureexpr SIL function "@$s11KituraTests12TestRequestsC17testParameterExityyFy0A013RouterRequestC_AE0H8ResponseCSSyyctKcfU_".
for expression at [swift-source-compat-suite/project_cache/Kitura/Tests/KituraTests/TestRequests.swift:372:32 - line:383:9] RangeText="{ request, response, value, next in
XCTAssertNotNil(value)
XCTAssertEqual(request.parameters["id"], value)
guard Int(value) != nil else {
try response.status(.notAcceptable).end()
return
}
response.headers["User-Id"] = value
next()
"
Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH or set the environment var `LLVM_SYMBOLIZER_PATH` to point to it):
0 swift-frontend 0x00000001160ee517 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) + 39
1 swift-frontend 0x00000001160ec698 llvm::sys::RunSignalHandlers() + 248
2 swift-frontend 0x00000001160eebc0 SignalHandler(int) + 288
3 libsystem_platform.dylib 0x00007ff80de7bdfd _sigtramp + 29
4 swift-frontend 0x000000011160af65 llvm::hash_code llvm::hashing::detail::hash_combine_recursive_helper::combine<std::__1::tuple<swift::AbstractFunctionDecl*>>(unsigned long, char*, char*, std::__1::tuple<swift::AbstractFunctionDecl*> const&) + 149
5 libsystem_c.dylib 0x00007ff80ddb1d24 abort + 123
6 libsystem_c.dylib 0x00007ff80ddb10cb err + 0
7 swift-frontend 0x00000001164c0701 swift::SILFunctionConventions::getSILArgumentConvention(unsigned int) const (.cold.8) + 33
8 swift-frontend 0x0000000110daf56e swift::SILFunctionConventions::getSILArgumentConvention(unsigned int) const + 446
9 swift-frontend 0x0000000110db1834 swift::SILBasicBlock::createFunctionArgument(swift::SILType, swift::ValueDecl const*, bool) + 148
10 swift-frontend 0x0000000110615f44 createInputFunctionArgument(swift::Lowering::SILGenBuilder&, swift::SILType, swift::SILLocation, swift::ValueDecl*, bool, swift::LifetimeAnnotation, bool, bool) + 100
11 swift-frontend 0x0000000110615ec6 swift::Lowering::SILGenBuilder::createInputFunctionArgument(swift::SILType, swift::ValueDecl*, bool, swift::LifetimeAnnotation, bool, bool) + 86
12 swift-frontend 0x00000001106cdc51 (anonymous namespace)::LoweredParamGenerator::claimNext() + 241
13 swift-frontend 0x00000001106d01ea swift::CanTypeVisitor<(anonymous namespace)::EmitBBArguments, swift::Lowering::ManagedValue, swift::Lowering::AbstractionPattern, swift::Lowering::Initialization*>::visit(swift::CanType, swift::Lowering::AbstractionPattern, swift::Lowering::Initialization*) + 3338
14 swift-frontend 0x00000001106ce361 (anonymous namespace)::ArgumentInitHelper::makeArgument(swift::SILLocation, swift::ParamDecl*) + 1633
15 swift-frontend 0x00000001106cc781 (anonymous namespace)::ArgumentInitHelper::emitParam(swift::ParamDecl*) + 273
16 swift-frontend 0x00000001106ca97c swift::Lowering::SILGenFunction::emitBasicProlog(swift::DeclContext*, swift::ParameterList*, swift::ParamDecl*, swift::Type, std::__1::optional<swift::Type>, swift::SourceLoc, unsigned int, std::__1::optional<swift::Lowering::AbstractionPattern>) + 2124
17 swift-frontend 0x00000001106c86e5 swift::Lowering::SILGenFunction::emitProlog(swift::DeclContext*, swift::CaptureInfo, swift::ParameterList*, swift::ParamDecl*, swift::Type, std::__1::optional<swift::Type>, swift::SourceLoc, std::__1::optional<swift::Lowering::AbstractionPattern>) + 133
18 swift-frontend 0x000000011066e096 swift::Lowering::SILGenFunction::emitClosure(swift::AbstractClosureExpr*) + 454
19 swift-frontend 0x00000001105d8925 swift::Lowering::SILGenModule::emitFunctionDefinition(swift::SILDeclRef, swift::SILFunction*) + 2965
20 swift-frontend 0x00000001105dbe63 swift::Lowering::SILGenModule::emitClosure(swift::AbstractClosureExpr*) + 163
21 swift-frontend 0x0000000110661e55 (anonymous namespace)::RValueEmitter::visitAbstractClosureExpr(swift::AbstractClosureExpr*, swift::Lowering::SGFContext) + 325
22 swift-frontend 0x00000001106516a3 swift::ASTVisitor<(anonymous namespace)::RValueEmitter, swift::Lowering::RValue, void, void, void, void, void, swift::Lowering::SGFContext>::visit(swift::Expr*, swift::Lowering::SGFContext) + 227
23 swift-frontend 0x0000000110647fdc swift::Lowering::SILGenFunction::emitRValueAsSingleValue(swift::Expr*, swift::Lowering::SGFContext) + 60
24 swift-frontend 0x000000011062d657 swift::Lowering::SILGenFunction::emitConvertedRValue(swift::SILLocation, swift::Lowering::Conversion const&, swift::Lowering::SGFContext, llvm::function_ref<swift::Lowering::ManagedValue (swift::Lowering::SILGenFunction&, swift::SILLocation, swift::Lowering::SGFContext)>) + 311
25 swift-frontend 0x00000001105c06e0 swift::Lowering::ArgumentSource::getConverted(swift::Lowering::SILGenFunction&, swift::Lowering::Conversion const&, swift::Lowering::SGFContext) && + 160
26 swift-frontend 0x00000001105c0e47 swift::Lowering::ArgumentSource::forwardInto(swift::Lowering::SILGenFunction&, swift::Lowering::AbstractionPattern, swift::Lowering::Initialization*, swift::Lowering::TypeLowering const&) && + 407
27 swift-frontend 0x00000001106617e9 (anonymous namespace)::RValueEmitter::visitCollectionExpr(swift::CollectionExpr*, swift::Lowering::SGFContext) + 1097
28 swift-frontend 0x0000000110651689 swift::ASTVisitor<(anonymous namespace)::RValueEmitter, swift::Lowering::RValue, void, void, void, void, void, swift::Lowering::SGFContext>::visit(swift::Expr*, swift::Lowering::SGFContext) + 201
29 swift-frontend 0x0000000110647fdc swift::Lowering::SILGenFunction::emitRValueAsSingleValue(swift::Expr*, swift::Lowering::SGFContext) + 60
30 swift-frontend 0x00000001105f96b5 (anonymous namespace)::ArgEmitter::emit(swift::Lowering::ArgumentSource&&, swift::Lowering::AbstractionPattern, std::__1::optional<swift::AnyFunctionType::Param>) + 3349
31 swift-frontend 0x00000001105e8884 (anonymous namespace)::ArgEmitter::emitSingleArg(swift::Lowering::ArgumentSource&&, swift::Lowering::AbstractionPattern, std::__1::optional<swift::AnyFunctionType::Param>) + 548
32 swift-frontend 0x00000001105f82a7 (anonymous namespace)::ArgEmitter::emitPreparedArgs(swift::Lowering::PreparedArguments&&, swift::Lowering::AbstractionPattern) + 263
33 swift-frontend 0x0000000110604bdb (anonymous namespace)::CallSite::emit(swift::Lowering::SILGenFunction&, swift::Lowering::AbstractionPattern, swift::CanTypeWrapper<swift::SILFunctionType>, (anonymous namespace)::ParamLowering&, llvm::SmallVectorImpl<swift::Lowering::ManagedValue>&, llvm::SmallVectorImpl<(anonymous namespace)::DelayedArgument>&, swift::ForeignInfo const&) && + 1067
34 swift-frontend 0x0000000110604334 (anonymous namespace)::CallEmission::emitArgumentsForNormalApply(swift::Lowering::AbstractionPattern, swift::CanTypeWrapper<swift::SILFunctionType>, swift::ForeignInfo const&, llvm::SmallVectorImpl<swift::Lowering::ManagedValue>&, std::__1::optional<swift::SILLocation>&) + 1476
35 swift-frontend 0x00000001105ec928 (anonymous namespace)::CallEmission::apply(swift::Lowering::SGFContext) + 1864
36 swift-frontend 0x00000001105ea876 swift::Lowering::SILGenFunction::emitApplyExpr(swift::ApplyExpr*, swift::Lowering::SGFContext) + 2214
37 swift-frontend 0x0000000110651673 swift::ASTVisitor<(anonymous namespace)::RValueEmitter, swift::Lowering::RValue, void, void, void, void, void, swift::Lowering::SGFContext>::visit(swift::Expr*, swift::Lowering::SGFContext) + 179
38 swift-frontend 0x00000001106484a6 swift::Lowering::SILGenFunction::emitIgnoredExpr(swift::Expr*) + 1142
39 swift-frontend 0x00000001106d3257 swift::ASTVisitor<(anonymous namespace)::StmtEmitter, void, void, void, void, void, void>::visit(swift::Stmt*) + 5639
40 swift-frontend 0x00000001106d1c45 swift::Lowering::SILGenFunction::emitStmt(swift::Stmt*) + 21
41 swift-frontend 0x000000011066de54 swift::Lowering::SILGenFunction::emitFunction(swift::FuncDecl*) + 580
42 swift-frontend 0x00000001105da696 swift::Lowering::SILGenModule::emitFunctionDefinition(swift::SILDeclRef, swift::SILFunction*) + 10502
43 swift-frontend 0x00000001105daf67 swift::Lowering::SILGenModule::emitOrDelayFunction(swift::SILDeclRef) + 231
44 swift-frontend 0x00000001105d7d71 swift::Lowering::SILGenModule::emitFunction(swift::FuncDecl*) + 193
45 swift-frontend 0x00000001106e5d15 (anonymous namespace)::SILGenType::visitFuncDecl(swift::FuncDecl*) + 21
46 swift-frontend 0x00000001106e2487 (anonymous namespace)::SILGenType::emitType() + 119
47 swift-frontend 0x00000001106e2409 swift::Lowering::SILGenModule::visitNominalTypeDecl(swift::NominalTypeDecl*) + 25
48 swift-frontend 0x00000001105ddc00 swift::ASTLoweringRequest::evaluate(swift::Evaluator&, swift::ASTLoweringDescriptor) const + 1344
49 swift-frontend 0x00000001106d1728 swift::SimpleRequest<swift::ASTLoweringRequest, std::__1::unique_ptr<swift::SILModule, std::__1::default_delete<swift::SILModule>> (swift::ASTLoweringDescriptor), (swift::RequestFlags)9>::evaluateRequest(swift::ASTLoweringRequest const&, swift::Evaluator&) + 120
50 swift-frontend 0x00000001105e0d82 llvm::Expected<swift::ASTLoweringRequest::OutputType> swift::Evaluator::getResultUncached<swift::ASTLoweringRequest>(swift::ASTLoweringRequest const&) + 402
51 swift-frontend 0x00000001105de7da swift::performASTLowering(swift::FileUnit&, swift::Lowering::TypeConverter&, swift::SILOptions const&, swift::IRGenOptions const*) + 106
52 swift-frontend 0x000000010ffb9970 swift::performCompileStepsPostSema(swift::CompilerInstance&, int&, swift::FrontendObserver*) + 640
53 swift-frontend 0x000000010ffbcee6 performCompile(swift::CompilerInstance&, int&, swift::FrontendObserver*) + 1014
54 swift-frontend 0x000000010ffbbc15 swift::performFrontend(llvm::ArrayRef<char const*>, char const*, void*, swift::FrontendObserver*) + 3365
55 swift-frontend 0x000000010fd97488 swift::mainEntry(int, char const**) + 2312
56 dyld 0x000000012396452e start + 462
This was introduced between
a94d22e (Projects build OK) && 0cc0df9 (Projects fail with assertion error)
https://ci.swift.org/job/swift-main-source-compat-suite/590/
Expected behavior
These projects should build fine
Environment
Apple Swift version 5.11-dev (LLVM 26ea15ae72ba6e9, Swift 29acda513617147)
Target: x86_64-apple-macosx10.13
Metadata
Metadata
Assignees
Labels
FrontendArea → compiler: FrontendArea → compiler: FrontendSILGenArea → compiler: The SIL generation stageArea → compiler: The SIL generation stageassertion failureBug → crash: An assertion failureBug → crash: An assertion failurebugA deviation from expected or documented behavior. Also: expected but undesirable behavior.A deviation from expected or documented behavior. Also: expected but undesirable behavior.crashBug: A crash, i.e., an abnormal termination of softwareBug: A crash, i.e., an abnormal termination of softwaresource compatibility suiteFlag: An issue that surfaced in the source compatibility suiteFlag: An issue that surfaced in the source compatibility suiteswift 6.0