@@ -327,6 +327,10 @@ package actor SwiftPMBuildSystem: BuiltInBuildSystem {
327327 ///
328328 /// - Important: Must only be called on `packageLoadingQueue`.
329329 private func reloadPackageAssumingOnPackageLoadingQueue( ) async throws {
330+ let signposter = logger. makeSignposter ( )
331+ let signpostID = signposter. makeSignpostID ( )
332+ let state = signposter. beginInterval ( " Reloading package " , id: signpostID, " Start reloading package " )
333+
330334 self . connectionToSourceKitLSP. send (
331335 TaskStartNotification (
332336 taskId: TaskId ( id: " package-reloading " ) ,
@@ -349,6 +353,8 @@ package actor SwiftPMBuildSystem: BuiltInBuildSystem {
349353 observabilityScope: observabilitySystem. topScope. makeChildScope ( description: " Load package graph " )
350354 )
351355
356+ signposter. emitEvent ( " Finished loading modules graph " , id: signpostID)
357+
352358 let plan = try await BuildPlan (
353359 destinationBuildParameters: destinationBuildParameters,
354360 toolsBuildParameters: toolsBuildParameters,
@@ -357,6 +363,9 @@ package actor SwiftPMBuildSystem: BuiltInBuildSystem {
357363 fileSystem: localFileSystem,
358364 observabilityScope: observabilitySystem. topScope. makeChildScope ( description: " Create SwiftPM build plan " )
359365 )
366+
367+ signposter. emitEvent ( " Finished generating build plan " , id: signpostID)
368+
360369 let buildDescription = BuildDescription ( buildPlan: plan)
361370 self . buildDescription = buildDescription
362371
@@ -380,7 +389,10 @@ package actor SwiftPMBuildSystem: BuiltInBuildSystem {
380389 swiftPMTargets [ targetIdentifier] = buildTarget
381390 }
382391
392+ signposter. emitEvent ( " Finished traversing modules " , id: signpostID)
393+
383394 connectionToSourceKitLSP. send ( OnBuildTargetDidChangeNotification ( changes: nil ) )
395+ signposter. endInterval ( " Reloading package " , state)
384396 }
385397
386398 package nonisolated var supportsPreparation : Bool { true }
0 commit comments