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

Windows no std shim #46

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open

Windows no std shim #46

wants to merge 4 commits into from

Conversation

zsol
Copy link
Contributor

@zsol zsol commented Feb 8, 2025

This PR changes the windows shim to drop a lot of dependencies, shrinking the size of the final binary to 4KB.

It's 90% based on @zertosh's work, with a few changes:

  • stopped using a Vec and thus the need for a global allocator
  • A few extra places for error handling
  • Updated the dependencies (windows-sys and compiler_builtins)

@zertosh
Copy link
Contributor

zertosh commented Feb 9, 2025

Are you sure this is 4KB? I'll fiddle with Azure and try to get a VM.

Please excuse my bad github skills, I don't know how to do reviews here

@zsol
Copy link
Contributor Author

zsol commented Feb 9, 2025

Yup, pretty sure it's 4KB. GitHub and PowerShell both say so:

Length Name
------ ----
4096 dotslash_windows_shim-x86_64.exe

@facebook-github-bot
Copy link
Contributor

@zsol has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

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

Successfully merging this pull request may close these issues.

3 participants