Skip to content
Snippets Groups Projects
  1. Feb 01, 2024
  2. Jan 31, 2024
  3. Jan 29, 2024
  4. Jan 26, 2024
  5. Jan 25, 2024
  6. Jan 24, 2024
  7. Jan 20, 2024
  8. Jan 19, 2024
  9. Jan 18, 2024
  10. Jan 17, 2024
    • Cheng Shao's avatar
      base: treat all FDs as "nonblocking" on wasm · 2eca52b4
      Cheng Shao authored
      On posix platforms, when performing read/write on FDs, we check the
      nonblocking flag first. For FDs without this flag (e.g. stdout), we
      call fdReady() first, which in turn calls poll() to wait for I/O to be
      available on that FD. This is problematic for wasm32-wasi: although
      select()/poll() is supported via the poll_oneoff() wasi syscall, that
      syscall is rather heavyweight and runtime behavior differs in
      different wasi implementations. The issue is even worse when targeting
      browsers, given there's no satisfactory way to implement async I/O as
      a synchronous syscall, so existing JS polyfills for wasi often give up
      and simply return ENOSYS.
      
      Before we have a proper I/O manager that avoids poll_oneoff() for
      async I/O on wasm, this patch improves the status quo a lot by merely
      pretending all FDs are "nonblocking". Read/write on FDs will directly
      invoke read()/write(), which are much more reliably handled in
      existing wasi implementations, especially those in browsers.
      
      Fixes #23275 and the following test cases: T7773 isEOF001 openFile009
      T4808 cgrun025
      
      Approved by CLC proposal #234:
      https://github.com/haskell/core-libraries-committee/issues/234
      2eca52b4
    • Cheng Shao's avatar
      ci: bump ci-images for updated wasm image · 320454d3
      Cheng Shao authored
      320454d3
    • Matthew Pickering's avatar
      Update nofib submodule · 7f0879e1
      Matthew Pickering authored and Marge Bot's avatar Marge Bot committed
      7f0879e1
Loading