| The honest answer is: don't know yet, but if it doesn't happen in 1.0, it will be the priority for 1.1. I'm going to do some experiments in the next few days and see how it goes. Roughly, the way we're thinking of adding Windows support to Bun is: 1) Get all the Zig code using platform-specific system APIs to use the closest Windows equivalent API. Fortunately, we have lots of code for handling UTF-16 strings (since that's what JS uses in some cases) 2) Get uSockets/uWebSockets (C/C++ library we use for tcp & http serve) to compile for Windows, or fall back to using libuv if it takes too long to make it work 3) Get the rest of the dependencies to compile on Windows 4) Fix bugs and perf issues There are a lot of open questions though. None of us are super familiar with I/O on Windows. JavaScriptCore doesn't have WebAssembly enabled on Windows yet. The biggest thing I'm worried about (other than time) re: Windows is async i/o. In Bun, we _mostly_ use synchronous I/O. Synchronous I/O is simpler and when using SSDs, is often meaningfully lower overhead than the work necessary to make it async. I've heard that anti-virus software will often block I/O for potentially seconds, which means that using sync I/O at all is a super bad idea for performance in Windows (if this is true). If that is true, then making it fast will be difficult in cases where we need to do lots of filesystem lookups (like module resolution) |
Disclaimer: I work at Microsoft and ship code to Windows, but the above are just my personal opinions.