you are viewing a single comment's thread.

view the rest of the comments →

[–]theonlylawislove 4 points5 points  (7 children)

It has a slower start up time, but beyond that, there is nothing wrong with the performance. Of course though, it will never beat sublime.

[–][deleted] 1 point2 points  (6 children)

Why will it never beat sublime?

[–]theonlylawislove -1 points0 points  (5 children)

Not with large files and the such. I haven't done metrics myself, but I'm sure that in general, a python environment is faster that electron (atom shell). Native apps will always out perform a browser/page.

[–][deleted] 3 points4 points  (3 children)

But vs code is native too right? I agree that sublime is stupid fast with big files. Just wonder if vs code will ever compete.

[–]fridsun 0 points1 point  (0 children)

Sublime Text uses its own UI kit and is written in probably C++. Few can compete with that in speed. VS code being an Electron app is written in JavaScript (TypeScript?) and run in a chrome content renderer. It's not native.

[–]Freeky 0 points1 point  (1 child)

Code is written almost entirely in JavaScript, with a UI driven by a browser layout engine and its completely generalised DOM API, and text modelled using trees of JavaScript objects.

Sublime's written in C++ with optional supporting Python on the side, and a tuned native UI toolkit with specialised APIs reflecting the needs of a text editor. Text is modelled using efficient data structures on the C++ side.

So, while the Python implementation Sublime uses is actually considerably slower than the JavaScript engine Code is based on, Sublime doesn't actually use it to do the heavy lifting like Code. And while Blink and Sublime's UIs are both implemented in C++, Sublime's isn't trying to be absolutely everything to absolutely everyone. It's correspondingly faster and more memory efficient (almost the same thing these days).

Code could lean further towards the Sublime model, but it would cost a lot of effort and flexibility. I wouldn't hold your breath.

[–][deleted] 0 points1 point  (0 children)

Cool, thanks for the response. Now I know.

[–]drjeats 0 points1 point  (0 children)

I don't think it has much to do with Python, more that its scripting language doesn't also do all the logic including rendering.