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 Tasks collections in .Net 9 #7585

Merged
merged 25 commits into from
Nov 20, 2024

Conversation

LukaszRozmej
Copy link
Member

Builds upon #7532

Changes

  • Move task collections to pooled ones and use spans when using WaitAll, WhenAll and WhenAny

Types of changes

What types of changes does your code introduce?

  • Bugfix (a non-breaking change that fixes an issue)
  • New feature (a non-breaking change that adds functionality)
  • Breaking change (a change that causes existing functionality not to work as expected)
  • Optimization
  • Refactoring
  • Documentation update
  • Build-related changes
  • Other: Description

Testing

Requires testing

  • Yes
  • No

If yes, did you write tests?

  • Yes
  • No

Copy link
Contributor

@rubo rubo left a comment

Choose a reason for hiding this comment

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

Nitpick: In some places we add items to the pool in a for loop with .Add(), in other places, with LINQ's .Select() or Enumerable.Range().Select(). Isn't it worth unifying the approach?

@LukaszRozmej LukaszRozmej mentioned this pull request Oct 31, 2024
3 tasks
@rubo rubo force-pushed the feature/dotnet9-migration branch from 83982fb to 2d20327 Compare November 19, 2024 10:44
Base automatically changed from feature/dotnet9-migration to master November 19, 2024 13:04
…ration-optimize-tasks

# Conflicts:
#	global.json
#	src/Nethermind/Directory.Build.props
#	src/Nethermind/Directory.Packages.props
#	src/Nethermind/Nethermind.State/PersistentStorageProvider.cs
#	src/Nethermind/Nethermind.Trie/Pruning/TrieStore.cs
#	tools/Directory.Build.props
#	tools/HiveCompare/HiveCompare.csproj
Copy link
Member

@benaadams benaadams left a comment

Choose a reason for hiding this comment

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

Why the .orig files?

@LukaszRozmej
Copy link
Member Author

Why the .orig files?

github merge fail

@LukaszRozmej LukaszRozmej marked this pull request as ready for review November 20, 2024 11:03
@benaadams benaadams merged commit 88a615f into master Nov 20, 2024
77 checks passed
@benaadams benaadams deleted the feature/dotnet9-migration-optimize-tasks branch November 20, 2024 13:57
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.

4 participants