ouroboros-network
ouroboros-network copied to clipboard
Analyse TVar memory leak when using `ghc-9.8`
One can reproduce the problem with this repo.
We know the problem is caused by pipelining, especially when maximal pipelining depth is heigh. Some ideas to simplify the repository:
- eliminate
cpsVar - swap
doneVarfor anMVar - eliminate
Channeland useconnectPipelinedinstead, - eliminate usage of typed-protocols, and run
ChainSyncServeragainstChainSyncClientPipelinedagainst each other with: directPipelined. - simplify
chain-syncprotocol
We found out that the memory leak was resolved when the number of pipelined messages was reduced to a small number. There's more information about it in an unfortunately private slack thread.