Skip to content

Commit c57bc13

Browse files
committed
---
yaml --- r: 349223 b: refs/heads/master-next c: 4ade370 h: refs/heads/master i: 349221: 1392416 349219: 358364f 349215: a536b9a
1 parent 61bdf24 commit c57bc13

File tree

313 files changed

+2372
-2035
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

313 files changed

+2372
-2035
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
refs/heads/master: 3574c513bbc5578dd9346b4ea9ab5995c5927bb5
3-
refs/heads/master-next: 096778317048303b95a7aa56d1de9601829bee69
3+
refs/heads/master-next: 4ade370345e49d4b9ec102adacccfd0b162b9742
44
refs/tags/osx-passed: b6b74147ef8a386f532cf9357a1bde006e552c54
55
refs/tags/swift-2.2-SNAPSHOT-2015-12-01-a: 6bb18e013c2284f2b45f5f84f2df2887dc0f7dea
66
refs/tags/swift-2.2-SNAPSHOT-2015-12-01-b: 66d897bfcf64a82cb9a87f5e663d889189d06d07

branches/master-next/cmake/modules/SwiftXcodeSupport.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,8 @@ macro(swift_common_xcode_cxx_config)
100100
# Force usage of Clang.
101101
set(CMAKE_XCODE_ATTRIBUTE_GCC_VERSION "com.apple.compilers.llvm.clang.1_0"
102102
CACHE STRING "Xcode Compiler")
103-
# Use C++'11.
104-
set(CMAKE_XCODE_ATTRIBUTE_CLANG_CXX_LANGUAGE_STANDARD "c++11"
103+
# Use C++'14.
104+
set(CMAKE_XCODE_ATTRIBUTE_CLANG_CXX_LANGUAGE_STANDARD "c++14"
105105
CACHE STRING "Xcode C++ Language Standard")
106106
# Use libc++.
107107
set(CMAKE_XCODE_ATTRIBUTE_CLANG_CXX_LIBRARY "libc++"

branches/master-next/include/swift/AST/ASTNode.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,10 @@ namespace swift {
3636
enum class DeclKind : uint8_t;
3737
enum class StmtKind;
3838

39-
struct ASTNode : public llvm::PointerUnion3<Expr*, Stmt*, Decl*> {
39+
struct ASTNode : public llvm::PointerUnion<Expr*, Stmt*, Decl*> {
4040
// Inherit the constructors from PointerUnion.
41-
using PointerUnion3::PointerUnion3;
42-
41+
using PointerUnion::PointerUnion;
42+
4343
SourceRange getSourceRange() const;
4444

4545
/// Return the location of the start of the statement.

branches/master-next/include/swift/AST/Decl.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4785,7 +4785,7 @@ class VarDecl : public AbstractStorageDecl {
47854785
};
47864786

47874787
protected:
4788-
PointerUnion3<PatternBindingDecl *, Stmt *, VarDecl *> Parent;
4788+
PointerUnion<PatternBindingDecl *, Stmt *, VarDecl *> Parent;
47894789

47904790
VarDecl(DeclKind kind, bool isStatic, Introducer introducer,
47914791
bool issCaptureList, SourceLoc nameLoc, Identifier name,

branches/master-next/include/swift/AST/DiagnosticsClangImporter.def

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,10 +91,6 @@ WARNING(implicit_bridging_header_imported_from_module,none,
9191
"is deprecated and will be removed in a later version of Swift",
9292
(StringRef, Identifier))
9393

94-
WARNING(clang_vfs_overlay_is_ignored,none,
95-
"ignoring '-ivfsoverlay' options provided to '-Xcc' in favor of "
96-
"'-vfsoverlay'", ())
97-
9894
#ifndef DIAG_NO_UNDEF
9995
# if defined(DIAG)
10096
# undef DIAG

branches/master-next/include/swift/AST/Evaluator.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ class Evaluator {
260260
// Check for a cycle.
261261
if (checkDependency(getCanonicalRequest(request))) {
262262
return llvm::Error(
263-
llvm::make_unique<CyclicalRequestError<Request>>(request, *this));
263+
std::make_unique<CyclicalRequestError<Request>>(request, *this));
264264
}
265265

266266
// Make sure we remove this from the set of active requests once we're

branches/master-next/include/swift/AST/GenericSignatureBuilder.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -92,10 +92,10 @@ class GenericSignatureBuilder {
9292
class ResolvedType;
9393

9494
using UnresolvedRequirementRHS =
95-
llvm::PointerUnion3<Type, PotentialArchetype *, LayoutConstraint>;
95+
llvm::PointerUnion<Type, PotentialArchetype *, LayoutConstraint>;
9696

9797
using RequirementRHS =
98-
llvm::PointerUnion3<Type, PotentialArchetype *, LayoutConstraint>;
98+
llvm::PointerUnion<Type, PotentialArchetype *, LayoutConstraint>;
9999

100100
/// The location of a requirement as written somewhere in the source.
101101
typedef llvm::PointerUnion<const TypeRepr *, const RequirementRepr *>
@@ -1373,8 +1373,8 @@ class GenericSignatureBuilder::FloatingRequirementSource {
13731373
} kind;
13741374

13751375
using Storage =
1376-
llvm::PointerUnion3<const RequirementSource *, const TypeRepr *,
1377-
const RequirementRepr *>;
1376+
llvm::PointerUnion<const RequirementSource *, const TypeRepr *,
1377+
const RequirementRepr *>;
13781378

13791379
Storage storage;
13801380

branches/master-next/include/swift/AST/ModuleLoader.h

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,10 @@
2424
#include "llvm/ADT/SmallSet.h"
2525
#include "llvm/ADT/TinyPtrVector.h"
2626

27+
namespace llvm {
28+
class FileCollector;
29+
}
30+
2731
namespace clang {
2832
class DependencyCollector;
2933
}
@@ -54,8 +58,9 @@ enum class Bridgeability : unsigned {
5458
class DependencyTracker {
5559
std::shared_ptr<clang::DependencyCollector> clangCollector;
5660
public:
57-
58-
explicit DependencyTracker(bool TrackSystemDeps);
61+
explicit DependencyTracker(
62+
bool TrackSystemDeps,
63+
std::shared_ptr<llvm::FileCollector> FileCollector = {});
5964

6065
/// Adds a file as a dependency.
6166
///

branches/master-next/include/swift/AST/SimpleRequest.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ class SimpleRequest<Derived, Output(Inputs...), Caching> {
195195

196196
template<size_t ...Indices>
197197
llvm::Expected<Output>
198-
callDerived(Evaluator &evaluator, llvm::index_sequence<Indices...>) const {
198+
callDerived(Evaluator &evaluator, std::index_sequence<Indices...>) const {
199199
static_assert(sizeof...(Indices) > 0, "Subclass must define evaluate()");
200200
return asDerived().evaluate(evaluator, std::get<Indices>(storage)...);
201201
}
@@ -217,7 +217,7 @@ class SimpleRequest<Derived, Output(Inputs...), Caching> {
217217
static llvm::Expected<OutputType>
218218
evaluateRequest(const Derived &request, Evaluator &evaluator) {
219219
return request.callDerived(evaluator,
220-
llvm::index_sequence_for<Inputs...>());
220+
std::index_sequence_for<Inputs...>());
221221
}
222222

223223
/// Retrieve the nearest source location to which this request applies.

branches/master-next/include/swift/AST/TypeCheckRequests.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,7 @@ struct WhereClauseOwner {
366366

367367
/// The source of the where clause, which can be a generic parameter list
368368
/// or a declaration that can have a where clause.
369-
llvm::PointerUnion3<GenericParamList *, Decl *, SpecializeAttr *> source;
369+
llvm::PointerUnion<GenericParamList *, Decl *, SpecializeAttr *> source;
370370

371371
WhereClauseOwner(Decl *decl);
372372

branches/master-next/include/swift/Basic/LLVM.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,7 @@ namespace llvm {
4242
template<typename T> class MutableArrayRef;
4343
template<typename T> class TinyPtrVector;
4444
template<typename T> class Optional;
45-
template <typename PT1, typename PT2> class PointerUnion;
46-
template <typename PT1, typename PT2, typename PT3> class PointerUnion3;
45+
template <typename ...PTs> class PointerUnion;
4746
class SmallBitVector;
4847

4948
// Other common classes.
@@ -68,7 +67,6 @@ namespace swift {
6867
using llvm::None;
6968
using llvm::Optional;
7069
using llvm::PointerUnion;
71-
using llvm::PointerUnion3;
7270
using llvm::SmallBitVector;
7371
using llvm::SmallPtrSet;
7472
using llvm::SmallPtrSetImpl;

branches/master-next/include/swift/ClangImporter/ClangImporter.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323

2424
namespace llvm {
2525
class Triple;
26+
class FileCollector;
2627
template<typename Fn> class function_ref;
2728
}
2829

@@ -149,7 +150,8 @@ class ClangImporter final : public ClangModuleLoader {
149150
/// Create a new clang::DependencyCollector customized to
150151
/// ClangImporter's specific uses.
151152
static std::shared_ptr<clang::DependencyCollector>
152-
createDependencyCollector(bool TrackSystemDeps);
153+
createDependencyCollector(bool TrackSystemDeps,
154+
std::shared_ptr<llvm::FileCollector> FileCollector);
153155

154156
/// Append visible module names to \p names. Note that names are possibly
155157
/// duplicated, and not guaranteed to be ordered in any way.

branches/master-next/include/swift/ClangImporter/ClangImporterOptions.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -96,10 +96,6 @@ class ClangImporterOptions {
9696
/// When set, don't enforce warnings with -Werror.
9797
bool DebuggerSupport = false;
9898

99-
/// When set, clobber the Clang instance's virtual file system with the Swift
100-
/// virtual file system.
101-
bool ForceUseSwiftVirtualFileSystem = false;
102-
10399
/// Return a hash code of any components from these options that should
104100
/// contribute to a Swift Bridging PCH hash.
105101
llvm::hash_code getPCHHashComponents() const {

branches/master-next/include/swift/Frontend/Frontend.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -462,7 +462,7 @@ class CompilerInstance {
462462

463463
void createDependencyTracker(bool TrackSystemDeps) {
464464
assert(!Context && "must be called before setup()");
465-
DepTracker = llvm::make_unique<DependencyTracker>(TrackSystemDeps);
465+
DepTracker = std::make_unique<DependencyTracker>(TrackSystemDeps);
466466
}
467467
DependencyTracker *getDependencyTracker() { return DepTracker.get(); }
468468

branches/master-next/include/swift/LLVMPasses/Passes.h

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,14 @@ namespace swift {
3030
const llvm::PreservedAnalyses &) { return false; }
3131

3232
using AAResultBase::getModRefInfo;
33-
llvm::ModRefInfo getModRefInfo(llvm::ImmutableCallSite CS,
34-
const llvm::MemoryLocation &Loc);
33+
llvm::ModRefInfo getModRefInfo(const llvm::CallBase *Call,
34+
const llvm::MemoryLocation &Loc) {
35+
llvm::AAQueryInfo AAQI;
36+
return getModRefInfo(Call, Loc, AAQI);
37+
}
38+
llvm::ModRefInfo getModRefInfo(const llvm::CallBase *Call,
39+
const llvm::MemoryLocation &Loc,
40+
llvm::AAQueryInfo &AAQI);
3541
};
3642

3743
class SwiftAAWrapperPass : public llvm::ImmutablePass {

branches/master-next/include/swift/Parse/Parser.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
#include "llvm/ADT/SetVector.h"
4141

4242
namespace llvm {
43-
template <typename PT1, typename PT2, typename PT3> class PointerUnion3;
43+
template <typename... PTs> class PointerUnion;
4444
}
4545

4646
namespace swift {

branches/master-next/include/swift/SIL/PatternMatch.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,7 @@ namespace detail {
310310
struct GetOperandsFunctor {
311311
template <size_t... Idx>
312312
std::array<SILValue, sizeof...(Idx)>
313-
operator()(SILInstruction *i, llvm::index_sequence<Idx...> seq) const {
313+
operator()(SILInstruction *i, std::index_sequence<Idx...> seq) const {
314314
return {i->getOperand(Idx)...};
315315
}
316316
};
@@ -327,15 +327,15 @@ template <typename... MatcherTys> struct MatcherFunctor {
327327
template <size_t... Idx>
328328
std::array<bool, sizeof...(MatcherTys)>
329329
matchHelper(const std::array<SILValue, sizeof...(MatcherTys)> &operands,
330-
llvm::index_sequence<Idx...> seq) {
330+
std::index_sequence<Idx...> seq) {
331331
return {individual(std::get<Idx>(matchers), std::get<Idx>(operands))...};
332332
}
333333

334334
bool match(SILInstruction *i) {
335335
std::array<SILValue, sizeof...(MatcherTys)> operands =
336-
GetOperandsFunctor{}(i, llvm::index_sequence_for<MatcherTys...>{});
336+
GetOperandsFunctor{}(i, std::index_sequence_for<MatcherTys...>{});
337337
auto tmpResult =
338-
matchHelper(operands, llvm::index_sequence_for<MatcherTys...>{});
338+
matchHelper(operands, std::index_sequence_for<MatcherTys...>{});
339339
for (unsigned i : indices(tmpResult)) {
340340
if (!tmpResult[i])
341341
return false;

branches/master-next/include/swift/SIL/SILInstruction.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -988,7 +988,7 @@ class MultipleValueInstructionTrailingObjects<Derived, DerivedResult,
988988
MultipleValueInstruction *,
989989
DerivedResult,
990990
FinalOtherTrailingTypes...> {
991-
static_assert(LLVM_IS_FINAL(DerivedResult),
991+
static_assert(std::is_final<DerivedResult>(),
992992
"Expected DerivedResult to be final");
993993
static_assert(
994994
std::is_base_of<MultipleValueInstructionResult, DerivedResult>::value,

branches/master-next/include/swift/SILOptimizer/Analysis/BasicCalleeAnalysis.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -164,14 +164,14 @@ class BasicCalleeAnalysis : public SILAnalysis {
164164

165165
CalleeList getCalleeList(FullApplySite FAS) {
166166
if (!Cache)
167-
Cache = llvm::make_unique<CalleeCache>(M);
167+
Cache = std::make_unique<CalleeCache>(M);
168168

169169
return Cache->getCalleeList(FAS);
170170
}
171171

172172
CalleeList getCalleeList(SILInstruction *I) {
173173
if (!Cache)
174-
Cache = llvm::make_unique<CalleeCache>(M);
174+
Cache = std::make_unique<CalleeCache>(M);
175175

176176
return Cache->getCalleeList(I);
177177
}

branches/master-next/include/swift/SILOptimizer/Analysis/DominanceAnalysis.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class DominanceAnalysis : public FunctionAnalysisBase<DominanceInfo> {
4242
}
4343

4444
std::unique_ptr<DominanceInfo> newFunctionAnalysis(SILFunction *F) override {
45-
return llvm::make_unique<DominanceInfo>(F);
45+
return std::make_unique<DominanceInfo>(F);
4646
}
4747

4848
virtual bool shouldInvalidate(SILAnalysis::InvalidationKind K) override {
@@ -72,7 +72,7 @@ class PostDominanceAnalysis : public FunctionAnalysisBase<PostDominanceInfo> {
7272

7373
std::unique_ptr<PostDominanceInfo>
7474
newFunctionAnalysis(SILFunction *F) override {
75-
return llvm::make_unique<PostDominanceInfo>(F);
75+
return std::make_unique<PostDominanceInfo>(F);
7676
}
7777

7878
virtual bool shouldInvalidate(SILAnalysis::InvalidationKind K) override {

branches/master-next/include/swift/SILOptimizer/Analysis/EpilogueARCAnalysis.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,7 @@ class EpilogueARCAnalysis : public FunctionAnalysisBase<EpilogueARCFunctionInfo>
302302

303303
virtual std::unique_ptr<EpilogueARCFunctionInfo>
304304
newFunctionAnalysis(SILFunction *F) override {
305-
return llvm::make_unique<EpilogueARCFunctionInfo>(F, PO, AA, RC);
305+
return std::make_unique<EpilogueARCFunctionInfo>(F, PO, AA, RC);
306306
}
307307

308308
virtual bool shouldInvalidate(SILAnalysis::InvalidationKind K) override {

branches/master-next/include/swift/SILOptimizer/Analysis/IVAnalysis.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ class IVAnalysis final : public FunctionAnalysisBase<IVInfo> {
9191
}
9292

9393
std::unique_ptr<IVInfo> newFunctionAnalysis(SILFunction *F) override {
94-
return llvm::make_unique<IVInfo>(*F);
94+
return std::make_unique<IVInfo>(*F);
9595
}
9696

9797
/// For now we always invalidate.

branches/master-next/include/swift/SILOptimizer/Analysis/LoopRegionAnalysis.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ class LoopRegion {
384384
private:
385385
/// A pointer to one of a Loop, Basic Block, or Function represented by this
386386
/// region.
387-
llvm::PointerUnion3<FunctionTy *, LoopTy *, BlockTy *> Ptr;
387+
llvm::PointerUnion<FunctionTy *, LoopTy *, BlockTy *> Ptr;
388388

389389
/// The ID of this region.
390390
unsigned ID;
@@ -1082,7 +1082,7 @@ class LoopRegionAnalysis : public FunctionAnalysisBase<LoopRegionFunctionInfo> {
10821082

10831083
virtual std::unique_ptr<LoopRegionFunctionInfo>
10841084
newFunctionAnalysis(SILFunction *F) override {
1085-
return llvm::make_unique<LoopRegionFunctionInfo>(F, POA->get(F),
1085+
return std::make_unique<LoopRegionFunctionInfo>(F, POA->get(F),
10861086
SLA->get(F));
10871087
}
10881088

branches/master-next/include/swift/SILOptimizer/Analysis/PostOrderAnalysis.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ class PostOrderAnalysis : public FunctionAnalysisBase<PostOrderFunctionInfo> {
3636
protected:
3737
virtual std::unique_ptr<PostOrderFunctionInfo>
3838
newFunctionAnalysis(SILFunction *F) override {
39-
return llvm::make_unique<PostOrderFunctionInfo>(F);
39+
return std::make_unique<PostOrderFunctionInfo>(F);
4040
}
4141

4242
virtual bool shouldInvalidate(SILAnalysis::InvalidationKind K) override {

branches/master-next/include/swift/SILOptimizer/Analysis/RCIdentityAnalysis.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ class RCIdentityAnalysis : public FunctionAnalysisBase<RCIdentityFunctionInfo> {
120120

121121
virtual std::unique_ptr<RCIdentityFunctionInfo>
122122
newFunctionAnalysis(SILFunction *F) override {
123-
return llvm::make_unique<RCIdentityFunctionInfo>(DA);
123+
return std::make_unique<RCIdentityFunctionInfo>(DA);
124124
}
125125

126126
virtual bool shouldInvalidate(SILAnalysis::InvalidationKind K) override {

branches/master-next/lib/AST/ASTContext.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1530,7 +1530,7 @@ void ASTContext::registerGenericSignatureBuilder(
15301530

15311531
++NumRegisteredGenericSignatureBuilders;
15321532
genericSignatureBuilders[canSig] =
1533-
llvm::make_unique<GenericSignatureBuilder>(std::move(builder));
1533+
std::make_unique<GenericSignatureBuilder>(std::move(builder));
15341534
}
15351535

15361536
GenericSignatureBuilder *ASTContext::getOrCreateGenericSignatureBuilder(

branches/master-next/lib/AST/Builtins.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1378,9 +1378,13 @@ Type IntrinsicTypeDecoder::decodeImmediate() {
13781378
case IITDescriptor::ExtendArgument:
13791379
case IITDescriptor::TruncArgument:
13801380
case IITDescriptor::HalfVecArgument:
1381+
case IITDescriptor::ScalableVecArgument:
13811382
case IITDescriptor::VarArg:
13821383
case IITDescriptor::Token:
1384+
case IITDescriptor::VecElementArgument:
13831385
case IITDescriptor::VecOfAnyPtrsToElt:
1386+
case IITDescriptor::Subdivide2Argument:
1387+
case IITDescriptor::Subdivide4Argument:
13841388
// These types cannot be expressed in swift yet.
13851389
return Type();
13861390

branches/master-next/lib/AST/DiagnosticConsumer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ FileSpecificDiagnosticConsumer::consolidateSubconsumers(
7171
if (subconsumers.size() == 1)
7272
return std::move(subconsumers.front()).consumer;
7373
// Cannot use return
74-
// llvm::make_unique<FileSpecificDiagnosticConsumer>(subconsumers); because
74+
// std::make_unique<FileSpecificDiagnosticConsumer>(subconsumers); because
7575
// the constructor is private.
7676
return std::unique_ptr<DiagnosticConsumer>(
7777
new FileSpecificDiagnosticConsumer(subconsumers));

branches/master-next/lib/AST/GenericSignatureBuilder.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3433,7 +3433,7 @@ GenericSignatureBuilder::Implementation::getOrCreateRewriteTreeRoot(
34333433
return root;
34343434

34353435
auto &root = RewriteTreeRoots[anchor];
3436-
root = llvm::make_unique<RewriteTreeNode>(nullptr);
3436+
root = std::make_unique<RewriteTreeNode>(nullptr);
34373437
return root.get();
34383438
}
34393439

0 commit comments

Comments
 (0)