Skip to content

Conversation

@rustyrussell
Copy link
Contributor

@Lagrang3 pointed out that our single linked list of layers will become a bottleneck, so this contains a quick benchmark for many layers, and replaces the linked list with a hashtable.

Changelog-None

Simple bench.

Before:
   Creating 20,000 layers:  32 seconds

After:
   Creating 20,000 layers:  13 seconds
   Creating 50,000 layers:  30 seconds
   Creating 100,000 layers: 57 seconds

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
…ers on startup.

We used non-persistent layers before, but what if we save to the datastore and restore?

This takes it from 57 to 87 seconds.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
@rustyrussell rustyrussell added this to the v26.03 milestone Dec 5, 2025
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