Commit 54584ff 1 parent 76f292e commit 54584ff Copy full SHA for 54584ff
File tree 2 files changed +7
-0
lines changed
2 files changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -81,6 +81,8 @@ require "ruby_lsp/load_sorbet"
81
81
$LOAD_PATH. unshift ( File . expand_path ( "../lib" , __dir__ ) )
82
82
require "ruby_lsp/internal"
83
83
84
+ T ::Utils . run_all_sig_blocks
85
+
84
86
if options [ :debug ]
85
87
if [ "x64-mingw-ucrt" , "x64-mingw32" ] . include? ( RUBY_PLATFORM )
86
88
$stderr. puts "Debugging is not supported on Windows"
Original file line number Diff line number Diff line change @@ -876,6 +876,11 @@ def perform_initial_indexing
876
876
send_message ( Notification . window_show_error ( "Error while indexing: #{ error . message } " ) )
877
877
end
878
878
879
+ # Indexing produces a high number of short lived object allocations. That might lead to some fragmentation and
880
+ # an unnecessarily expanded heap. Compacting ensures that the heap is as small as possible and that future
881
+ # allocations and garbage collections are faster
882
+ GC . compact
883
+
879
884
# Always end the progress notification even if indexing failed or else it never goes away and the user has no
880
885
# way of dismissing it
881
886
end_progress ( "indexing-progress" )
You can’t perform that action at this time.
0 commit comments