Skip to content

The event tests hang on FreeBSD #3251

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

Open
ghost opened this issue Sep 19, 2019 · 2 comments
Open

The event tests hang on FreeBSD #3251

ghost opened this issue Sep 19, 2019 · 2 comments
Labels
bug Observed behavior contradicts documented or intended behavior os-freebsd standard library This issue involves writing Zig code for the standard library.
Milestone

Comments

@ghost
Copy link

ghost commented Sep 19, 2019

Currently on FreeBSD, when running the test-std test, it hangs at this line:

309/1219 event.channel.test "std-freebsd-x86_64-Debug-bare-multi std.event.Channel"...

Also, @mikdusan on irc said he was able to replicate this issue and he thought it had to do with kevent.

Update: These tests also hang.

310/1218 event.future.test "std-freebsd-x86_64-Debug-bare-multi std.event.Future"...
312/1218 event.lock.test "std-freebsd-x86_64-Debug-bare-multi std.event.Lock"...
@andrewrk andrewrk added bug Observed behavior contradicts documented or intended behavior os-freebsd standard library This issue involves writing Zig code for the standard library. labels Sep 19, 2019
@andrewrk andrewrk added this to the 0.6.0 milestone Sep 19, 2019
@andrewrk
Copy link
Member

This issue is blocking #1759

@ghost ghost changed the title The event.channel.test hangs on FreeBSD The event tests hangs on FreeBSD Sep 19, 2019
@ghost ghost changed the title The event tests hangs on FreeBSD The event tests hang on FreeBSD Sep 19, 2019
@jethron
Copy link
Contributor

jethron commented Dec 29, 2019

This looks to be odd behaviour in kevent when you specify EV_CLEAR with NOTE_TRIGGER. When you trigger the event with EV_CLEAR, you can't read it back off the queue again, so the next kevent call just blocks forever. Changing this to just EV_ENABLE seems to fix the blocking.

Still doesn't pass all tests though, std.event.Lock test still fails (sometimes, same as Linux, aborts with SIGBUS) and std.event.Channel tests fail most of the time as well, so not sure if this is 100% the correct fix... Future and Group pass consistently, though.

@andrewrk andrewrk modified the milestones: 0.6.0, 0.7.0 Mar 12, 2020
@andrewrk andrewrk modified the milestones: 0.7.0, 0.8.0 Oct 30, 2020
@andrewrk andrewrk modified the milestones: 0.8.0, 0.8.1 Jun 4, 2021
@andrewrk andrewrk modified the milestones: 0.8.1, 0.9.1 Sep 1, 2021
@andrewrk andrewrk modified the milestones: 0.9.1, 0.9.0, 0.10.0 Nov 20, 2021
@andrewrk andrewrk modified the milestones: 0.10.0, 0.11.0 Apr 16, 2022
@andrewrk andrewrk modified the milestones: 0.11.0, 0.12.0 Apr 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Observed behavior contradicts documented or intended behavior os-freebsd standard library This issue involves writing Zig code for the standard library.
Projects
None yet
Development

No branches or pull requests

2 participants