Found that it's not easy to use the ide-swift extension because lots of SourceKitten processes are started on any change. Here just tracking a previous SourceKitten process inside the IdeSwiftAutocompleteProvider class and killing it right before creating a new process reduces the CPU usage a lot.
I'm not familiar with all the Atom APIs, but if it's possible to also kill the SourceKitService processed spawned by the SourceKitten (kill the process tree), it can help to make it even better.
Found that it's not easy to use the
ide-swift
extension because lots of SourceKitten processes are started on any change. Here just tracking a previous SourceKitten process inside theIdeSwiftAutocompleteProvider
class and killing it right before creating a new process reduces the CPU usage a lot.I'm not familiar with all the Atom APIs, but if it's possible to also kill the SourceKitService processed spawned by the SourceKitten (kill the process tree), it can help to make it even better.