MinaProtocol / mina

Mina is a cryptocurrency protocol with a constant size blockchain, improving scaling while maintaining decentralization and security.
https://minaprotocol.com
Apache License 2.0
1.97k stars 523 forks source link

Improving how trace with selectors are kept in memory #15656

Open dannywillems opened 1 month ago

dannywillems commented 1 month ago

At the moment, there is a huge memory overhead as we keep a full columns for each selectors for each traces, i.e. if we have N relations columns and M selectors, we will keep M * (N + M) columns of L rows, L being the domain size. It is not efficient at all, as we only have to keep a value 0 or 1 for M columns for each of the M traces.