Andrew Trick
6ffafe4dd3
NFC: Remove a dead call in the DeadObjectElimination pass.
...
Cleanup after a pasto. Thanks Roman.
2016-04-05 16:28:27 -07:00
Erik Eckstein
115c50a5c7
DeadObjectElimination: Fix a problem with dead array elimination.
...
With the new ValueLifetimeAnalysis DOE did not handle case where a dead array is not released on a path at all (because it leads to an unreachable).
2016-03-01 12:30:52 -08:00
Erik Eckstein
1730b90ae4
Reinstate "Rewrite the ValueLifetimeAnalysis."
...
Reinstates commit 0c2ca94ef7
With two bug fixes:
*) use after free asan crash
*) wrong check in ValueLifetimeAnalysis::isWithinLifetime
And some refactoring
2016-02-29 07:42:59 -08:00
Xin Tong
d0dc008fc1
Revert GenericSpecializer code.
...
This reverts commit
ed8126d050
ac0e7fd183
a11042eb05
b2d6e8ce6e
3a83cee006
0c2ca94ef7
First 4 commits are @practicalswift typo fixes which are implicated. Last 2 are
the culprits.
This causes an asan build crash.
2016-02-28 11:13:44 -08:00
Erik Eckstein
0c2ca94ef7
Rewrite the ValueLifetimeAnalysis.
...
It fixes a problem with lifetime regions having "exit-edges". This crashed the ClosureSpecializer.
2016-02-26 14:05:48 -08:00
Xin Tong
84a6ff1d98
And lastly rename NewProjection to Projection. This is a NFC. rdar://24520269
2016-02-09 22:20:10 -08:00
Xin Tong
6fb741bbca
Migrate dead object elimination to new projection. This should be a NFC
2016-02-09 22:20:09 -08:00
Erik Eckstein
74d44b74e7
SIL: remove SILValue::getDef and add a cast operator to ValueBase * as a repelacement. NFC.
2016-01-25 15:00:49 -08:00
Erik Eckstein
506ab9809f
SIL: remove getTyp() from SILValue
2016-01-25 15:00:49 -08:00
Erik Eckstein
b745691a38
SIL refactoring: Move some functions out of SILValue and Operand
...
SILValue.h/.cpp just defines the SIL base classes. Referring to specific instructions is a (small) kind of layering violation.
Also I want to keep SILValue small so that it is really just a type alias of ValueBase*.
NFC.
2016-01-25 10:37:03 -08:00
practicalswift
33312eac6b
[gardening] Remove unreachable/unused/redundant code
...
* Make parameter naming in forward declaration match definition
* Remove unused argument to function persistAsync(…)
* Remove unused enum ShouldHalt
* Remove unused enum class IsProtocol
* Remove unused function dumpTypeSubstitutionMap()
* Remove unused function template getFirstPairElt(…)
* Remove unused method addConstantWordInWords(…)
* Remove unused method asExistentialTI()
* Remove unused method currentTrackedState()
* Remove unused method getNumBodyParameters()
* Remove unused method getSuccIndex()
* Remove unused method getTypeOfDeclReference(…)
* Remove unused method hasStructWithAtMostOneNonTrivialField(…)
* Remove unused method initForDirectValues()
* Remove unused method nextIfNot(…)
* Remove unused method overwriteLoweredValue(…)
* Remove unused method removeColumn(…)
* Remove unused methods HasSingleDecl() and GetFirstDecl()
* Remove unused methods overwriteLoweredExplosion(…) and setLoweredSingleValue(…)
* Remove unused methods requireRetainablePointerValue(…), getMethodSelfInstanceType(…) and isSelfArchetype(…)
* Remove unused methods setAsEmptyDirect(), setAsSingleDirectUnmanagedFragileValue(…), setAsIndirectAddress(…) and getDirectValues()
* Remove unused struct CachedMemberInfo
* Remove unused struct CallEdit
* Remove unused struct ErrorImportInfo
* Remove unused synonym ConformancePair
* Remove unused variable SemaInfo
* Remove unused variable localDeclNameNode
* Remove unused variables kindToken and kindLoc
2016-01-22 09:43:24 +01:00
Erik Eckstein
2db6f3d213
SIL: remove multiple result values from SILValue
...
As there are no instructions left which produce multiple result values, this is a NFC regarding the generated SIL and generated code.
Although this commit is large, most changes are straightforward adoptions to the changes in the ValueBase and SILValue classes.
2016-01-21 10:30:31 -08:00
practicalswift
1339b5403b
Consistent use of header comment format.
...
Correct format:
//===--- Name of file - Description ----------------------------*- Lang -*-===//
2016-01-04 13:26:31 +01:00
Zach Panzarino
e3a4147ac9
Update copyright date
2015-12-31 23:28:40 +00:00
practicalswift
149b50d901
Fix typos in code (non-comment/documentation typos).
2015-12-28 11:42:15 +01:00
practicalswift
85e2e6eb9a
Fix a vs. an
2015-12-26 14:40:16 +01:00
ken0nek
fcd8fcee91
Convert [Cc]an not -> [Cc]annot
2015-12-23 00:55:48 +09:00
Xin Tong
375bef1295
Minor comment fix in DeadObjectElimination.cpp
2015-12-20 14:23:20 -08:00
Andrew Trick
739b0e9c56
Reorganize SILOptimizer directories for better discoverability.
...
(libraries now)
It has been generally agreed that we need to do this reorg, and now
seems like the perfect time. Some major pass reorganization is in the
works.
This does not have to be the final word on the matter. The consensus
among those working on the code is that it's much better than what we
had and a better starting point for future bike shedding.
Note that the previous organization was designed to allow separate
analysis and optimization libraries. It turns out this is an
artificial distinction and not an important goal.
2015-12-11 15:14:23 -08:00