WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Sharing a Uring from a Parent to a Child Process #801

@patricoferris

Description

@patricoferris

Hi!

Whilst trying to add some tests for an OCaml library I ran into this weird bug with Eio_linux. The smallest reproducible I have right now is the following code:

let test fs _ =
  ignore (Eio.Path.(load (fs / "./README.md")))

let suite fs =
  let open OUnit2 in
  "Tess" >:: (test fs)


let () = 
  Eio_linux.run @@ fun env ->
  OUnit2.run_test_tt_main (suite env#fs)

On my machine this program hangs.

% uname -rv
6.6.82 #1-NixOS SMP PREEMPT_DYNAMIC Sun Mar  9 08:55:04 UTC 202

Switching to Eio_posix and everything is good again.


I've been trying to debug this and so far I have the following findings:

  • We get stuck in a Uring.cancel that can never get placed on the queue as there is no space.
  • The Uring submission queue seems to be completely full and perhaps if I left it running long enough it will complete, but something is going wrong and that shouldn't happen. This could be a ocaml-uring bug. By completely full it seems sqe_ready is reporting 4294967165 which doesn't seem right either, perhaps there is some corruption going on there or something.

Happy to help debug this if there are any pointers :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions