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

Improve interop performance against CLR list types #1792

Merged
merged 1 commit into from
Feb 25, 2024

Conversation

lahma
Copy link
Collaborator

@lahma lahma commented Feb 25, 2024

fixes #1772

Jint.Benchmark.ListInteropBenchmark

Diff Method Toolchain Mean Error Allocated
Old Filter Default 967.84 μs 12.909 μs 1935.49 KB
New Default 704.80 μs (-27%) 13.149 μs 973936 B (-51%)
Old Indexing Default 305.84 μs 4.030 μs 113.96 KB
New Default 263.17 μs (-14%) 3.922 μs 92667 B (-21%)
Old HasProperty Default 18.40 μs 0.246 μs 30.97 KB
New Default 11.17 μs (-39%) 0.090 μs 32 B (-100%)

@lahma lahma enabled auto-merge (squash) February 25, 2024 15:53
@lahma lahma merged commit 895b8d4 into sebastienros:main Feb 25, 2024
3 checks passed
@lahma lahma deleted the list-interop-perf branch February 25, 2024 15:54
return false;
}

private const int Count = 10_00;
Copy link
Owner

Choose a reason for hiding this comment

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

I used sharplab to be sure what it was ;) Now I am even more confused by the location of the _

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Hah, probably did some testing and forgot to remove the underscore which should be used as a thousand separator 😆

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.

Unexpected memory overflow/leak
2 participants