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

feat: add benchmarks #92

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Conversation

TimothyMakkison
Copy link

@TimothyMakkison TimothyMakkison commented Jan 2, 2025

Add benchmarks for reading and writing TOML

Basic benchmarks

Method Mean Error StdDev Median Allocated
StringToModel 51.270 us 2.3102 us 6.5160 us 49.579 us 52.6 KB
ModelToString 7.249 us 0.1430 us 0.2985 us 7.128 us 9.45 KB

Twitter.toml

Method Mean Error StdDev Allocated
StringToModel 80.621 ms 2.9600 ms 8.2021 ms 22.79 MB
ModelToString 4.922 ms 0.1049 ms 0.2836 ms 3.21 MB

@TimothyMakkison TimothyMakkison marked this pull request as draft January 2, 2025 22:57
@TimothyMakkison TimothyMakkison marked this pull request as ready for review January 3, 2025 18:15
@xoofx
Copy link
Owner

xoofx commented Jan 5, 2025

Nice, thanks! Could you add another benchmark for parsing a TOML to a DocumentSyntax (via Toml.Parse) and saving it back to a string?

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.

2 participants