Skip to content

Clean up packages and use internal object pool for stringbuilder#45

Merged
manigandham merged 3 commits intomasterfrom
cleanup
Jul 3, 2021
Merged

Clean up packages and use internal object pool for stringbuilder#45
manigandham merged 3 commits intomasterfrom
cleanup

Conversation

@manigandham
Copy link
Copy Markdown
Collaborator

@manigandham manigandham commented Jul 3, 2021

  • Cleanup unused nuget references
  • Replace Microsoft.Extensions.ObjectPool with internal implementation using ConcurrentBag<> to avoid conflicts in some environments.

@manigandham manigandham changed the title Cleanup Clean up packages and use internal object pool for stringbuilder Jul 3, 2021
@manigandham
Copy link
Copy Markdown
Collaborator Author

manigandham commented Jul 3, 2021

No change in performance and all tests pass:

BenchmarkDotNet=v0.12.1, OS=Windows 10.0.19043
AMD Ryzen 9 3900X, 1 CPU, 24 logical and 12 physical cores
.NET Core SDK=5.0.301
  [Host]     : .NET Core 5.0.7 (CoreCLR 5.0.721.25508, CoreFX 5.0.721.25508), X64 RyuJIT
  DefaultJob : .NET Core 5.0.7 (CoreCLR 5.0.721.25508, CoreFX 5.0.721.25508), X64 RyuJIT


|         Method |     Mean |     Error |    StdDev |  Gen 0 | Gen 1 | Gen 2 | Allocated |
|--------------- |---------:|----------:|----------:|-------:|------:|------:|----------:|
|  RoundtripInts | 4.134 us | 0.0501 us | 0.0468 us | 0.0687 |     - |     - |     576 B |
| RoundtripLongs | 4.646 us | 0.0313 us | 0.0292 us | 0.0687 |     - |     - |     576 B |
|   RoundtripHex | 4.167 us | 0.0608 us | 0.0569 us | 0.1755 |     - |     - |    1512 B |

@manigandham manigandham merged commit 39c86a2 into master Jul 3, 2021
@manigandham manigandham deleted the cleanup branch July 3, 2021 03:30
@manigandham manigandham self-assigned this Nov 18, 2021
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.

1 participant