Skip to content
This repository was archived by the owner on Oct 25, 2024. It is now read-only.

Conversation

@dvush
Copy link
Contributor

@dvush dvush commented Dec 27, 2022

📝 Summary

Should fix #13

Its stops prefetcher when it can be leaked.

Copy link
Collaborator

@Ruteri Ruteri left a comment

Choose a reason for hiding this comment

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

I worry this is hardly the last place it could leak, but it'll definitely help

@dvush
Copy link
Contributor Author

dvush commented Dec 28, 2022

I am very confident that this is the only place that matter.

We create an environment and start prefetcher in the prepareWork function and call env.discard() (that stops prefetcher) properly.

The only problem that we have is if we swap env.state pointer to the copy of the state. We do it only in one place - which is here.

The upside of this change is that it will not stop prefetcher if we don't use this method. (e.g. if we will have algorithm that works without state copying for bundles)

@dvush dvush merged commit ecff598 into flashbots:main Dec 28, 2022
avalonche pushed a commit that referenced this pull request Feb 7, 2023
* remove unused beacon client from the builder

* build on multiple tips

* worker async generateWork

* rework bundle cache

* fix validate payload test in main
avalonche pushed a commit that referenced this pull request Feb 7, 2023
avalonche pushed a commit that referenced this pull request Mar 9, 2023
* remove unused beacon client from the builder

* build on multiple tips

* worker async generateWork

* rework bundle cache

* fix validate payload test in main
avalonche pushed a commit that referenced this pull request Mar 9, 2023
avalonche pushed a commit that referenced this pull request Mar 15, 2023
* remove unused beacon client from the builder

* build on multiple tips

* worker async generateWork

* rework bundle cache

* fix validate payload test in main
avalonche pushed a commit that referenced this pull request Mar 15, 2023
avalonche pushed a commit that referenced this pull request Mar 17, 2023
* remove unused beacon client from the builder

* build on multiple tips

* worker async generateWork

* rework bundle cache

* fix validate payload test in main
avalonche pushed a commit that referenced this pull request Mar 17, 2023
avalonche pushed a commit that referenced this pull request Mar 22, 2023
* remove unused beacon client from the builder

* build on multiple tips

* worker async generateWork

* rework bundle cache

* fix validate payload test in main
avalonche pushed a commit that referenced this pull request Mar 22, 2023
avalonche pushed a commit that referenced this pull request Jul 6, 2023
* remove unused beacon client from the builder

* build on multiple tips

* worker async generateWork

* rework bundle cache

* fix validate payload test in main
avalonche pushed a commit that referenced this pull request Jul 6, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Possible Memory Leak

3 participants