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

eio_linux: add work-around for signals race #734

Merged
merged 1 commit into from
May 26, 2024

Conversation

talex5
Copy link
Collaborator

@talex5 talex5 commented May 23, 2024

This is a quick fix for #732.

A proper fix would be quite involved and I'd like to get feedback from the OCaml devs about fixing it upstream first, but this work-around fixes the regression relative to Eio 1.0, which should be enough to make a new release.

@talex5 talex5 merged commit 2c5eb61 into ocaml-multicore:main May 26, 2024
4 of 5 checks passed
@talex5 talex5 deleted the fix-signal-race branch May 26, 2024 13:38
talex5 added a commit to talex5/opam-repository that referenced this pull request May 28, 2024
CHANGES:

New features:

- Add `Eio.Path.symlink` (@patricoferris ocaml-multicore/eio#715, reviewed by @talex5).

- Add `Eio.Pool.use ~never_block` (@SGrondin ocaml-multicore/eio#657, reviewed by @talex5).

- Add `Eio_unix.Net.import_socket_listening` (@alyssais ocaml-multicore/eio#733).

- Add `Eio.Time.Timeout.sleep` (@talex5 ocaml-multicore/eio#726).

Documentation:

- Add `examples/fs` showing how to walk a directory tree (@talex5 ocaml-multicore/eio#730).

- README: explain that `read_all` reads until shutdown (@talex5 ocaml-multicore/eio#717, reported by @Wenke-D).

- Use long dash in README title (@lucperkins ocaml-multicore/eio#718).

Linux backend:

- Require Linux >= 5.15 (@talex5 ocaml-multicore/eio#720, reviewed by @SGrondin and @avsm).
  Removes a work-around that required checking whether every flow was a tty.

- Don't call submit immediately before wait (@talex5 ocaml-multicore/eio#728).
  This is slightly faster and makes the traces clearer.

- Don't record submit events when there's nothing to submit (@talex5 ocaml-multicore/eio#729).
  Makes the traces a bit clearer.

- Split flow into its own file (@talex5 ocaml-multicore/eio#727).

- Add work-around for signals race (@talex5 ocaml-multicore/eio#734).

POSIX backend:

- Add `_BSD_SOURCE` flag to fix build on OpenBSD (@prgbln ocaml-multicore/eio#722).

- Fix sandboxed path resolution on OpenBSD (@jebrosen ocaml-multicore/eio#723, reviewed by @talex5).
  OpenBSD uses `ELOOP` when opening a symlink with `O_NOFOLLOW`.

Build and test:

- Benchmarks: record uname, Eio backend, and number of cores (@talex5 ocaml-multicore/eio#719).

- Update to MDX 2.4.1 for OCaml 5.2 (@talex5 ocaml-multicore/eio#712).
talex5 added a commit to talex5/opam-repository that referenced this pull request May 28, 2024
CHANGES:

New features:

- Add `Eio.Path.symlink` (@patricoferris ocaml-multicore/eio#715, reviewed by @talex5).

- Add `Eio.Pool.use ~never_block` (@SGrondin ocaml-multicore/eio#657, reviewed by @talex5).

- Add `Eio_unix.Net.import_socket_listening` (@alyssais ocaml-multicore/eio#733, reviewed by @talex5).

- Add `Eio.Time.Timeout.sleep` (@talex5 ocaml-multicore/eio#726).

Documentation:

- Add `examples/fs` showing how to walk a directory tree (@talex5 ocaml-multicore/eio#730).

- README: explain that `read_all` reads until shutdown (@talex5 ocaml-multicore/eio#717, reported by @Wenke-D).

- Use long dash in README title (@lucperkins ocaml-multicore/eio#718).

Linux backend:

- Require Linux >= 5.15 (@talex5 ocaml-multicore/eio#720, reviewed by @SGrondin and @avsm).
  Removes a work-around that required checking whether every flow was a tty.

- Don't call submit immediately before wait (@talex5 ocaml-multicore/eio#728).
  This is slightly faster and makes the traces clearer.

- Don't record submit events when there's nothing to submit (@talex5 ocaml-multicore/eio#729).
  Makes the traces a bit clearer.

- Split flow into its own file (@talex5 ocaml-multicore/eio#727).

- Add work-around for signals race (@talex5 ocaml-multicore/eio#734).

POSIX backend:

- Add `_BSD_SOURCE` flag to fix build on OpenBSD (@prgbln ocaml-multicore/eio#722).

- Fix sandboxed path resolution on OpenBSD (@jebrosen ocaml-multicore/eio#723, reviewed by @talex5).
  OpenBSD uses `ELOOP` when opening a symlink with `O_NOFOLLOW`.

Build and test:

- Benchmarks: record uname, Eio backend, and number of cores (@talex5 ocaml-multicore/eio#719).

- Update to MDX 2.4.1 for OCaml 5.2 (@talex5 ocaml-multicore/eio#712).
avsm pushed a commit to avsm/opam-repository that referenced this pull request Sep 5, 2024
CHANGES:

New features:

- Add `Eio.Path.symlink` (@patricoferris ocaml-multicore/eio#715, reviewed by @talex5).

- Add `Eio.Pool.use ~never_block` (@SGrondin ocaml-multicore/eio#657, reviewed by @talex5).

- Add `Eio_unix.Net.import_socket_listening` (@alyssais ocaml-multicore/eio#733, reviewed by @talex5).

- Add `Eio.Time.Timeout.sleep` (@talex5 ocaml-multicore/eio#726).

Documentation:

- Add `examples/fs` showing how to walk a directory tree (@talex5 ocaml-multicore/eio#730).

- README: explain that `read_all` reads until shutdown (@talex5 ocaml-multicore/eio#717, reported by @Wenke-D).

- Use long dash in README title (@lucperkins ocaml-multicore/eio#718).

Linux backend:

- Require Linux >= 5.15 (@talex5 ocaml-multicore/eio#720, reviewed by @SGrondin and @avsm).
  Removes a work-around that required checking whether every flow was a tty.

- Don't call submit immediately before wait (@talex5 ocaml-multicore/eio#728).
  This is slightly faster and makes the traces clearer.

- Don't record submit events when there's nothing to submit (@talex5 ocaml-multicore/eio#729).
  Makes the traces a bit clearer.

- Split flow into its own file (@talex5 ocaml-multicore/eio#727).

- Add work-around for signals race (@talex5 ocaml-multicore/eio#734).

POSIX backend:

- Add `_BSD_SOURCE` flag to fix build on OpenBSD (@prgbln ocaml-multicore/eio#722).

- Fix sandboxed path resolution on OpenBSD (@jebrosen ocaml-multicore/eio#723, reviewed by @talex5).
  OpenBSD uses `ELOOP` when opening a symlink with `O_NOFOLLOW`.

Build and test:

- Benchmarks: record uname, Eio backend, and number of cores (@talex5 ocaml-multicore/eio#719).

- Update to MDX 2.4.1 for OCaml 5.2 (@talex5 ocaml-multicore/eio#712).
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.

1 participant