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

Optimize, simplify FromChunkedBase64String method #1868

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

QuocDatHoang
Copy link
Contributor

This update optimizes and simplifies the FromChunkedBase64String method, improving both performance and memory efficiency.

Implementation Details

Removed unnecessary manual handling of \r and \n, as Convert.FromBase64String already handles these characters automatically.
Eliminated Where() and ToArray() operations, significantly reducing memory allocations and improving execution efficiency.

Benchmark Results

Performance: ~2.4x speed improvement
Memory Usage: ~70% reduction

image

Copy link

github-actions bot commented Feb 6, 2025

Test Results

    70 files  ±0      70 suites  ±0   1h 3m 54s ⏱️ -14s
 2 041 tests ±0   2 038 ✅ ±0   3 💤 ±0  0 ❌ ±0 
32 418 runs  ±0  32 382 ✅ ±0  36 💤 ±0  0 ❌ ±0 

Results for commit a32752a. ± Comparison against base commit dc1318f.

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