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

fix: actually use the size hint in util_windows.go #109

Merged
merged 1 commit into from
Oct 15, 2023

Conversation

Jorropo
Copy link
Contributor

@Jorropo Jorropo commented Aug 2, 2022

This code was broken, it computed the size hint to do nothing with it.

Found with this profile:
Capture d’écran du 2022-08-02 15-40-33

This profile clearly show a pattern of append's growth.
With this new code the only way to append is if the size hint undershoot (which would require more data to be written between the Size and Read calls). Might be worth a panic("race") or returning an error if that happen ?

@welcome

This comment was marked as resolved.

@Jorropo Jorropo force-pushed the fix/windows_alloc_hint branch 2 times, most recently from f990071 to 669f34a Compare August 2, 2022 14:56
@Jorropo
Copy link
Contributor Author

Jorropo commented Aug 2, 2022

Found with @Arlodotexe

@Jorropo Jorropo requested review from aschmahmann and removed request for aschmahmann August 2, 2022 16:08
util_windows.go Outdated Show resolved Hide resolved
util_windows.go Outdated Show resolved Hide resolved
util_windows.go Outdated Show resolved Hide resolved
@Jorropo Jorropo requested a review from Stebalien August 11, 2022 13:57
@Jorropo Jorropo force-pushed the fix/windows_alloc_hint branch 6 times, most recently from fcf1a59 to 1aa2ad3 Compare October 15, 2023 05:03
This code was broken, it computed the size hint to do nothing with it.
@Jorropo
Copy link
Contributor Author

Jorropo commented Oct 15, 2023

I overlooked it didn't built ... :'( thx
I'll release after I get an O_TMPFILE patch ready for linux.

@Jorropo Jorropo merged commit 2f66973 into master Oct 15, 2023
9 checks passed
@Jorropo Jorropo deleted the fix/windows_alloc_hint branch October 15, 2023 19:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants