Skip to content

Build IndexStore together with the host toolchain #1456

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

Closed
wants to merge 564 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
564 commits
Select commit Hold shift + click to select a range
e2a1862
[AutoDiff upstream] Add `inout` parameter differentiation tests. (#33…
dan-zheng Aug 20, 2020
cc19330
Codesign the Error binary before executing
shahmishal Aug 20, 2020
b8976a3
[SIL] Add flag to SILFunctionType::Profile for async.
nate-chandler Aug 20, 2020
fc34e4c
Merge pull request #33559 from nate-chandler/add-flag-to-SILFunctionT…
swift-ci Aug 20, 2020
5c4c4dc
Merge pull request #33558 from apple/fix-codesign-for-tests
shahmishal Aug 20, 2020
ecd6d4d
Add a new ConcurrentReadableHashMap type. Switch the protocol conform…
mikeash Jul 30, 2020
0f879c4
[CodeCompletion] Avoid prioritizing unavailable in LookupVisibleDecls
rintaro Aug 20, 2020
fc4ef19
[build-script] Add a default-enabled "clean" step for swift-driver an…
artemcm Aug 20, 2020
9ffddc9
[Function builders] Remove buildDo.
DougGregor Aug 20, 2020
1a90ecc
[Function builders] Remove test case residue.
DougGregor Aug 20, 2020
d46c4ec
[Function builders] Add support for 'throw' statement.
DougGregor Aug 20, 2020
e132171
[Test] Filter out a __rotate symbol and another __once_call symbol in…
mikeash Aug 20, 2020
29e655b
DependenciesScanner: implement protocol for batch module dependencies…
nkcsgexi Aug 20, 2020
316475c
Merge pull request #33564 from DougGregor/function-builders-remove-bu…
swift-ci Aug 20, 2020
1ecf062
Merge pull request #33556 from brentdax/how-forward-of-you
beccadax Aug 20, 2020
32e0305
[NFC] Add test for self-cycles in module trace.
varungandhi-apple Aug 20, 2020
6a6b1f8
DependenciesScanner: differentiate Swift and Clang module more explic…
nkcsgexi Aug 20, 2020
443e091
Merge pull request #33562 from rintaro/ide-completion-rdar67155695
rintaro Aug 20, 2020
260125e
[ModuleTrace] Early exit if a Clang module imports itself.
varungandhi-apple Aug 20, 2020
6c18a03
[NFC] Add ClangNode::dump()
beccadax Aug 20, 2020
28ea3e1
[NFC] Document TypeAliasDecl::isCompatibilityAlias
beccadax Aug 20, 2020
9d4281b
Support generic @compatibility_alias in PrintAsObjC
beccadax Aug 20, 2020
2f7e0d4
Revert "Revert "[Serialization] Serialize isUserAccessible on functio…
xymus Aug 18, 2020
256226d
[Serialization] Fix isUserAccessible serialization on functions only
xymus Aug 20, 2020
fd78da5
[ModuleInterface] Don't print extensions to implementation-only impor…
xymus Aug 20, 2020
d3b4094
Merge pull request #33566 from mikeash/fix-symbol-visibility-test
swift-ci Aug 21, 2020
7daed3c
Merge pull request #33570 from DougGregor/function-builders-throw
swift-ci Aug 21, 2020
6b07132
Merge pull request #33572 from varungandhi-apple/vg-fix-clang-module-…
varungandhi-apple Aug 21, 2020
3d61c21
[AutoDiff] Revert obsolete SIL undef hack. (#33571)
dan-zheng Aug 21, 2020
ec29edd
Sema: Pass substitution options to swift::checkTypeWitness
AnthonyLatsis Aug 21, 2020
5a1f38b
Merge pull request #33569 from nkcsgexi/batch-scanning-protocol
nkcsgexi Aug 21, 2020
13cf37a
Patch A Regression in Lookup for CodingKeys
CodaFi Aug 21, 2020
39d4e01
Merge pull request #33487 from mikeash/concurrenthashmap
mikeash Aug 21, 2020
f3045ff
DependenciesScanner: teach batch scanning mode to configure scanner u…
nkcsgexi Aug 21, 2020
828ab6d
Merge pull request #33573 from brentdax/how-forward-of-you-2-electric…
beccadax Aug 21, 2020
d7bf739
Merge pull request #33574 from xymus/serialize-user-accessible-take-2
xymus Aug 21, 2020
051f342
Merge pull request #33587 from nkcsgexi/use-arguments-batch-input
nkcsgexi Aug 21, 2020
bfe74f5
[ModuleInterface] Only skip extensions without public members
xymus Aug 21, 2020
94bf392
[CSGen] Abort constraint generation on error only if closure particip…
xedin Aug 21, 2020
7c508a0
Merge pull request #33582 from CodaFi/the-coding-keys-to-success
CodaFi Aug 21, 2020
83b2ebe
[AutoDiff] Support forward mode differentiation of functions with `in…
efremale Aug 22, 2020
6a7b38d
[SILGenPattern] Silence redundant unreachable enum case warning (#33336)
theblixguy Aug 22, 2020
0bd8b14
[AST] Fix declaration bitfields. (#33567)
dan-zheng Aug 22, 2020
af35936
[Runtime] Fix a race condition in ConcurrentReadableHashMap with conc…
mikeash Aug 22, 2020
9ce8250
Merge pull request #33595 from mikeash/fix-concurrenthashmap-clear-race
mikeash Aug 22, 2020
7aac681
[opt-remark] Handle inline locations correctly.
gottesmm Aug 19, 2020
8337f96
[Package] When building a toolchain, don't copy the Resource directory.
Aug 22, 2020
5d37354
Merge pull request #33597 from gottesmm/pr-d13e5a398f892c94f54a62e0c4…
gottesmm Aug 23, 2020
611d4b8
[gardening] PlaygroundSupport is a build-script product now... remove…
gottesmm Aug 23, 2020
ac64ad6
[opt-remark] Add remarks for alloc_box, alloc_ref, alloc_stack
gottesmm Jul 27, 2020
8094bd9
Merge pull request #33600 from gottesmm/pr-48cf564dc39db018424298742c…
swift-ci Aug 23, 2020
61e93c5
Merge pull request #33599 from gottesmm/pr-0a5fe73f7591074eb2e48781ce…
gottesmm Aug 23, 2020
303026b
Don't drop -DNDEBUG from CMAKE_CXX_FLAGS_RELEASE (#33565)
kubamracek Aug 23, 2020
35b4925
Add warning about spaces in the Xcode path.
Aug 24, 2020
84928c6
Fixes example snippet in Array.swift
valeriyvan Aug 24, 2020
faea5f0
Merge pull request #33563 from artemcm/CleanupDriverPM
artemcm Aug 24, 2020
fe0a945
AST: split out diagnostics serialization
compnerd Aug 23, 2020
b574795
Merge pull request #33608 from valeriyvan/Array-NSURL
swift-ci Aug 24, 2020
7fcc7ba
Fix JVPs for `Float` `*=` and `/=` (#33579)
efremale Aug 24, 2020
1fdcdce
Merge pull request #33575 from xymus/dont-print-ioi-extensions
xymus Aug 24, 2020
9bc2819
Merge pull request #33590 from xedin/fail-on-error-if-single-stmt
xedin Aug 24, 2020
7c5bb7d
Update the master-rebranch scheme to include:
shahmishal Aug 24, 2020
6467827
[Runtime] Fix memory ordering on two loads in ConcurrentReadableHashMap.
mikeash Aug 24, 2020
ead41b4
Merge pull request #33598 from dcci/for-fox-sake-is-a-great-album
dcci Aug 24, 2020
b9c899a
[Package] Fix passing -gline-tables-only when building.
Aug 24, 2020
bafa8be
Reworded warning.
Aug 24, 2020
e9b9b50
Jira link
Aug 24, 2020
a165250
Merge pull request #33613 from apple/shahmishal/add-support-rebranch-…
swift-ci Aug 24, 2020
beb3568
Merge pull request #33605 from compnerd/serialize-diagnostics
compnerd Aug 24, 2020
d71d92e
Merge pull request #31105 from valeriyvan/RemoveRedundantBufferZeroin…
Aug 24, 2020
a350fb7
Merge pull request #33615 from mikeash/fix-concurrenthashmap-memory-o…
swift-ci Aug 24, 2020
c9b3164
Correct the DeclContext Used For 'super.init()' Synthesis
CodaFi Aug 24, 2020
ce550f2
AST: Try harder to preserve type sugar in AbstractGenericSignatureReq…
slavapestov Aug 24, 2020
b0208a1
AST: Move getSugaredType() from GenericEnvironment to GenericSignature
slavapestov Aug 24, 2020
b93ee4c
AST: Remove some calls to getSugaredType() which are no longer necessary
slavapestov Aug 24, 2020
995eb66
AST: Rename SpecializeAttr::getSpecializedSgnature()
slavapestov Aug 24, 2020
a408fd3
Better paragraph
Aug 25, 2020
bbe1310
format
Aug 25, 2020
76da9a0
Use defined(_POSIX_THREADS) to detect pthread support (#33609)
kubamracek Aug 25, 2020
e3b7d5d
Merge pull request #33620 from CodaFi/a-look-alike
swift-ci Aug 25, 2020
68dcbca
Merge pull request #33581 from AnthonyLatsis/ripe-conformances/no-opt…
AnthonyLatsis Aug 25, 2020
5c88421
Update swift-argument-parser checkout to 0.3.0
owenv Jun 24, 2020
d5731c5
Merge pull request #33619 from slavapestov/fix-generic-requirements-i…
slavapestov Aug 25, 2020
e1d0ea2
Merge pull request #33616 from dcci/the-piper-at-the-gates-of-dawn
dcci Aug 25, 2020
5e3ef64
AST: Fix ASTScopeLookup crash if a PatternBindingEntry's context is n…
slavapestov Aug 25, 2020
8fbd449
Merge pull request #33114 from brentdax/check-your-interfaces-at-the-…
beccadax Aug 25, 2020
b4fb7d0
[IDE] Skip visiting constructor references when the decl is unknown
bnbarham Aug 25, 2020
b1c0bd3
Minor cleanup in ARCSequenceOpts (#33578)
meg-gupta Aug 25, 2020
9ead8d5
Add a single-threaded stdlib mode, use it for the 'minimal' stdlib (#…
kubamracek Aug 25, 2020
63a8463
Merge pull request #33593 from owenv/update-argparse
shahmishal Aug 25, 2020
dd9e1cf
[CS] Don't use TMF_GenerateConstraints in simplifyConstraint
hamishknight Aug 25, 2020
a5ca83a
Merge pull request #33607 from davidungar/readme-addition
Aug 25, 2020
6480bfa
[gardening] Move FuzzyStringMatcher to libIDE
benlangmuir Aug 12, 2020
34de805
[gardening] Move source text printing alongside other completion methods
benlangmuir Aug 25, 2020
cf87ad8
[gardening] Move filter name printing alongside other completion methods
benlangmuir Aug 25, 2020
af78895
[gardening] Sink compiler invocation code into libIDE
benlangmuir Aug 25, 2020
0d42d7d
[gardening] format changed code
benlangmuir Aug 25, 2020
24f1a46
Merge pull request #33624 from slavapestov/ast-scope-crash-with-patte…
slavapestov Aug 25, 2020
8178610
Move adjustClangTriple above its only caller
benlangmuir Aug 25, 2020
696c124
Fix missing dependency
benlangmuir Aug 25, 2020
6e6de51
[Sema] Improve diagnostics for use of self access kind modifier on ac…
theblixguy Aug 25, 2020
ee8ad7b
[AutoDiff] NFC: silence no-asserts unused variable warning. (#33629)
dan-zheng Aug 25, 2020
c5b42ac
Move FuzzyStringMatcherTest to IDE unittests
benlangmuir Aug 25, 2020
94b5f76
Revert "[SIL] Add SILFunctionType flag for async."
nate-chandler Aug 25, 2020
5d813f3
Revert "[SIL] Add flag to SILFunctionType::Profile for async."
nate-chandler Aug 25, 2020
78159c8
[Explicit Module Builds] Handle #canImport in the dependency scanner …
artemcm Aug 25, 2020
7815ecf
[CSApply] Handle OptionalForce component when is initial component on…
LucianoPAlmeida Aug 25, 2020
8c56ce8
Merge pull request #33632 from benlangmuir/gardening-libIDE
benlangmuir Aug 25, 2020
86c7857
Merge pull request #33625 from bnbarham/pass-reference-nullptr
bnbarham Aug 25, 2020
8f72547
[test] ABIChecker: add a test for -use-interface-for-module flag
nkcsgexi Aug 25, 2020
d82a767
SIL: Add a SILFunction::Purpose for global init once functions
jckarter Aug 25, 2020
f74a3b4
[SIL] Added async flag to SILExtInfo.
nate-chandler Aug 25, 2020
6d6165a
SILOptimizer: Recognize globalinit once functions using an attribute …
jckarter Aug 26, 2020
48a7bc9
Merge pull request #33631 from hamishknight/what-do-you-mean-youve-se…
hamishknight Aug 26, 2020
79b0a7e
[CSDiagnostics] Emit fix-its to insert requirement stubs for missing …
theblixguy Aug 26, 2020
97609dd
Merge pull request #33623 from LucianoPAlmeida/SR-13442-key-path-unwr…
LucianoPAlmeida Aug 26, 2020
148ba9d
Merge pull request #33636 from nate-chandler/move-flag-to-SILExtInfo
swift-ci Aug 26, 2020
e387b36
Merge pull request #33255 from kateinoigakukun/katei/fix-sib-xref-deinit
MaxDesiatov Aug 26, 2020
a53f363
[IRGen] NFC: Simplify IRGenModule::defineTypeMetadata
davezarzycki Aug 25, 2020
9962f79
[RemoteMirror] Fix potential uninitialized data access in convertChild.
mikeash Aug 26, 2020
bf5fb4d
[CodeCompletion] Don't update VFS content hash map after each completion
rintaro Aug 26, 2020
58604ff
[Runtime] Fix memory ordering on a store in ConcurrentReadableArray.
mikeash Aug 26, 2020
66e2ce6
Remove apparently unnecessary filter for CMO serializing references t…
jckarter Aug 26, 2020
59fe82a
Merge pull request #33638 from nkcsgexi/test-use-interface-for-module
nkcsgexi Aug 26, 2020
b37de4b
Merge pull request #32685 from compnerd/testing-the-future
shahmishal Aug 26, 2020
29c7216
DependenciesScanner: include search path options in PCM building comm…
nkcsgexi Aug 26, 2020
82e870b
build: remove the Python 2 check
compnerd Aug 26, 2020
c059fc2
Merge pull request #33642 from mikeash/fix-remotemirror-uninitialized…
mikeash Aug 26, 2020
0ade99f
Merge pull request #33646 from mikeash/fix-concurrentarray-memory-order
swift-ci Aug 26, 2020
9ee8cd2
Merge pull request #33645 from rintaro/ide-completion-rdar67773257
rintaro Aug 26, 2020
362a25a
[AST] Support SILFunctionType/SILBlockStorageType in ClangTypeConverter.
varungandhi-apple Jan 16, 2020
78ea3de
[AST] Introduce a new type to represent a type hole in constraint system
xedin Aug 26, 2020
48c9767
[CSApply] Make sure that hole type are not propagated to AST
xedin Aug 27, 2020
d039107
[ConstraintSystem] Replace use of `UnresolvedType` with specialized `…
xedin Aug 27, 2020
b4d3237
[CSDiagnostics] Adjust diagnostics to account that type holes in solu…
xedin Aug 27, 2020
d287963
[sil-mode] Change viewcfg integration to specify dot as a renderer.
gottesmm Aug 27, 2020
5b5e30b
Implement implicit member chains
Jumhyn Jul 31, 2020
1069fe2
Fixup diagnostics
Jumhyn Jul 31, 2020
3b5deab
More diagnostic improvements
Jumhyn Jul 31, 2020
788d3f0
Fix missing call diagnostic
Jumhyn Jul 31, 2020
aedde34
[Sema] Move unresolved base tracking into CSGen
Jumhyn Jul 31, 2020
4e9b7b2
[Sema] Inject implicit ParenExpr for unresolved member chains
Jumhyn Jul 31, 2020
f584566
[AST] Introduce UnresolvedMemberChainResultExpr
Jumhyn Jul 31, 2020
d78b59c
[Sema] Prefer LValueType during solution scoring
Jumhyn Aug 1, 2020
e0e3bab
[Sema] Change anchor of unresolved chain result type
Jumhyn Aug 3, 2020
4331e26
[Sema] Move UnresolvedMemberChainResultExpr creation to walkToExprPre
Jumhyn Aug 3, 2020
aade4aa
[Localization] Add new diagnostics to localization file
Jumhyn Aug 3, 2020
5394e6b
[Sema] Use getMetatypeInstanceType instead of casting to MetatypeType
Jumhyn Aug 3, 2020
c33ad11
[Sema] Apply clang-format
Jumhyn Aug 3, 2020
1e27f26
[Sema] Always cache the unresolved chain base
Jumhyn Aug 3, 2020
ed94131
[Sema] Bail out early of solution application for UME
Jumhyn Aug 4, 2020
26f0a80
[Sema] Transfer contextual type info when we inject UnresolvedMemberC…
Jumhyn Aug 4, 2020
74d0040
[Sema] Remove unnecessary impact adjustment
Jumhyn Aug 4, 2020
1892356
[Sema] Move member chain transformation into precheck
Jumhyn Aug 4, 2020
7b05352
[Sema] Improve invalid lvalue diagnostics for UnresolvedMemberExpr
Jumhyn Aug 5, 2020
0055501
[Sema] Add FIXME for Optional binding inference bug
Jumhyn Aug 6, 2020
5de23f5
[Sema] Rebase and address feedback for implicit member chains
Jumhyn Aug 12, 2020
968112e
[Sema] Support code completion for heterogeneous unresolved member ch…
Jumhyn Aug 17, 2020
db33dfa
[IDE] Offer unresolved member completions with non-matching types
Jumhyn Aug 21, 2020
352adc3
Remove Argument from UnresolvedMemberExpr
Jumhyn Aug 24, 2020
30e52be
[AST] Properly initialize FunctionRefKind for UnresolvedMemberExpr
Jumhyn Aug 27, 2020
d8878d2
[Tests] Add IUO tests for implicit member chains
Jumhyn Aug 27, 2020
b6c2f89
[AST] NFC: Fix a typo in the `HasTypeHole` description
xedin Aug 26, 2020
9de7b59
Subsume SWIFT_STDLIB_USE_NONATOMIC_RC into SWIFT_STDLIB_SINGLE_THREAD…
kubamracek Aug 27, 2020
8f2e53c
[AST] Make sure that hole types are always allocated in `ConstraintSo…
xedin Aug 27, 2020
b07ecb9
Merge pull request #33626 from davezarzycki/pr33626
davezarzycki Aug 27, 2020
8905f97
[Tests] Update completions for unresolved enum members
Jumhyn Aug 27, 2020
4cd1b71
[Runtime] Shrink ConcurrentReadableHashMap a bit.
mikeash Aug 26, 2020
1fec2b5
Respect SWIFT_STDLIB_SINGLE_THREADED_RUNTIME and use nonatomic refcou…
kubamracek Aug 27, 2020
102d638
[build] Don't execute dsymutil in parallel (#33654)
edymtt Aug 27, 2020
1a44db3
ABIChecker: exclude decls with the @_alwaysEmitIntoClient attribute
nkcsgexi Aug 27, 2020
524cfae
[Dynamic Casting] Overhauled Runtime (#33561)
tbkka Aug 27, 2020
33fe1ff
Merge pull request #33652 from nkcsgexi/67589328
nkcsgexi Aug 27, 2020
9993875
Merge pull request #33630 from artemcm/ScannerCanImport
artemcm Aug 27, 2020
9665091
[CSBindings] Don't attempt to join types that contain holes
xedin Aug 27, 2020
83b50cd
[AutoDiff] Add missing `withoutDerivative(at:)` fix-its. (#33660)
dan-zheng Aug 27, 2020
103b61c
ABIChecker: rename argument -protocol-requirement-white-list to -prot…
nkcsgexi Aug 27, 2020
80560da
CSGen: Infer generic arguments in explicit closure result types
AnthonyLatsis Aug 27, 2020
61d86d5
[NFC] CSGen: Clean up some flow in inferClosureType
AnthonyLatsis Aug 27, 2020
84c5065
[SR-13461] Relax An Assert
CodaFi Aug 27, 2020
ce2377d
Merge pull request #33651 from compnerd/complete
compnerd Aug 27, 2020
c890cdd
[AST] Add functionality for computing Clang types for SIL functions.
varungandhi-apple Jul 28, 2020
1807412
[Serialization] Allow different Clang types in deserialization.
varungandhi-apple Aug 18, 2020
eaac23f
[NFC] Remove ASTExtInfo::assertIsFunctionType in favor of checkInvari…
varungandhi-apple Aug 18, 2020
8da4d53
[NFC] Use ClangTypeInfo's implicit null state instead of an extra Opt…
varungandhi-apple Aug 18, 2020
eead4ae
[NFC] Remove unused function parameter.
varungandhi-apple Aug 18, 2020
eeec16f
[NFC] Remove redundant ExtInfo parameter for getBridgedFunctionType.
varungandhi-apple Aug 20, 2020
fdbcd12
[NFC] Bridge based on SILFunctionLanguage instead of Representation.
varungandhi-apple Aug 21, 2020
f86aad9
[NFC] Extract computation of SILExtInfoBuilder bits into new method.
varungandhi-apple Aug 21, 2020
c4ad840
[NFC] Reuse SILExtInfoBuilder's main constructor in default constructor.
varungandhi-apple Aug 21, 2020
863bca8
[Dependency Scanner] Prefix Clang dependency scanner search path argu…
artemcm Aug 27, 2020
4847ec9
[AST/TypeChecker] Add more asserts to make sure types don't get into AST
xedin Aug 27, 2020
41ea927
Merge pull request #33666 from nkcsgexi/67883661
nkcsgexi Aug 27, 2020
0bef4a6
Give global once symbols stabler manglings.
jckarter Aug 27, 2020
4b921c3
[Sema] Improve diagnostics for key path root type inferred as option …
LucianoPAlmeida Aug 23, 2020
4c7ccf5
[NFC] Clean Up FrontendTool
CodaFi Aug 25, 2020
fe7444f
Add doesActionRequireSwiftStandardLibrary
CodaFi Aug 27, 2020
4c56c95
Define doesActionRequireInputs
CodaFi Aug 27, 2020
e013ebd
[CodeCompletion] Ensure all ExtensionDecl's extended nominal are comp…
rintaro Aug 27, 2020
5faedbd
Merge pull request #33667 from nkcsgexi/allow-list-rename
nkcsgexi Aug 27, 2020
16876fb
[Clang importer] Drop unused parameter from getParamOptionality().
DougGregor Aug 24, 2020
12dd83d
Merge pull request #33670 from artemcm/ClangScannerPathPrefixes
artemcm Aug 28, 2020
6e8ee7c
[docs] Fix small mistake in DynamicCasting.md (#33641)
ole Aug 28, 2020
5afbddb
[Dependency Scanner] Ensure that Clang dependency scanner instances i…
artemcm Aug 28, 2020
82fc202
Merge pull request #33603 from LucianoPAlmeida/SR-13079-improve-kp-op…
LucianoPAlmeida Aug 28, 2020
b1db77a
Fix ConnectionGraph verification for calls to no return functions. (#…
meg-gupta Aug 28, 2020
f3cebd2
Merge pull request #33669 from rintaro/ide-completion-rdar67102794
rintaro Aug 28, 2020
1e5d30f
[Concurrency] Import Objective-C methods with completion handlers as …
DougGregor Aug 26, 2020
97d43ae
[WASM] Fix conflict resolution
kateinoigakukun Aug 28, 2020
1132cda
[ownership] Move SemanticARCOpts into a separate folder in preparatio…
gottesmm Aug 28, 2020
109b7b8
Disable LLDB tests in nightly package preset (67923799)
shahmishal Aug 28, 2020
4456632
[WASM] Skip to cross compile for arm64
kateinoigakukun Aug 28, 2020
f588f2f
Merge pull request #33650 from jckarter/global_init_mangling
jckarter Aug 28, 2020
c98d895
Expanded discussion of protocol types (#33621)
tbkka Aug 28, 2020
7b50374
Merge pull request #33679 from apple/disable-lldb-test-package-bot
shahmishal Aug 28, 2020
02513b1
Merge pull request #33671 from artemcm/BatchScannerTargetExtract
artemcm Aug 28, 2020
a6c3e6f
Merge pull request #33658 from xedin/introduce-hole-type
xedin Aug 28, 2020
c48a676
Merge pull request #31679 from Jumhyn/implicit-member-chains-differen…
rintaro Aug 28, 2020
fd6922f
Add error reporting when looking up types by demangled name.
mikeash Aug 19, 2020
0990fa9
Merge pull request #33647 from mikeash/shrink-concurrentreadablehashmap
mikeash Aug 28, 2020
539b241
Fallback to building Cmake from source on all platforms, not just Lin…
tbkka Aug 28, 2020
6ad2757
[Concurrency] Use completion/completionHandler parameter names for as…
DougGregor Aug 28, 2020
7c8041a
Merge pull request #33672 from CodaFi/ceci-nest-pas-une-pipeline
CodaFi Aug 28, 2020
592d427
Merge pull request #33668 from CodaFi/field-day
CodaFi Aug 28, 2020
8df8315
Merge pull request #33541 from varungandhi-apple/vg-clang-types-in-si…
varungandhi-apple Aug 28, 2020
50ea66d
Merge pull request #33585 from mikeash/type-lookup-error-reporting
mikeash Aug 28, 2020
c4f0505
[Parse] Don't drop throws containing a code completion expression.
Aug 14, 2020
00994f1
[Parse] Stop early exiting when parsing catch statements and ObjCSele…
Aug 27, 2020
3e0500d
[Parse][IDE] Don't drop default argument init exprs containing code c…
Aug 24, 2020
8980356
[Parse] Perform the single expression function body transform for del…
Aug 26, 2020
5525a78
Merge pull request #33663 from AnthonyLatsis/unbound-closure-retty
AnthonyLatsis Aug 29, 2020
172c4be
[Sema] Diagnose use of ambiguous property wrappers (#33688)
theblixguy Aug 29, 2020
8c1be69
Merge pull request #33677 from gottesmm/pr-0c62e0beda3a13e79c75b24764…
gottesmm Aug 29, 2020
11eac12
Merge pull request #33659 from gottesmm/pr-84ac4140f366657db17f220c96…
swift-ci Aug 29, 2020
10fa19b
Merge pull request #33674 from DougGregor/concurrency-objc-import-async
DougGregor Aug 29, 2020
7a6f84d
When building standalone stdlib, explicitly use C/C++ compilers from …
kubamracek Aug 29, 2020
73f4273
Mark Reflection_jit.swift as UNSUPPORTED for standalone stdlib builds…
kubamracek Aug 29, 2020
3e8278a
Merge pull request #33676 from nathawes/parser-completion-fixes
Aug 29, 2020
aba4f77
Merge branch 'master' of github.com:swiftwasm/swift into maxd/master-…
MaxDesiatov Aug 29, 2020
6a20263
Request WASI in `webassembly-macos-target` preset
MaxDesiatov Aug 29, 2020
26bac33
Fix `wait` signature in `MutexWASI.cpp`
MaxDesiatov Aug 29, 2020
c877ee6
Fix Foundation install path in build-foundation.sh
MaxDesiatov Aug 29, 2020
c985739
Use correct argument parser version in checkout
MaxDesiatov Aug 30, 2020
ba6d212
Move Foundation module files to correct path
MaxDesiatov Aug 30, 2020
acc71a6
Add IndexStore and SourceKit-LSP to host toolchain
MaxDesiatov Jul 14, 2020
885d32c
Add install-sourcekit-lsp to webassembly-host
MaxDesiatov Jul 14, 2020
270ff3d
Add libcxx and install-libcxx to build-presets
MaxDesiatov Jul 14, 2020
81b0cbb
Avoid building and installing sourcekit-lsp
MaxDesiatov Jul 15, 2020
2c70500
Build SourceKit-LSP, use swiftwasm fork for that
MaxDesiatov Aug 30, 2020
585b61e
Use the upstream SourceKit-LSP repo after all
MaxDesiatov Aug 31, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
25 changes: 20 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -369,6 +369,10 @@ option(SWIFT_REPORT_STATISTICS
"Create json files which contain internal compilation statistics"
FALSE)

option(SWIFT_DISABLE_OBJC_INTEROP
"Disable Objective-C interoperability even on platforms what would normally have it"
FALSE)

# FIXME(wasm) Reflection tests are temporalily disabled due to lack of linker features
option(SWIFTWASM_DISABLE_REFLECTION_TEST
"Disable building swift-reflection-test for WebAssembly build"
Expand All @@ -391,10 +395,6 @@ option(SWIFT_RUNTIME_ENABLE_LEAK_CHECKER
"Should the runtime be built with support for non-thread-safe leak detecting entrypoints"
FALSE)

option(SWIFT_STDLIB_USE_NONATOMIC_RC
"Build the standard libraries and overlays with nonatomic reference count operations enabled"
FALSE)

option(SWIFT_ENABLE_RUNTIME_FUNCTION_COUNTERS
"Enable runtime function counters and expose the API."
FALSE)
Expand Down Expand Up @@ -634,6 +634,22 @@ if("${CMAKE_C_COMPILER_ID}" STREQUAL "MSVC" OR "${CMAKE_CXX_SIMULATE_ID}" STREQU
set(SWIFT_COMPILER_IS_MSVC_LIKE TRUE)
endif()

if(NOT SWIFT_COMPILER_IS_MSVC_LIKE)
# CMake's default for CMAKE_CXX_FLAGS_RELEASE is "-O3 -DNDEBUG". Let's avoid "-O3" for consistency
# between Release and RelWithDebInfo. Dropping -DNDEBUG from this setting is blocked by triggering
# a test failure of Swift-Unit :: Syntax/./SwiftSyntaxTests/TypeSyntaxTests.MetatypeTypeWithAPIs
# because unit tests don't currently explicitly set -DNDEBUG/-UNDEBUG.
set(CMAKE_CXX_FLAGS_RELEASE "-O2 -DNDEBUG")

_compute_lto_flag("${SWIFT_TOOLS_ENABLE_LTO}" _lto_flag_out)
if(_lto_flag_out)
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_RELEASE} -gline-tables-only")
set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "${CMAKE_CXX_FLAGS_RELWITHDEBINFO} -gline-tables-only")
endif()
else()

endif()

#
# Configure SDKs.
#
Expand Down Expand Up @@ -933,7 +949,6 @@ if(NOT CMAKE_SYSTEM_NAME STREQUAL "Darwin")
endif()
endif()

find_package(Python2 COMPONENTS Interpreter REQUIRED)
find_package(Python3 COMPONENTS Interpreter REQUIRED)

#
Expand Down
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,14 @@ The required version of Xcode changes frequently, and is often a beta release.
Check this document or the host information on <https://ci.swift.org> for the
current required version.

Swift's build tooling is meant to support spaces in the paths passed to them,
but using spaces sometimes tickles bugs in Swift's build scripts or the tools
they rely on. For example, [SR-13441](https://bugs.swift.org/browse/SR-13441)
is caused by a space in the Xcode path used on macOS. If you see Swift's build
tooling misbehave due to a space in a path, please
[report the bug on the Swift bug tracker](https://swift.org/contributing/#reporting-bugs)
and then change the path to work around it.

You will also need [CMake](https://cmake.org) and [Ninja](https://ninja-build.org),
which can be installed via a package manager:

Expand Down
1 change: 1 addition & 0 deletions benchmark/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ set(SWIFT_BENCH_MODULES
single-source/PrefixWhile
single-source/Prims
single-source/PrimsNonStrongRef
single-source/ProtocolConformance
single-source/ProtocolDispatch
single-source/ProtocolDispatch2
single-source/Queue
Expand Down
76 changes: 76 additions & 0 deletions benchmark/single-source/ProtocolConformance.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
//===--- ProtocolDispatch.swift -------------------------------------------===//
//
// This source file is part of the Swift.org open source project
//
// Copyright (c) 2020 Apple Inc. and the Swift project authors
// Licensed under Apache License v2.0 with Runtime Library Exception
//
// See https://swift.org/LICENSE.txt for license information
// See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//
//===----------------------------------------------------------------------===//

import TestsUtils

public let ProtocolConformance = BenchmarkInfo (
name: "ProtocolConformance",
runFunction: run_ProtocolConformance,
tags: [.validation, .runtime])

protocol P {}

struct One: P {}
struct Two {}

struct Cat<T, U> {}

extension Cat: P where T: P, U: P {}

protocol Growable {}
extension Growable {
func grow() -> (Growable, Growable) {
return (Cat<Self, One>(), Cat<Self, Two>())
}
}

extension One: Growable {}
extension Two: Growable {}
extension Cat: Growable {}

@inline(never)
public func run_ProtocolConformance(_ N: Int) {
var array: [Growable] = [One(), Two()]
var i = 0
var checks = 0

// The expected number of times we expect `elt is P` to be true.
var expectedConforms = 0

// The expected number of times we expect `elt is P` to be true
// per iteration, at the current time.
var expectedConformsPerIter = 1

// The number of times we've actually seen `elt is P` be true.
var conforms = 0
while checks < N * 500 {
let (a, b) = array[i].grow()
array.append(a)
array.append(b)

// The number of times `elt is P` is true per outer iteration
// goes up by 1 when the array's count is a power of 2.
if array.count & (array.count - 1) == 0 {
expectedConformsPerIter += 1
}
expectedConforms += expectedConformsPerIter

for elt in array {
if elt is P {
conforms += 1
}
checks += 1
}
i += 1
}
CheckResults(expectedConforms == conforms)
}
2 changes: 2 additions & 0 deletions benchmark/utils/main.swift
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ import PrefixWhile
import Prims
import PrimsNonStrongRef
import PrimsSplit
import ProtocolConformance
import ProtocolDispatch
import ProtocolDispatch2
import Queue
Expand Down Expand Up @@ -317,6 +318,7 @@ registerBenchmark(PrefixWhile)
registerBenchmark(Prims)
registerBenchmark(PrimsNonStrongRef)
registerBenchmark(PrimsSplit)
registerBenchmark(ProtocolConformance)
registerBenchmark(ProtocolDispatch)
registerBenchmark(ProtocolDispatch2)
registerBenchmark(QueueGeneric)
Expand Down
36 changes: 10 additions & 26 deletions cmake/modules/AddSwift.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ function(_add_host_variant_c_compile_link_flags name)

set(_sysroot
"${SWIFT_SDK_${SWIFT_HOST_VARIANT_SDK}_ARCH_${SWIFT_HOST_VARIANT_ARCH}_PATH}")
if(SWIFT_HOST_VARIANT_SDK IN_LIST SWIFT_APPLE_PLATFORMS)
if(SWIFT_SDK_${SWIFT_HOST_VARIANT_SDK}_USE_ISYSROOT)
target_compile_options(${name} PRIVATE -isysroot;${_sysroot})
elseif(NOT SWIFT_COMPILER_IS_MSVC_LIKE AND NOT "${_sysroot}" STREQUAL "/")
target_compile_options(${name} PRIVATE --sysroot=${_sysroot})
Expand Down Expand Up @@ -130,13 +130,18 @@ function(_add_host_variant_c_compile_flags target)
_add_host_variant_c_compile_link_flags(${target})

is_build_type_optimized("${CMAKE_BUILD_TYPE}" optimized)
if(optimized)
target_compile_options(${target} PRIVATE -O2)
is_build_type_with_debuginfo("${CMAKE_BUILD_TYPE}" debuginfo)

# Add -O0/-O2/-O3/-Os/-g/-momit-leaf-frame-pointer/... based on CMAKE_BUILD_TYPE.
target_compile_options(${target} PRIVATE "${CMAKE_CXX_FLAGS_${CMAKE_BUILD_TYPE}}")

if(optimized)
# Omit leaf frame pointers on x86 production builds (optimized, no debug
# info, and no asserts).
is_build_type_with_debuginfo("${CMAKE_BUILD_TYPE}" debug)
if(NOT debug AND NOT LLVM_ENABLE_ASSERTIONS)
if(NOT debuginfo AND NOT LLVM_ENABLE_ASSERTIONS)
# Unfortunately, this cannot be folded into the standard
# CMAKE_CXX_FLAGS_... because Apple multi-SDK builds use different
# architectures for different SDKs.
if(SWIFT_HOST_VARIANT_ARCH MATCHES "i?86")
if(NOT SWIFT_COMPILER_IS_MSVC_LIKE)
target_compile_options(${target} PRIVATE -momit-leaf-frame-pointer)
Expand All @@ -145,27 +150,6 @@ function(_add_host_variant_c_compile_flags target)
endif()
endif()
endif()
else()
if(NOT SWIFT_COMPILER_IS_MSVC_LIKE)
target_compile_options(${target} PRIVATE -O0)
else()
target_compile_options(${target} PRIVATE /Od)
endif()
endif()

# CMake automatically adds the flags for debug info if we use MSVC/clang-cl.
if(NOT SWIFT_COMPILER_IS_MSVC_LIKE)
is_build_type_with_debuginfo("${CMAKE_BUILD_TYPE}" debuginfo)
if(debuginfo)
_compute_lto_flag("${SWIFT_TOOLS_ENABLE_LTO}" _lto_flag_out)
if(_lto_flag_out)
target_compile_options(${target} PRIVATE -gline-tables-only)
else()
target_compile_options(${target} PRIVATE -g)
endif()
else()
target_compile_options(${target} PRIVATE -g0)
endif()
endif()

if(SWIFT_HOST_VARIANT_SDK STREQUAL WINDOWS)
Expand Down
18 changes: 18 additions & 0 deletions cmake/modules/DarwinSDKs.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,24 @@ if(swift_build_osx)
configure_target_variant(OSX-R "OS X Release" OSX R "Release")
endif()

is_sdk_requested(FREESTANDING swift_build_freestanding)
if(swift_build_freestanding)
set(SWIFT_FREESTANDING_SDK "" CACHE STRING
"Which SDK to use when building the FREESTANDING stdlib")
set(SWIFT_FREESTANDING_TRIPLE_NAME "" CACHE STRING
"Which triple name (e.g. 'none-macho') to use when building the FREESTANDING stdlib")
set(SWIFT_FREESTANDING_ARCHS "" CACHE STRING
"Which architectures to build when building the FREESTANDING stdlib")
configure_sdk_darwin(
FREESTANDING "FREESTANDING" ""
"${SWIFT_FREESTANDING_SDK}" freestanding "${SWIFT_FREESTANDING_TRIPLE_NAME}" freestanding "${SWIFT_FREESTANDING_ARCHS}")
set(SWIFT_SDK_FREESTANDING_LIB_SUBDIR "freestanding")
configure_target_variant(FREESTANDING-DA "FREESTANDING Debug+Asserts" FREESTANDING DA "Debug+Asserts")
configure_target_variant(FREESTANDING-RA "FREESTANDING Release+Asserts" FREESTANDING RA "Release+Asserts")
configure_target_variant(FREESTANDING-R "FREESTANDING Release" FREESTANDING R "Release")
configure_target_variant(FREESTANDING-S "FREESTANDING MinSizeRelease" FREESTANDING S "MinSizeRelease")
endif()

# Compatible cross-compile SDKS for Darwin OSes: IOS, IOS_SIMULATOR, TVOS,
# TVOS_SIMULATOR, WATCHOS, WATCHOS_SIMULATOR (archs hardcoded below).

Expand Down
5 changes: 5 additions & 0 deletions cmake/modules/SwiftConfigureSDK.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,8 @@ endfunction()
# SWIFT_SDK_${prefix}_LIB_SUBDIR Library subdir for this SDK
# SWIFT_SDK_${prefix}_VERSION_MIN_NAME Version min name for this SDK
# SWIFT_SDK_${prefix}_TRIPLE_NAME Triple name for this SDK
# SWIFT_SDK_${prefix}_OBJECT_FORMAT The object file format (e.g. MACHO)
# SWIFT_SDK_${prefix}_USE_ISYSROOT Whether to use -isysroot
# SWIFT_SDK_${prefix}_ARCHITECTURES Architectures (as a list)
# SWIFT_SDK_${prefix}_IS_SIMULATOR Whether this is a simulator target.
# SWIFT_SDK_${prefix}_ARCH_${ARCH}_TRIPLE Triple name
Expand Down Expand Up @@ -187,6 +189,7 @@ macro(configure_sdk_darwin
set(SWIFT_SDK_${prefix}_VERSION_MIN_NAME "${version_min_name}")
set(SWIFT_SDK_${prefix}_TRIPLE_NAME "${triple_name}")
set(SWIFT_SDK_${prefix}_OBJECT_FORMAT "MACHO")
set(SWIFT_SDK_${prefix}_USE_ISYSROOT TRUE)

set(SWIFT_SDK_${prefix}_ARCHITECTURES ${architectures})
if(SWIFT_DARWIN_SUPPORTED_ARCHS)
Expand Down Expand Up @@ -270,6 +273,7 @@ macro(configure_sdk_unix name architectures)
else()
set(SWIFT_SDK_${prefix}_OBJECT_FORMAT "ELF")
endif()
set(SWIFT_SDK_${prefix}_USE_ISYSROOT FALSE)

foreach(arch ${architectures})
if("${prefix}" STREQUAL "ANDROID")
Expand Down Expand Up @@ -432,6 +436,7 @@ macro(configure_sdk_windows name environment architectures)
set(SWIFT_SDK_${prefix}_LIB_SUBDIR "windows")
set(SWIFT_SDK_${prefix}_ARCHITECTURES "${architectures}")
set(SWIFT_SDK_${prefix}_OBJECT_FORMAT "COFF")
set(SWIFT_SDK_${prefix}_USE_ISYSROOT FALSE)

foreach(arch ${architectures})
if(arch STREQUAL armv7)
Expand Down
42 changes: 42 additions & 0 deletions docs/ABI/Mangling.rst
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,11 @@ Globals
global ::= global 'MJ' // noncanonical specialized generic type metadata instantiation cache associated with global
global ::= global 'MN' // noncanonical specialized generic type metadata for global

#if SWIFT_RUNTIME_VERSION >= 5.4
global ::= context (decl-name '_')+ 'WZ' // global variable one-time initialization function
global ::= context (decl-name '_')+ 'Wz' // global variable one-time initialization token
#endif

A direct symbol resolves directly to the address of an object. An
indirect symbol resolves to the address of a pointer to the object.
They are distinct manglings to make a certain class of bugs
Expand Down Expand Up @@ -1107,3 +1112,40 @@ nominal type descriptor symbol for ``CxxStruct`` while compiling the ``main`` mo
.. code::

sSo9CxxStructVMn // -> nominal type descriptor for __C.CxxStruct

Importing C++ class template instantiations
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

A class template instantiation is imported as a struct named
``__CxxTemplateInst`` plus Itanium mangled type of the instantiation (see the
``type`` production in the Itanium specification). Note that Itanium mangling is
used on all platforms, regardless of the ABI of the C++ toolchain, to ensure
that the mangled name is a valid Swift type name (this is not the case for MSVC
mangled names). A prefix with a double underscore (to ensure we have a reserved
C++ identifier) is added to limit the possibility for conflicts with names of
user-defined structs. The struct is notionally defined in the ``__C`` module,
similarly to regular C and C++ structs and classes. Consider the following C++
module:

.. code-block:: c++

template<class T>
struct MagicWrapper {
T t;
};

struct MagicNumber {};

typedef MagicWrapper<MagicNumber> WrappedMagicNumber;

``WrappedMagicNumber`` is imported as a typealias for struct
``__CxxTemplateInst12MagicWrapperI11MagicNumberE``. Interface of the imported
module looks as follows:

.. code-block:: swift

struct __CxxTemplateInst12MagicWrapperI11MagicNumberE {
var t: MagicNumber
}
struct MagicNumber {}
typealias WrappedMagicNumber = __CxxTemplateInst12MagicWrapperI11MagicNumberE
Loading