Open Zanndorin opened 1 year ago
Does it still happen if you disable hardware acceleration using the setting "hardware_acceleration": "none"
?
I am a little bit of a noob regarding the settings but this was already set by default. I don't know what platform specific settings they are referring to
There's platform specific settings for macOS that override the default to be "opengl"
. Set it in your user settings to "none"
and it will disable hardware acceleration.
So I add the hardware_acceleration option to the Preference.sublime_settings on the right that show up when i open Settings? Tried googling it.
Seems like that did the trick at least. In that case at least me and my colleague have this issue with openGL, not sure if I can give you any further feedback.
If that fixes it then there's likely an OpenGL driver bug in Sonoma (Might be worth reporting to Apple).
If you re-enable opengl and enable fps logging by going to View > Show Console and entering sublime.log_fps(True)
, what gets logged in the console?
It is a bit hard to trigger but something like this
fps: 59.1 average: 4ms
fps: 42.4 average: 4ms
fps: 51.3 average: 4ms
fps: 33.9 average: 4ms
fps: 48.8 average: 3ms
fps: 7.5 average: 3ms <- Here opengl is turned on
Frame time exceeded 60hz: 17ms
fps: 2.6 average: 3ms
fps: 1.4 average: 7ms
Frame time exceeded 60hz: 17ms
fps: 8 average: 4ms
Frame time exceeded 60hz: 17ms
fps: 19.7 average: 2ms
Just to make sure: Did you restart Sublime Text after changing the setting?
Yes, at first at least because later on i noticed that it does not matter ( at least when turning it on, as seen in the logs). And then the options also gigalag which makes it really hard.
That setting only takes effect when restarting Sublime Text.
I understand that is how it should be. But the FPS going from ~50 to 3 without me restarting only to add the string, maybe it's some autosave bug in that case?
Is Sublime Text using a lot of CPU? You can check using the activity monitor.
This time I had to restart to trigger the lag after removing the option.
It uses quite a bit, not sure what would count as a lot. It spikes to 26-30% in the worst of lags but then goes low again.
It takes more when running with the HW acceleration disabled. But does not lag. (40+)
Are you doing anything specific, like having a folder open, or is it lagging with just an empty window?
No I just have a single file (well normally multiple files, but that does not seem to matter) open (just text (txt)). It does not seem to matter if I have multiple files or anything like that. The size of the file is normal to small 1k-4k chars.
It worked perfect before the Sonoma upgrade and the hw_disable seems to fix it so I'm not sure if additional input isn't just guessing from my side.
Can you provide the full logs from the console please? (View > Show Console)
For when I do what? Just start and running in hw disabled?
startup, version: 4152 osx arm64 channel: stable executable: /Applications/Sublime Text.app/Contents/MacOS/sublime_text application: /Applications/Sublime Text.app working dir: /
<removed some private paths for zip, state etc>
ignored_packages: ["Vintage"] pre session restore time: 0.229527 startup time: 0.245734 first paint time: 0.29044 environment variables loaded using: /bin/zsh -l reloading python 3.3 plugin 0_package_control_loader.00-package_control reloading plugin Default.arithmetic reloading python 3.3 plugin 0_package_control_loader.01-pygments reloading plugin Default.auto_indent_tag reloading plugin Default.block reloading python 3.3 plugin 0_package_control_loader.50-pymdownx reloading python 3.3 plugin 0_package_control_loader.50-python-markdown reloading python 3.3 plugin 0_package_control_loader.50-pyyaml reloading plugin Default.colors reloading python 3.3 plugin JsFormat.js_formatter reloading plugin Default.comment reloading plugin Default.convert_color_scheme reloading plugin Default.convert_syntax reloading plugin Default.copy_path reloading plugin Default.echo reloading plugin Default.exec reloading plugin Default.fold reloading plugin Default.font reloading plugin Default.goto_line reloading plugin Default.history_list reloading plugin Default.html_print reloading plugin Default.indentation reloading plugin Default.install_package_control reloading python 3.3 plugin JSON Reindent.sublime_json_reindent reloading plugin Default.keymap reloading plugin Default.kill_ring reloading plugin Default.mark reloading plugin Default.new_templates reloading plugin Default.open_context_url reloading plugin Default.open_in_browser reloading plugin Default.pane reloading plugin Default.paragraph reloading plugin Default.paste_from_history reloading plugin Default.profile reloading plugin Default.quick_panel reloading plugin Default.rename reloading plugin Default.run_syntax_tests reloading plugin Default.save_on_focus_lost reloading plugin Default.scroll reloading plugin Default.set_unsaved_view_name reloading plugin Default.settings reloading plugin Default.show_scope_name reloading plugin Default.side_bar reloading plugin Default.sort reloading plugin Default.switch_file reloading plugin Default.symbol reloading plugin Default.transform reloading plugin Default.transpose reloading plugin Default.ui reloading plugin CSS.css_completions reloading plugin Diff.diff reloading plugin HTML.encode_html_entities reloading plugin HTML.html_completions reloading plugin MarkdownEditing.plugin reloading python 3.3 plugin MarkdownPreview.browser reloading python 3.3 plugin MarkdownPreview.markdown_preview reloading python 3.3 plugin MarkdownPreview.markdown_settings reloading python 3.3 plugin MarkdownPreview.markdown_wrapper reloading python 3.3 plugin Package Control.1_reloader reloading python 3.3 plugin Package Control.2_bootstrap reloading python 3.3 plugin Package Control.Package Control plugins loaded Package Control: No updated packages
@kaerntna what hardware do you have?
这里同样的问题。设置“hardware_acceleration”:“disabled”暂时可以解决问题。
thx. u just solved my problem which is same to this issue.
From sonoma 14.1 with m3pro chip
is that a problem with apple silicon or sublime text4? @BenjaminSchaaf
As I said upthread:
If that fixes it then there's likely an OpenGL driver bug in Sonoma (Might be worth reporting to Apple).
I am a little bit of a noob regarding the settings but this was already set by default. I don't know what platform specific settings they are referring to
I had the same issue immediately after updating from Sonoma 14.0 to 14.1.1 on an M2 MacBook Pro - it made Sublime unusable.
Changing this setting fixed it for me.
I now get "Frame time exceeded 60hz" (vs 20fps at best often dropping to 5 when trying to select text before disabling opengl) when logging the framerate
Same exactly problem here. I have a M3 Max laptop, 36 GB memory, Sonoma 14.1.1. Disabling hardware accel fixes it.
Interestingly this lag only happens on the laptop display due to the higher resolution. On my two attached 1080 monitors it doesn't lag. Seems related to resolution.
TLDR: setting "hardware_acceleration": "disabled",
solved everything! Otherwise I was getting terrible framerates and extreme lagginess.
I'm so glad I found this, I thought that I was going mad. Especially because it seemed like Sublime was working perfectly fine on my M3 for a few days. A Sonoma update might have happened in the meantime?
Importantly, this only happened on external monitors. I tried usb-c, hdmi, different monitors (apple studio pro and viewsonic 4k), switching which ports/sides the monitors were connected to, etc. Nothing made a difference.
Debugging info below, hopefully it can help.
Sonoma 14.3.1, M3 Max on a MBP 16-inch.
startup, version: 4169 osx arm64 channel: stable
executable: /Applications/Sublime Text.app/Contents/MacOS/sublime_text
application: /Applications/Sublime Text.app
working dir: /
packages path: /Users/greg/Library/Application Support/Sublime Text/Packages
state path: /Users/greg/Library/Application Support/Sublime Text/Local
zip path: /Applications/Sublime Text.app/Contents/MacOS/Packages
zip path: /Users/greg/Library/Application Support/Sublime Text/Installed Packages
ignored_packages: ["Vintage"]
pre session restore time: 0.208255
OpenGL Context Information:
GL API Version: 4.1 Metal - 88
GLSL Version: 4.10
Vendor: Apple
Renderer: Apple M3 Max
startup time: 0.250135
first paint time: 0.255161
environment variables loaded using: /bin/zsh -l
reloading plugin Default.arithmetic
reloading plugin Default.auto_indent_tag
reloading plugin Default.block
reloading plugin Default.colors
reloading plugin Default.comment
reloading plugin Default.convert_color_scheme
reloading plugin Default.convert_syntax
reloading plugin Default.copy_path
reloading plugin Default.echo
reloading plugin Default.exec
reloading plugin Default.fold
reloading plugin Default.font
reloading plugin Default.goto_line
reloading plugin Default.history_list
reloading plugin Default.html_print
reloading plugin Default.indentation
reloading plugin Default.install_package_control
reloading plugin Default.keymap
reloading plugin Default.kill_ring
reloading plugin Default.mark
reloading plugin Default.new_templates
reloading plugin Default.open_context_url
reloading plugin Default.open_in_browser
reloading plugin Default.pane
reloading plugin Default.paragraph
reloading plugin Default.paste_from_history
reloading plugin Default.profile
reloading plugin Default.quick_panel
reloading plugin Default.rename
reloading plugin Default.run_syntax_tests
reloading plugin Default.save_on_focus_lost
reloading plugin Default.scroll
reloading plugin Default.set_unsaved_view_name
reloading plugin Default.settings
reloading plugin Default.show_scope_name
reloading plugin Default.side_bar
reloading plugin Default.sort
reloading plugin Default.switch_file
reloading plugin Default.symbol
reloading plugin Default.transform
reloading plugin Default.transpose
reloading plugin Default.ui
reloading plugin CSS.css_completions
reloading plugin Diff.diff
reloading plugin HTML.encode_html_entities
reloading plugin HTML.html_completions
plugins loaded
>>> sublime.log_fps(True)
Frame time exceeded 60hz: 38ms
fps: 1.8 average: 15ms
Frame time exceeded 60hz: 42ms
fps: 70.9 average: 1ms
fps: 109.9 average: 1ms
fps: 24.6 average: 2ms
fps: 7.2 average: 5ms
Frame time exceeded 60hz: 36ms
fps: 4.5 average: 5ms
Frame time exceeded 60hz: 35ms
fps: 32.9 average: 2ms
fps: 110.8 average: 1ms
fps: 53.8 average: 1ms
fps: 72.7 average: 2ms
fps: 121.6 average: 1ms
fps: 3.2 average: 5ms
Frame time exceeded 60hz: 18ms
fps: 7.2 average: 3ms
Frame time exceeded 60hz: 23ms
fps: 4.4 average: 1ms
fps: 15.7 average: 1ms
fps: 0.9 average: 18ms
Frame time exceeded 60hz: 37ms
fps: 1.8 average: 2ms
fps: 15.7 average: 2ms
fps: 0.5 average: 10ms
Frame time exceeded 60hz: 21ms
The same issue with an external display and an enabled setting "Displays have separate Spaces"
I have 2 external monitors. A vertical one, a horizontal one, and my laptop. Both connected via DisplayPort to a KVM, then a DisplayPort to USB-C connector.
When Sublime is on my vertical monitor, IN ENTIRETY, it is exceptionally laggy. I might get 4 or 5 keystrokes relatively quickly, and then go 5-10 seconds without any updates. If even a few pixels of the window stretch out of the vertical monitor, it is totally fine. I have this without separate spaces enabled, but I believe it had the issue with that enabled as well.
I started experiencing this when I attached two Apple Studio monitors to my M3 Max Macbook Pro. Sublime was laggy beyond use. Switching to "hardware_acceleration": "disabled"
seems to have "fixed" the issue.
Description of the bug
So since the OS upgrade to Sonoma my Sublime has been lagging immensly and is unusable. I cannot mark text with the mouse or move with the direction keys without it lagging a lot.
I have this issue both in Safe Mod and when I did a fresh install.
This happens with 1 file open or multiple. I have only .txt files (and sometimes a JSON file).
It does not lag when scrolling but it lags a lot when trying to mark text
It worked without any issues before Sonoma upgrade.
Sorry that I cannot provide any more here. I'm not sure what to do. At the moment I have stopped using Sublime completely.
Steps to reproduce
Expected behavior
It to not lag
Actual behavior
Lags A LOT
Sublime Text build number
startup, version: 4152 osx arm64 channel: stable
Operating system & version
M2 16GB Sonoma 14.0
(Linux) Desktop environment and/or window manager
No response
Additional information
No response
OpenGL context information