Jordan Rose
098a1c98f8
Stop importing SILModule.h in Frontend.h
...
...for no other reason than to slightly improve compile times
when something changes in SILModule.h or SILFunction.h.
2018-02-20 17:50:50 -08:00
David Ungar
488db9fb9b
Fix ReferencedNameTracker in preparation for batch mode.
2018-02-16 22:28:10 -07:00
David Ungar
fec411e9bc
reformatted
2018-02-15 15:34:55 -07:00
David Ungar
1f9a4f3591
Pass around arguments for primary-specific filenames.
...
Get rid of IRGenOpts attributes that won’t work for batch mode and also remove fakeNamesStub.
2018-02-15 15:34:55 -07:00
Andrew Trick
def6d24237
Add -verify-exclusivity option (off by default)
2018-02-15 11:26:54 -08:00
Xi Ge
37f352fe41
sourcekitd: build Swift syntax tree more lazily than collecting parsed tokens. ( #14578 )
...
Before this patch, we have one flag (KeepSyntaxInfo) to turn on two syntax
functionalities of parser: (1) collecting parsed tokens for coloring and
(2) building syntax trees. Since sourcekitd is the only consumer of either of these
functionalities, sourcekitd by default always enables such flag.
However, empirical results show (2) is both heavier and less-frequently
needed than (1). Therefore, separating the flag to two flags makes more
sense, where CollectParsedToken controls (1) and BuildSyntaxTree
controls (2).
CollectingParsedToken is always enabled by sourcekitd because
formatting and syntax-coloring need it; however BuildSyntaxTree should
be explicitly switched on by sourcekitd clients.
resolves: rdar://problem/37483076
2018-02-13 16:27:12 -08:00
Mark Lacey
37009b0d8b
[ConstraintSystem] Remove constraint propagation.
...
The current implementation isn't really useful in the face of generic
overloads. It has never been enabled by default, and isn't useful to
keep around if it is disabled. If we ever want to bring it back,
we know where to look!
2018-02-12 21:30:39 -08:00
David Ungar
ef02d0bfc0
Cleaner handling of cases where action produces no output or where there are no inputs.
2018-02-08 13:22:49 -08:00
David Ungar
ba4f2a84b4
Move supplementary outputs to SupplementaryOutputs in FrontendInputsAndOutputs.
2018-02-07 13:55:32 -08:00
David Ungar
56b50cb28d
Merge pull request #14349 from davidungar/PR-18-4b-refactor-performCompile
...
[Batch Mode] NFC: Carve up performCompile & performCompileStepsPostSILGen. (2)
2018-02-05 19:17:53 -08:00
David Ungar
4821e15795
Extract shouldActionOnlyParse.
2018-02-02 20:25:05 -08:00
David Ungar
c396a3a972
Don’t free the ASTContext if > 1 primary input.
2018-02-02 13:49:08 -08:00
eeckstein
1218515153
Merge pull request #14338 from eeckstein/fix-nd
...
Fix two issues which prevents incremental llvm compilation
2018-02-01 19:26:47 -08:00
David Ungar
6b1d16b68b
Move comment to declaration.
2018-02-01 15:20:20 -08:00
Erik Eckstein
17d4459227
debug-info: Don't write temporary file names in the debug info.
...
This would prevent incremental llvm compilation because we would generate different IR on every compiler invocation.
2018-02-01 12:15:36 -08:00
David Ungar
614006bc4f
Move main outputs to FrontendInputsAndOutputs and InputFile
2018-02-01 11:55:08 -08:00
David Ungar
e006825d88
Move convertBufferNameFromLLVM_getFileOrSTDIN_toSwiftConventions deeper in the call stack.
2018-01-30 18:55:02 -08:00
David Ungar
4bd12ac509
Change conjunction to assertion in isInputPrimary to check consistency.
2018-01-30 18:55:01 -08:00
David Ungar
00da3e81ca
Reorder attributes in FrontendInputsAndOutputs
2018-01-30 18:55:01 -08:00
David Ungar
a9819b6e60
Renaming FrontendInputs -> FrontendInputsAndOutputs
...
Fix comment in ArtsToFrontendOptionsConverter re getOutputFilenamesFromCommandLineOrFilelist
2018-01-30 18:54:38 -08:00
David Ungar
ec2a9573cc
Rename FrontendInputs::AllFiles to AllInputs, getAllFiles to getAllInputs, etc.
2018-01-23 14:01:15 -08:00
David Ungar
a70ba0a6cd
Split out ArgsToFrontenfOptionsConverter.
2018-01-19 09:51:30 -08:00
David Ungar
68bda74a00
Split out ArgsToFrontendInputsConverter.
2018-01-18 18:36:12 -08:00
David Ungar
361ff7244c
Move FrontendInputs into separate .h and .cpp files.
2018-01-18 18:34:57 -08:00
David Ungar
1f8f9947fd
Changed PrimarySourceFiles from a SetVector to an ArrayRef.
2018-01-17 12:20:52 -08:00
Graydon Hoare
b0e5726af9
[BatchMode] Change CompilerInstance::Primary{BufferID,SourceFile} to SetVectors.
2018-01-16 16:17:25 -08:00
Slava Pestov
6af8d18a00
IRGen: Remove -enable-class-resilience staging flag
2018-01-03 00:26:10 -08:00
Greg Parker
c677a5dc11
[IRGen][runtime] Prepare to change the is-Swift bit in class metadata. ( #13595 )
...
Swift class metadata has a bit to distinguish it from non-Swift Objective-C
classes. The stable ABI will use a different bit so that stable Swift and
pre-stable Swift can be distinguished from each other.
No bits are actually changed yet. Enabling the new bit needs to wait for
other coordination such as libobjc.
rdar://35767811
2017-12-22 00:52:00 -08:00
swift-ci
adf83617ec
Merge pull request #13526 from DougGregor/remove-conditional-conformances-flag
2017-12-19 11:17:44 -08:00
Doug Gregor
5c831a71ee
Revert "[SE-0143] Put conditional conformances behind an "experimental" flag."
...
This reverts commit b59c30c1af .
2017-12-18 22:54:31 -08:00
Ben Langmuir
93956eb34b
[code-complete] Put call-pattern heuristics under a flag
...
The original hope was we could make these heuristics really good, but
since that is not currently in sight (and may never be), we want to be
able to turn them off. For now, just plumb through an internal flag to
control the behaviour. A future change will customize the behaviour in
SourceKit.
rdar://31113161
2017-12-15 13:23:44 -08:00
David Ungar
676c396b7d
Merge pull request #13397 from davidungar/PR5-setBuffer-rb2
...
Eliminate InputFile::setBuffer()
2017-12-13 14:48:26 -08:00
David Ungar
38c7b3eb4e
Make PrimaryFiles into a local.
...
Separate unusedPrimaries from all Primaries.
2017-12-13 12:01:47 -08:00
David Ungar
02470d1343
Simplify invocation of forAllFilesInFilelist.
2017-12-13 09:55:41 -08:00
David Ungar
9c78480bdf
Enforce exclusivity between -primary-file and -primary-filelist.
2017-12-13 09:45:53 -08:00
David Ungar
fb141bb16d
Fix primary not found diagnostic.
2017-12-13 09:28:43 -08:00
David Ungar
c3c9e90865
Add primary file list.
2017-12-13 04:03:37 -08:00
David Ungar
e9ada4cd0e
FrontendInputs data structure redo.
...
- Outlaw duplicate input files, fix driver, fix tests, and add test.
- Reflect that no buffer is present without a (possibly pseudo) named file.
- Reflect fact that every input has a (possible pseudo) name.
- Break up CompilerInstance::setup.
-
2017-12-12 16:01:12 -08:00
David Ungar
c0b0b5c5da
Eliminate InputFile::setBuffer by having SwiftASTManager create new InputFile's with the buffer set or not as needed.
2017-12-12 15:06:26 -08:00
David Ungar
00872b5d50
Removed another get().
2017-12-12 13:07:09 -08:00
David Ungar
38ce2a14d1
Added a FIXME and removed a get per review suggestions.
2017-12-12 13:04:25 -08:00
David Ungar
9105284a06
Refactor setUpInputs in CompilerInstance.
2017-12-12 10:14:33 -08:00
David Ungar
c1f81867d7
Merge pull request #13268 from davidungar/PR3A-rb
...
FrontendInputs data structure redo, rebased.
2017-12-11 20:44:10 -08:00
David Ungar
724d1c36cd
Last round of small changes
2017-12-11 17:19:06 -08:00
Slava Pestov
fc3cf2863a
Sema: Infer default witnesses before finishing conformance checking
...
Otherwise, we'll never get a chance to drain the TypeChecker's
UsedConformances list.
Fixes <https://bugs.swift.org/browse/SR-6565 >, <rdar://problem/35949729>.
2017-12-10 20:30:48 -08:00
David Ungar
60827b4be3
Rename accessors to InputFile data.
2017-12-08 12:57:32 -08:00
David Ungar
6e3829ec96
Rename isInMainMode to isInputSwift
2017-12-08 11:47:33 -08:00
David Ungar
ce56435a1a
Remove needless conversion to unique pointer.
2017-12-08 11:45:33 -08:00
David Ungar
536300f018
Add assertions about re-setting Main and PrimaryBufferIDs
2017-12-08 11:43:38 -08:00
David Ungar
c6cfa147f3
Added assertion for single primary to shouldTreatAsSIL
2017-12-06 16:08:30 -08:00