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

perf(test): lower base overhead to <1ms #20082

Closed
wants to merge 3 commits into from

Conversation

bartlomieju
Copy link
Member

@bartlomieju bartlomieju commented Aug 7, 2023

This PR changes how op sanitizer is run to only wait for an event loop tick
if there are unresolved ops. In most cases tests are finishing okay and don't
have leaky ops (unless there are workers or timers) involved. In such case
we can skip waiting for the macrotask callback and lower the base overhead
from ~3ms to ~1ms.

Copy link
Collaborator

@aapoalas aapoalas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tests fail :(

@nayeemrmn
Copy link
Collaborator

Turns out the Deno.test("uncaught error", () => { Promise.reject(...) }) test case was depending on the op sanitizer delay. This is addressed by denoland/deno_core#137.

@nayeemrmn
Copy link
Collaborator

failures:
    integration::js_unit_tests::fetch_test
    integration::js_unit_tests::http_test
    integration::js_unit_tests::serve_test
    integration::node_compat_tests::node_test_module

For integration::node_compat_tests::node_test_module see the patch in denoland/deno_core#137 (comment). The rest seem to be from this.

@bartlomieju
Copy link
Member Author

@nayeemrmn any chance you could try to debug the problem?

cli/js/40_testing.js Outdated Show resolved Hide resolved
@bartlomieju
Copy link
Member Author

Closing in favor of #20501

@bartlomieju bartlomieju deleted the test_sanitizer_delay branch September 15, 2023 12:14
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.

4 participants