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: avoid triggering a TSan warning #754

Merged
merged 1 commit into from
Sep 7, 2024

Conversation

talex5
Copy link
Collaborator

@talex5 talex5 commented Sep 6, 2024

TSan warns that setting statx_works races with users of it. This isn't really a problem, because we always set it to the same value, but it's distracting when looking for other bugs.

Reported by @avsm in #751.

Test-case:

open Eio.Std

let () =
  Eio_main.run @@ fun env ->
  Fiber.both
    (fun () ->
       Eio.Domain_manager.run env#domain_mgr (fun () -> Eio_unix.sleep 100.);
    )
    (fun () ->
       while true do
         ignore (Eio.Path.stat ~follow:false (Eio.Stdenv.cwd env) : Eio.File.Stat.t)
       done
    )

TSan warns that setting `statx_works` races with users of it. This isn't
really a problem, because we always set it to the same value, but it's
distracting when looking for other bugs.

Reported by Anil Madhavapeddy in ocaml-multicore#751.
@talex5 talex5 merged commit 534f89c into ocaml-multicore:main Sep 7, 2024
5 checks passed
@talex5 talex5 deleted the quiet-tsan branch September 7, 2024 13:06
@avsm
Copy link
Contributor

avsm commented Sep 9, 2024

This is very handy to filter out the noise, thanks!

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