Skip to content

Commit ab82774

Browse files
committed
Merge remote-tracking branch 'origin/master' into master-next
2 parents 9f31348 + 3bf54c3 commit ab82774

File tree

4 files changed

+4
-44
lines changed

4 files changed

+4
-44
lines changed

cmake/modules/SwiftSharedCMakeConfig.cmake

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ macro(swift_common_unified_build_config product)
226226
set(PATH_TO_LLVM_BUILD "${CMAKE_BINARY_DIR}")
227227
set(${product}_PATH_TO_CLANG_BUILD "${CMAKE_BINARY_DIR}")
228228
set(PATH_TO_CLANG_BUILD "${CMAKE_BINARY_DIR}")
229-
set(CLANG_MAIN_INCLUDE_DIR "${CMAKE_SOURCE_DIR}/tools/clang/include")
229+
set(CLANG_MAIN_INCLUDE_DIR "${LLVM_EXTERNAL_CLANG_SOURCE_DIR}/include")
230230
set(CLANG_BUILD_INCLUDE_DIR "${CMAKE_BINARY_DIR}/tools/clang/include")
231231
set(${product}_NATIVE_LLVM_TOOLS_PATH "${CMAKE_BINARY_DIR}/bin")
232232
set(${product}_NATIVE_CLANG_TOOLS_PATH "${CMAKE_BINARY_DIR}/bin")
@@ -235,8 +235,8 @@ macro(swift_common_unified_build_config product)
235235

236236
# If cmark was checked out into tools/cmark, expect to build it as
237237
# part of the unified build.
238-
if(EXISTS "${CMAKE_SOURCE_DIR}/tools/cmark/")
239-
set(${product}_PATH_TO_CMARK_SOURCE "${CMAKE_SOURCE_DIR}/tools/cmark")
238+
if(EXISTS "${LLVM_EXTERNAL_CMARK_SOURCE_DIR}")
239+
set(${product}_PATH_TO_CMARK_SOURCE "${LLVM_EXTERNAL_CMARK_SOURCE_DIR}")
240240
set(${product}_PATH_TO_CMARK_BUILD "${CMAKE_BINARY_DIR}/tools/cmark")
241241
set(${product}_CMARK_LIBRARY_DIR "${CMAKE_BINARY_DIR}/lib")
242242

include/swift/FrontendTool/FrontendTool.h

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -42,25 +42,6 @@ class FrontendObserver {
4242

4343
/// The frontend has configured the compiler instance.
4444
virtual void configuredCompiler(CompilerInstance &instance);
45-
46-
/// The frontend has performed semantic analysis.
47-
virtual void performedSemanticAnalysis(CompilerInstance &instance);
48-
49-
/// The frontend has performed basic SIL generation.
50-
/// SIL diagnostic passes have not yet been applied.
51-
virtual void performedSILGeneration(SILModule &module);
52-
53-
/// The frontend has executed the SIL diagnostic passes.
54-
virtual void performedSILDiagnostics(SILModule &module);
55-
56-
/// The frontend has executed the SIL optimization pipeline.
57-
virtual void performedSILOptimization(SILModule &module);
58-
59-
/// The frontend is about to run the program as an immediate script.
60-
virtual void aboutToRunImmediately(CompilerInstance &instance);
61-
62-
// TODO: maybe enhance this interface to hear about IRGen and LLVM
63-
// progress.
6445
};
6546

6647
/// Perform all the operations of the frontend, exactly as if invoked

lib/FrontendTool/FrontendTool.cpp

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -960,9 +960,6 @@ static bool performCompile(CompilerInstance &Instance,
960960
if (Action == FrontendOptions::ActionType::ResolveImports)
961961
return Context.hadError();
962962

963-
if (observer)
964-
observer->performedSemanticAnalysis(Instance);
965-
966963
if (Stats)
967964
countStatsPostSema(*Stats, Instance);
968965

@@ -1051,10 +1048,6 @@ static bool performMandatorySILPasses(CompilerInvocation &Invocation,
10511048
} else if (!Invocation.getDiagnosticOptions().SkipDiagnosticPasses) {
10521049
if (runSILDiagnosticPasses(*SM))
10531050
return true;
1054-
1055-
if (observer) {
1056-
observer->performedSILDiagnostics(*SM);
1057-
}
10581051
} else {
10591052
// Even if we are not supposed to run the diagnostic passes, we still need
10601053
// to run the ownership evaluator.
@@ -1154,9 +1147,6 @@ static bool processCommandLineAndRunImmediately(CompilerInvocation &Invocation,
11541147
ProcessCmdLine(opts.ImmediateArgv.begin(), opts.ImmediateArgv.end());
11551148
Instance.setSILModule(std::move(SM));
11561149

1157-
if (observer)
1158-
observer->aboutToRunImmediately(Instance);
1159-
11601150
ReturnValue =
11611151
RunImmediately(Instance, CmdLine, IRGenOpts, Invocation.getSILOptions());
11621152
return Instance.getASTContext().hadError();
@@ -1243,9 +1233,6 @@ static bool performCompileStepsPostSILGen(
12431233
SILOptions &SILOpts = Invocation.getSILOptions();
12441234
IRGenOptions &IRGenOpts = Invocation.getIRGenOptions();
12451235

1246-
if (observer)
1247-
observer->performedSILGeneration(*SM);
1248-
12491236
if (Stats)
12501237
countStatsPostSILGen(*Stats, *SM);
12511238

@@ -1301,9 +1288,6 @@ static bool performCompileStepsPostSILGen(
13011288

13021289
performSILOptimizations(Invocation, SM.get());
13031290

1304-
if (observer)
1305-
observer->performedSILOptimization(*SM);
1306-
13071291
if (Stats)
13081292
countStatsPostSILOpt(*Stats, *SM);
13091293

@@ -1873,8 +1857,3 @@ int swift::performFrontend(ArrayRef<const char *> Args,
18731857

18741858
void FrontendObserver::parsedArgs(CompilerInvocation &invocation) {}
18751859
void FrontendObserver::configuredCompiler(CompilerInstance &instance) {}
1876-
void FrontendObserver::performedSemanticAnalysis(CompilerInstance &instance) {}
1877-
void FrontendObserver::performedSILGeneration(SILModule &module) {}
1878-
void FrontendObserver::performedSILDiagnostics(SILModule &module) {}
1879-
void FrontendObserver::performedSILOptimization(SILModule &module) {}
1880-
void FrontendObserver::aboutToRunImmediately(CompilerInstance &instance) {}

tools/swift-remoteast-test/swift-remoteast-test.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ printDynamicTypeAndAddressForExistential(void *object,
178178
namespace {
179179

180180
struct Observer : public FrontendObserver {
181-
void aboutToRunImmediately(CompilerInstance &instance) override {
181+
void configuredCompiler(CompilerInstance &instance) override {
182182
Context = &instance.getASTContext();
183183
}
184184
};

0 commit comments

Comments
 (0)