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

epoll-test.epoll__invalid_op2 failed and epoll-test.epoll__epollhup_on_fresh_socket, epoll-test.epoll__epollpri tests where skipped #24

Open
advancedwebdeveloper opened this issue Nov 5, 2020 · 6 comments

Comments

@advancedwebdeveloper
Copy link

Hello.

Here is my situation:

make test

===> Testing for libepoll-shim-0.0.20200602
Test project /usr/ports/devel/libepoll-shim/work/.build
Total Test time (real) = 196.91 sec

The following tests did not run:
23 - epoll-test.epoll__epollhup_on_fresh_socket (Skipped)
25 - epoll-test.epoll__epollpri (Skipped)

The following tests FAILED:
6 - epoll-test.epoll__invalid_op2 (Failed)
Errors while running CTest
*** Error code 8

Stop.

I am on

#uname -a
FreeBSD gollvm.build.server 13.0-CURRENT FreeBSD 13.0-CURRENT #0 b9403d7aae8-c254071(main): Thu Oct 29 08:06:03 UTC 2020 [email protected]:/usr/obj/usr/src/amd64.amd64/sys/GENERIC amd64

@jiixyj
Copy link
Owner

jiixyj commented Nov 6, 2020

Thanks for the report! Can you run the test with further debug info (ctest -R 'epoll-test.epoll__invalid_op2' -VV) and post the output?

If you are building the port, you can disable that test (or all test) by modifying the ports Makefile in the do-test section (https://svnweb.freebsd.org/ports/head/devel/libepoll-shim/Makefile?revision=537573&view=markup#l21).

The skipped tests are mostly harmless, this is just a result of the epoll emulation not being 100% perfect.

@advancedwebdeveloper
Copy link
Author

make test

===> Testing for libepoll-shim-0.0.20200602
UpdateCTestConfiguration from :/usr/ports/devel/libepoll-shim/work/.build/DartConfiguration.tcl
Parse Config file:/usr/ports/devel/libepoll-shim/work/.build/DartConfiguration.tcl
UpdateCTestConfiguration from :/usr/ports/devel/libepoll-shim/work/.build/DartConfiguration.tcl
Parse Config file:/usr/ports/devel/libepoll-shim/work/.build/DartConfiguration.tcl
Test project /usr/ports/devel/libepoll-shim/work/.build
Constructing a list of tests
Done constructing a list of tests
Updating test list for fixtures
Added 0 tests to meet fixture requirements
Checking test dependency graph...
Checking test dependency graph end
test 6
Start 6: epoll-test.epoll__invalid_op2

6: Test command: /usr/local/bin/cmake "-D" "TEST_FOLDER_NAME=epoll-test.epoll__invalid_op2" "-D" "TEST_EXECUTABLE=/usr/ports/devel/libepoll-shim/work/.build/test/epoll-test" "-D" "TEST_NAME=epoll__invalid_op2" "-D" "BINARY_DIR=/usr/ports/devel/libepoll-shim/work/.build/test" "-D" "TIMEOUT=300" "-P" "/usr/ports/devel/libepoll-shim/work/epoll-shim-3840e9c/test/cmake/ATFRunTest.cmake"
6: Test timeout computed to be: 0
6: -- result: 0, passed
1/1 Test #6: epoll-test.epoll__invalid_op2 .... Passed 39.34 sec

The following tests passed:
epoll-test.epoll__invalid_op2

100% tests passed, 0 tests failed out of 1

Total Test time (real) = 39.40 sec

@jiixyj
Copy link
Owner

jiixyj commented Nov 6, 2020

Weird, looks like the test is passing now...

@advancedwebdeveloper
Copy link
Author

Probably the problem is in the configuration file.

What about those 2 skipped tests?
Do you lack anything in your shim, to make it work?

@jiixyj
Copy link
Owner

jiixyj commented Nov 6, 2020

Sometimes there are inherent limitations in kqueue or the various BSDs that make 100% exact emulation impossible. For example, emulation for EPOLLPRI (out of band socket data) is only possible on DragonFlyBSD which implements EVFILT_EXCEPT. On FreeBSD we can emulate it in level-triggered mode using normal poll and POLLPRI, but edge-triggered epoll requires more kernel support.

The most common use cases should be supported, however.

@advancedwebdeveloper
Copy link
Author

advancedwebdeveloper commented Nov 7, 2020

I see.

What about if you can help with external task, like geeting rid of epoll abstraction + the shim, for porting libbacktrace, to FreeBSD 13.0?

So it would be possible to deal with kqueue directly.

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

No branches or pull requests

2 participants