Open swift-ci opened 5 years ago
Issue Description:
Trying to build Carthage on current master (I'm specifically using 55e416a):
master
SWIFTPM_BOOTSTRAP=true make test
and getting:
swift build --skip-update --build-tests -Xswiftc -suppress-warnings -Xswiftc -Xcc -Xswiftc -fmodule-map-file=/Users/me/pathtorepo/Carthage/`find .build/checkouts -name "swift-llbuild.git*"`/products/libllbuild/include/module.modulemap <unknown>:0: error: fatal error encountered during compilation; please file a bug report with your project and the crash log <unknown>:0: note: Type variable id overflow Stack dump: 0. Program arguments: /Applications/Xcode-11.0-b6.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift -frontend -c /Users/me/pathtorepo/Carthage/Source/carthage/Archive.swift /Users/me/pathtorepo/Carthage/Source/carthage/Bootstrap.swift /Users/me/pathtorepo/Carthage/Source/carthage/Build.swift /Users/me/pathtorepo/Carthage/Source/carthage/Checkout.swift /Users/me/pathtorepo/Carthage/Source/carthage/CopyFrameworks.swift /Users/me/pathtorepo/Carthage/Source/carthage/Environment.swift /Users/me/pathtorepo/Carthage/Source/carthage/Extensions.swift /Users/me/pathtorepo/Carthage/Source/carthage/Fetch.swift /Users/me/pathtorepo/Carthage/Source/carthage/Formatting.swift /Users/me/pathtorepo/Carthage/Source/carthage/Outdated.swift /Users/me/pathtorepo/Carthage/Source/carthage/RemoteVersion.swift -primary-file /Users/me/pathtorepo/Carthage/Source/carthage/Update.swift /Users/me/pathtorepo/Carthage/Source/carthage/Validate.swift /Users/me/pathtorepo/Carthage/Source/carthage/Version.swift /Users/me/pathtorepo/Carthage/Source/carthage/main.swift -emit-module-path /Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/carthage.build/Update~partial.swiftmodule -emit-module-doc-path /Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/carthage.build/Update~partial.swiftdoc -emit-dependencies-path /Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/carthage.build/Update.d -emit-reference-dependencies-path /Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/carthage.build/Update.swiftdeps -target x86_64-apple-macosx10.10 -enable-objc-interop -sdk /Applications/Xcode-11.0-b6.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -I /Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug -I /Users/me/pathtorepo/Carthage/.build/checkouts/swift-llbuild.git--7961110096062541192/products/libllbuild/include -I /Users/me/pathtorepo/Carthage/.build/checkouts/swift-llbuild.git--7961110096062541192/lib/BuildSystem/include -I /Users/me/pathtorepo/Carthage/.build/checkouts/swift-llbuild.git--7961110096062541192/lib/Core/include -I /Users/me/pathtorepo/Carthage/.build/checkouts/swift-llbuild.git--7961110096062541192/lib/Basic/include -I /Users/me/pathtorepo/Carthage/.build/checkouts/swift-llbuild.git--7961110096062541192/lib/llvm/Support/include -I /Users/me/pathtorepo/Carthage/.build/checkouts/swift-llbuild.git--7961110096062541192/lib/llvm/Demangle/include -I /Users/me/pathtorepo/Carthage/.build/checkouts/swift-package-manager.git-4482211070731168504/Sources/clibc/include -F /Applications/Xcode-11.0-b6.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks -enable-testing -g -module-cache-path /Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/ModuleCache -suppress-warnings -swift-version 4.2 -Onone -D SWIFT_PACKAGE -D DEBUG -color-diagnostics -enable-anonymous-context-mangled-names -Xcc -fmodule-map-file=/Users/me/pathtorepo/Carthage/.build/checkouts/swift-llbuild.git--7961110096062541192/products/libllbuild/include/module.modulemap -Xcc -fmodule-map-file=/Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/llbuildBuildSystem.build/module.modulemap -Xcc -fmodule-map-file=/Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/llbuildCore.build/module.modulemap -Xcc -fmodule-map-file=/Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/llbuildBasic.build/module.modulemap -Xcc -fmodule-map-file=/Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/llvmSupport.build/module.modulemap -Xcc -fmodule-map-file=/Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/llvmDemangle.build/module.modulemap -Xcc -fmodule-map-file=/Users/me/pathtorepo/Carthage/.build/checkouts/swift-package-manager.git-4482211070731168504/Sources/clibc/include/module.modulemap -Xcc -fmodule-map-file=/Users/me/pathtorepo/Carthage/.build/checkouts/swift-llbuild.git--7961110096062541192/products/libllbuild/include/module.modulemap -module-name carthage -o /Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/carthage.build/Update.swift.o -index-store-path /Users/me/pathtorepo/Carthage/.build/x86_64-apple-macosx/debug/index/store -index-system-modules 1. While type-checking 'evaluate(_:)' (at /Users/me/pathtorepo/Carthage/Source/carthage/Update.swift:64:10) 2. While type-checking statement at [/Users/me/pathtorepo/Carthage/Source/carthage/Update.swift:64:103 - line:77:3] RangeText="{ let buildDescription = "skip the building of dependencies after updating\n(ignored if --no-checkout option is present)" let dependenciesUsage = "the dependency names to update, checkout and build" return curry(Options.init) <*> mode <| Option(key: "checkout", defaultValue: true, usage: "skip the checking out of dependencies after updating") <*> mode <| Option(key: "build", defaultValue: true, usage: buildDescription) <*> mode <| Option(key: "verbose", defaultValue: false, usage: "print xcodebuild output inline (ignored if --no-build option is present)") <*> mode <| Option(key: "log-path", defaultValue: nil, usage: "path to the xcode build output. A temporary file is used by default") <*> mode <| Option(key: "new-resolver", defaultValue: false, usage: "use the new resolver codeline when calculating dependencies. Default is false") <*> BuildOptions.evaluate(mode, addendum: "\n(ignored if --no-build option is present)") <*> CheckoutCommand.Options.evaluate(mode, dependenciesUsage: dependenciesUsage) " 3. While type-checking statement at [/Users/me/pathtorepo/Carthage/Source/carthage/Update.swift:69:4 - line:76:84] RangeText="return curry(Options.init) <*> mode <| Option(key: "checkout", defaultValue: true, usage: "skip the checking out of dependencies after updating") <*> mode <| Option(key: "build", defaultValue: true, usage: buildDescription) <*> mode <| Option(key: "verbose", defaultValue: false, usage: "print xcodebuild output inline (ignored if --no-build option is present)") <*> mode <| Option(key: "log-path", defaultValue: nil, usage: "path to the xcode build output. A temporary file is used by default") <*> mode <| Option(key: "new-resolver", defaultValue: false, usage: "use the new resolver codeline when calculating dependencies. Default is false") <*> BuildOptions.evaluate(mode, addendum: "\n(ignored if --no-build option is present)") <*> CheckoutCommand.Options.evaluate(mode, dependenciesUsage: dependenciesUsage" 4. While type-checking expression at [/Users/me/pathtorepo/Carthage/Source/carthage/Update.swift:69:11 - line:76:84] RangeText="curry(Options.init) <*> mode <| Option(key: "checkout", defaultValue: true, usage: "skip the checking out of dependencies after updating") <*> mode <| Option(key: "build", defaultValue: true, usage: buildDescription) <*> mode <| Option(key: "verbose", defaultValue: false, usage: "print xcodebuild output inline (ignored if --no-build option is present)") <*> mode <| Option(key: "log-path", defaultValue: nil, usage: "path to the xcode build output. A temporary file is used by default") <*> mode <| Option(key: "new-resolver", defaultValue: false, usage: "use the new resolver codeline when calculating dependencies. Default is false") <*> BuildOptions.evaluate(mode, addendum: "\n(ignored if --no-build option is present)") <*> CheckoutCommand.Options.evaluate(mode, dependenciesUsage: dependenciesUsage" 0 swift 0x000000010560b013 PrintStackTraceSignalHandler(void*) + 51 1 swift 0x000000010560a7e6 SignalHandler(int) + 358 2 libsystem_platform.dylib 0x00007fff5f094b5d _sigtramp + 29 3 libsystem_platform.dylib 0x000000010ca49b76 _sigtramp + 2912636982 4 libsystem_c.dylib 0x00007fff5ef4e6a6 abort + 127 5 swift 0x00000001012594f0 std::__1::unique_ptr<swift::DiagnosticConsumer, std::__1::default_delete<swift::DiagnosticConsumer> > llvm::function_ref<std::__1::unique_ptr<swift::DiagnosticConsumer, std::__1::default_delete<swift::DiagnosticConsumer> > (swift::InputFile const&)>::callback_fn<createSerializedDiagnosticConsumerIfNeeded(swift::FrontendInputsAndOutputs const&)::$_15>(long, swift::InputFile const&) + 0 6 swift 0x0000000105584236 llvm::report_fatal_error(llvm::Twine const&, bool) + 278 7 swift 0x000000010558411b llvm::report_fatal_error(char const*, bool) + 43 8 swift 0x0000000101c94848 swift::constraints::ConstraintSystem::createTypeVariable(swift::constraints::ConstraintLocator*, unsigned int) + 408 9 swift 0x0000000101cfb71c swift::constraints::ConstraintSystem::openGeneric(swift::DeclContext*, swift::DeclContext*, swift::GenericSignature*, bool, swift::constraints::ConstraintLocatorBuilder, llvm::DenseMap<swift::GenericTypeParamType*, swift::TypeVariableType*, llvm::DenseMapInfo<swift::GenericTypeParamType*>, llvm::detail::DenseMapPair<swift::GenericTypeParamType*, swift::TypeVariableType*> >&, bool) + 412 10 swift 0x0000000101cfc666 swift::constraints::ConstraintSystem::openFunctionType(swift::AnyFunctionType*, unsigned int, swift::constraints::ConstraintLocatorBuilder, llvm::DenseMap<swift::GenericTypeParamType*, swift::TypeVariableType*, llvm::DenseMapInfo<swift::GenericTypeParamType*>, llvm::detail::DenseMapPair<swift::GenericTypeParamType*, swift::TypeVariableType*> >&, swift::DeclContext*, swift::DeclContext*, bool, bool) + 182 11 swift 0x0000000101cfd9b9 swift::constraints::ConstraintSystem::getTypeOfReference(swift::ValueDecl*, swift::FunctionRefKind, swift::constraints::ConstraintLocatorBuilder, swift::DeclContext*) + 1097 12 swift 0x0000000101d00242 swift::constraints::ConstraintSystem::resolveOverload(swift::constraints::ConstraintLocator*, swift::Type, swift::constraints::OverloadChoice, swift::DeclContext*) + 802 13 swift 0x0000000101c93af4 swift::constraints::ConstraintSystem::simplifyConstraint(swift::constraints::Constraint const&) + 804 14 swift 0x0000000101c94179 swift::constraints::ConstraintSystem::simplifyDisjunctionChoice(swift::constraints::Constraint*) + 25 15 swift 0x0000000101cb05f9 swift::constraints::DisjunctionStep::attempt(swift::constraints::DisjunctionChoice const&) + 185 16 swift 0x0000000101cafe43 swift::constraints::BindingStep<swift::constraints::DisjunctionChoiceProducer>::take(bool) + 595 17 swift 0x0000000101c9af44 swift::constraints::ConstraintSystem::solve(llvm::SmallVectorImpl<swift::constraints::Solution>&) + 276 18 swift 0x0000000101c9ffc4 swift::constraints::ConstraintSystem::solve(swift::Expr*, llvm::SmallVectorImpl<swift::constraints::Solution>&, swift::FreeTypeVariableBinding) + 52 19 swift 0x0000000101c9f816 swift::constraints::ConstraintSystem::solve(swift::Expr*&, swift::Type, swift::ExprTypeCheckListener*, llvm::SmallVectorImpl<swift::constraints::Solution>&, swift::FreeTypeVariableBinding) + 9238 20 swift 0x0000000101d98362 swift::TypeChecker::typeCheckExpressionImpl(swift::Expr*&, swift::DeclContext*, swift::TypeLoc, swift::ContextualTypePurpose, swift::OptionSet<swift::TypeCheckExprFlags, unsigned int>, swift::ExprTypeCheckListener&, swift::constraints::ConstraintSystem*) + 1042 21 swift 0x0000000101e49bb6 swift::ASTVisitor<(anonymous namespace)::StmtChecker, void, swift::Stmt*, void, void, void, void>::visit(swift::Stmt*) + 20678 22 swift 0x0000000101e4ad51 bool (anonymous namespace)::StmtChecker::typeCheckStmt<swift::Stmt>(swift::Stmt*&) + 129 23 swift 0x0000000101e4a7e3 swift::ASTVisitor<(anonymous namespace)::StmtChecker, void, swift::Stmt*, void, void, void, void>::visit(swift::Stmt*) + 23795 24 swift 0x0000000101e44a91 bool (anonymous namespace)::StmtChecker::typeCheckStmt<swift::BraceStmt>(swift::BraceStmt*&) + 129 25 swift 0x0000000101e44590 swift::TypeChecker::typeCheckAbstractFunctionBodyUntil(swift::AbstractFunctionDecl*, swift::SourceLoc) + 5456 26 swift 0x0000000101e4c6f1 swift::TypeChecker::typeCheckAbstractFunctionBody(swift::AbstractFunctionDecl*) + 561 27 swift 0x0000000101e691c2 swift::performTypeChecking(swift::SourceFile&, swift::TopLevelContext&, swift::OptionSet<swift::TypeCheckingFlags, unsigned int>, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int) + 2082 28 swift 0x000000010156574b swift::CompilerInstance::parseAndCheckTypesUpTo(swift::CompilerInstance::ImplicitImports const&, swift::SourceFile::ASTStage_t)::$_0::operator()(swift::SourceFile&) const + 91 29 swift 0x00000001015644ab swift::CompilerInstance::performSemaUpTo(swift::SourceFile::ASTStage_t) + 5371 30 swift 0x0000000101259d2f performCompile(swift::CompilerInstance&, swift::CompilerInvocation&, llvm::ArrayRef<char const*>, int&, swift::FrontendObserver*, swift::UnifiedStatsReporter*) + 815 31 swift 0x00000001012561f4 swift::performFrontend(llvm::ArrayRef<char const*>, char const*, void*, swift::FrontendObserver*) + 6820 32 swift 0x00000001011e3763 main + 1219 33 libdyld.dylib 0x00007fff5eea93d5 start + 1 make: *** [test] Error 1
This issue is being tracked in Carthage and there is a workaround that can be put in place, but this is still a bug.
@swift-ci create
Environment
swift --version Apple Swift version 5.1 (swiftlang-1100.0.270.6 clang-1100.0.32.1) Target: x86_64-apple-darwin18.6.0 sw_vers ProductName: Mac OS X ProductVersion: 10.14.5 BuildVersion: 18F132Additional Detail from JIRA
| | | |------------------|-----------------| |Votes | 0 | |Component/s | Compiler | |Labels | Bug, 5.1Regression, CompilerCrash, TypeChecker | |Assignee | felias (JIRA) | |Priority | Medium | md5: d27079ffdc553b18f66230f31b6a3277Issue Description:
Trying to build Carthage on current
master
(I'm specifically using 55e416a):SWIFTPM_BOOTSTRAP=true make test
and getting:
This issue is being tracked in Carthage and there is a workaround that can be put in place, but this is still a bug.