X Tutup
Skip to content

Optimize data flushing for FileAccessCompressed and FileAccessEncrypted#110169

Merged
Repiteo merged 1 commit intogodotengine:masterfrom
BlueCube3310:file-access-flush-opti
Sep 17, 2025
Merged

Optimize data flushing for FileAccessCompressed and FileAccessEncrypted#110169
Repiteo merged 1 commit intogodotengine:masterfrom
BlueCube3310:file-access-flush-opti

Conversation

@BlueCube3310
Copy link
Contributor

@BlueCube3310 BlueCube3310 commented Sep 1, 2025

Improves the performance of FileAccessCompressed and FileAccessEncrypted's _close() functions by avoiding repeated allocations and COW.

Performance:
A file with 1000000 x int64, with each value being the index of the loop iteration.

Before After:
File Access Compressed: ~127 ms, File Access Encrypted: ~238 ms File Access Compressed: ~120 ms, File Access Encrypted: ~207 ms

Copy link
Member

@clayjohn clayjohn left a comment

Choose a reason for hiding this comment

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

Looks great!

@clayjohn clayjohn modified the milestones: 4.x, 4.6 Sep 15, 2025
Copy link
Member

@Calinou Calinou left a comment

Choose a reason for hiding this comment

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

Code looks good to me.

@Repiteo Repiteo merged commit 138e21e into godotengine:master Sep 17, 2025
20 checks passed
@Repiteo
Copy link
Contributor

Repiteo commented Sep 17, 2025

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

X Tutup