Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revamp loading #795

Closed
wants to merge 6 commits into from
Closed

Revamp loading #795

wants to merge 6 commits into from

Conversation

code-asher
Copy link
Member

@code-asher code-asher commented Jun 19, 2019

Server

  • Remove Webpack on the server. Instead we just require using native Node plus tsconfig-paths which hooks in and tells Node how to resolve our aliases. Pretty much as clean as it gets, no loader or bundler required.
  • For forking VS Code processes, we just use their loader as-is without any changes. This means we don't have to patch anything, and things like language support should just work. It also means we should be able to plug in any version of VS Code at will.
  • Fix "undefined symbol" error when importing spdlog and other native modules.
  • Might have some problems with dependencies nested in the packages directory since files get moved into an out directory.
  • There might be a few things to check out due to no longer patching that we should work around in other ways (for example the extension host has some exit condition we had to comment out).

Client

  • Greatly simplify client-side Webpack configuration (or use another bundler). It shouldn't touch anything from VS Code. Eventually we will be able to get rid of it entirely, but not in this PR. These changes should at least make it very simple to remove as well as make it build much, much faster.
  • For loading VS Code, we just use their loader to run the main workbench file and let their loader do all the work, so hopefully no more patching and working language support. We will still have injected overrides.

General

  • If a pre-built VS Code isn't available, it'll just clone and build it which should make testing new versions locally much easier.
  • Optimized version of VS Code is bundled, so we should now have a minimal bundle size.
  • Build times are far faster now (around 7 seconds to build and nearly instant changes while watching).
  • Debugging will probably be much easier now.
  • Bundling should exclude source maps (we could host them, that's what VS Code does).
  • Update/write docs on developing. Should be much, much easier now. Essentially there will be just yarn plus one command to run for either building (yarn build) or jumping into development (yarn watch).

@code-asher code-asher force-pushed the perf/loader branch 3 times, most recently from a3e0c61 to 35c9fd1 Compare June 20, 2019 15:43
@sr229
Copy link
Contributor

sr229 commented Jun 22, 2019

My main concern is still performance and this is mostly by the GC of Node. By default GC is very lazy so we can force GC intervals to have a more optimized code base so "hopefully" we can finally run this on Raspberry systems with 512MB memory.

so by default I want to nominate the following flags to be automatically appended to the node binary invocation:

  • --max-executable-size=96
  • --max-old-space-size=128
  • --max-semi-space-size=1
  • --jitless

@code-asher
Copy link
Member Author

Made obsolete by #857.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants