Skip to content

topo, funk: change Funk workspace use unlocked pages #5470

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

Merged
merged 1 commit into from
Jul 14, 2025

Conversation

topointon-jump
Copy link
Contributor

This PR changes the Funk workspace to use unlocked, unpinned pages that are not required to be resident in physical memory. This enables running large ledgers on machines with smaller memory.

@topointon-jump topointon-jump force-pushed the topointon/funk-unpinned-pages branch 7 times, most recently from 251804a to ee73f49 Compare July 1, 2025 18:56
@topointon-jump topointon-jump force-pushed the topointon/funk-unpinned-pages branch 3 times, most recently from dc4a7b5 to 1ae013a Compare July 7, 2025 21:38
@topointon-jump topointon-jump changed the title topo, funk: change Funk workspace use unlocked pages [WIP] topo, funk: change Funk workspace use unlocked pages Jul 7, 2025
@topointon-jump topointon-jump force-pushed the topointon/funk-unpinned-pages branch from 1ae013a to f32fb51 Compare July 8, 2025 15:28
@topointon-jump topointon-jump force-pushed the topointon/funk-unpinned-pages branch 3 times, most recently from 1d18412 to df87fce Compare July 9, 2025 21:28

/* Create the directory for the normal pages, where the files backing memory-mapped unlocked workspaces can be stored. */
FD_LOG_NOTICE(( "RUN: `mkdir -p %s`", path ));
if( FD_UNLIKELY( -1==fd_file_util_mkdir_all( path, config->uid, config->gid ) ) ) {
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't get this thing. What is a normalpage configure stage? The 4K page equivalent to hugetlbfs is tmpfs.

Copy link
Contributor

Choose a reason for hiding this comment

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

If it's for normal on-disk data, wouldn't it make more sense to just have a ledger directory instead? We can temporarily use it for disk-backed funk and then change it later on to be the backing store for the actual DB

Copy link
Contributor

Choose a reason for hiding this comment

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

The problem is it's integrated into the topology system, and expects a "workspace" which we have whole special code paths for, it's a little tricky to just get a workspace to mount in the ledger directory.

Copy link
Contributor

Choose a reason for hiding this comment

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

Disgusting but fine with me, I suppose it will get reverted

@topointon-jump topointon-jump force-pushed the topointon/funk-unpinned-pages branch 2 times, most recently from cfc00de to 3dccb73 Compare July 9, 2025 22:00
@topointon-jump topointon-jump force-pushed the topointon/funk-unpinned-pages branch 4 times, most recently from 67c867b to beb47f5 Compare July 9, 2025 23:20
@mmcgee-jump mmcgee-jump force-pushed the topointon/funk-unpinned-pages branch from beb47f5 to fffc0c8 Compare July 10, 2025 21:05
mmcgee-jump
mmcgee-jump previously approved these changes Jul 10, 2025
@mmcgee-jump mmcgee-jump enabled auto-merge July 10, 2025 21:06
@topointon-jump topointon-jump force-pushed the topointon/funk-unpinned-pages branch from fffc0c8 to 3a726eb Compare July 14, 2025 14:54
@topointon-jump topointon-jump force-pushed the topointon/funk-unpinned-pages branch 3 times, most recently from 0dd2afe to 72d18f3 Compare July 14, 2025 19:31
@topointon-jump topointon-jump force-pushed the topointon/funk-unpinned-pages branch from 72d18f3 to dac1cae Compare July 14, 2025 19:35
@mmcgee-jump mmcgee-jump added this pull request to the merge queue Jul 14, 2025
Merged via the queue into main with commit 64ae55c Jul 14, 2025
24 of 41 checks passed
@mmcgee-jump mmcgee-jump deleted the topointon/funk-unpinned-pages branch July 14, 2025 21:04
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