Skip to content

pgalloc: throttle background page loading until the kernel and filesy… - #15880

Merged
copybara-service[bot] merged 1 commit into
gvisor:masterfrom
milantracy:cr-restore-throttle
Oct 23, 2026
Merged

copybara-service[bot] merged 1 commit into
gvisor:masterfrom
milantracy:cr-restore-throttle

Conversation

@milantracy

@milantracy milantracy commented Oct 16, 2026 •

Copy link
Copy Markdown
Member

…stems are restored

For runsc restore --background, the page loader reads only one range of unawaited pages at a time, and only when no other read is in flight. Reads of awaited pages are not throttled. When the kernel and filesystems are restored, runsc stops the throttle, and the page loader uses all parallel reads again.

Fix: #15877

@EtiennePerot EtiennePerot left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Seems fine in principle to me but would like either other reviewer's take. (@ayushr2 or @nixprime)

Comment thread pkg/sentry/pgalloc/save_restore.go Resolved
Comment thread runsc/boot/fscheckpoint.go Resolved

@EtiennePerot EtiennePerot left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Please post benchmark numbers (with significance)

Comment thread pkg/sentry/pgalloc/save_restore.go Resolved
@EtiennePerot EtiennePerot added this to the Lightspeed milestone Oct 22, 2026

@EtiennePerot EtiennePerot left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks good but would still like benchmarks

@milantracy

Copy link
Copy Markdown
Member Author

Looks good but would still like benchmarks

the benchmark is updated at #15877 @EtiennePerot

@EtiennePerot EtiennePerot added the ready to pull Causes the PR to be imported into Google. Will be removed soon. label Oct 22, 2026
copybara-service Bot pushed a commit that referenced this pull request Oct 22, 2026
…stems are restored

For runsc restore --background, the page loader reads only one range of unawaited pages at a time, and only when no other read is in flight. Reads of awaited pages are not throttled. When the kernel and filesystems are restored, runsc stops the throttle, and the page loader uses all parallel reads again.

Fix: #15877
FUTURE_COPYBARA_INTEGRATE_REVIEW=#15880 from milantracy:cr-restore-throttle 80ea51b
PiperOrigin-RevId: 1004577251
copybara-service Bot pushed a commit that referenced this pull request Oct 22, 2026
…stems are restored

For runsc restore --background, the page loader reads only one range of unawaited pages at a time, and only when no other read is in flight. Reads of awaited pages are not throttled. When the kernel and filesystems are restored, runsc stops the throttle, and the page loader uses all parallel reads again.

Fix: #15877
FUTURE_COPYBARA_INTEGRATE_REVIEW=#15880 from milantracy:cr-restore-throttle 80ea51b
PiperOrigin-RevId: 1004577251
…stems are restored

For runsc restore --background, the page loader reads only one range of
unawaited pages at a time, and only when no other read is in flight.
Reads of awaited pages are not throttled. When the kernel and
filesystems are restored, runsc stops the throttle, and the page loader
uses all parallel reads again.

Signed-off-by: Jing Chen <[email protected]>
@milantracy milantracy removed the ready to pull Causes the PR to be imported into Google. Will be removed soon. label Oct 22, 2026
copybara-service Bot pushed a commit that referenced this pull request Oct 22, 2026
…stems are restored

For runsc restore --background, the page loader reads only one range of unawaited pages at a time, and only when no other read is in flight. Reads of awaited pages are not throttled. When the kernel and filesystems are restored, runsc stops the throttle, and the page loader uses all parallel reads again.

Fix: #15877
FUTURE_COPYBARA_INTEGRATE_REVIEW=#15880 from milantracy:cr-restore-throttle 80ea51b
PiperOrigin-RevId: 1004577251
copybara-service Bot pushed a commit that referenced this pull request Oct 22, 2026
…stems are restored

For runsc restore --background, the page loader reads only one range of unawaited pages at a time, and only when no other read is in flight. Reads of awaited pages are not throttled. When the kernel and filesystems are restored, runsc stops the throttle, and the page loader uses all parallel reads again.

Fix: #15877
FUTURE_COPYBARA_INTEGRATE_REVIEW=#15880 from milantracy:cr-restore-throttle 80ea51b
PiperOrigin-RevId: 1004577251
copybara-service Bot pushed a commit that referenced this pull request Oct 22, 2026
…stems are restored

For runsc restore --background, the page loader reads only one range of unawaited pages at a time, and only when no other read is in flight. Reads of awaited pages are not throttled. When the kernel and filesystems are restored, runsc stops the throttle, and the page loader uses all parallel reads again.

Fix: #15877
FUTURE_COPYBARA_INTEGRATE_REVIEW=#15880 from milantracy:cr-restore-throttle 80ea51b
PiperOrigin-RevId: 1004577251
copybara-service Bot pushed a commit that referenced this pull request Oct 22, 2026
…stems are restored

For runsc restore --background, the page loader reads only one range of unawaited pages at a time, and only when no other read is in flight. Reads of awaited pages are not throttled. When the kernel and filesystems are restored, runsc stops the throttle, and the page loader uses all parallel reads again.

Fix: #15877
FUTURE_COPYBARA_INTEGRATE_REVIEW=#15880 from milantracy:cr-restore-throttle 80ea51b
PiperOrigin-RevId: 1004577251

@EtiennePerot EtiennePerot left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks good but would still like benchmarks

@EtiennePerot EtiennePerot added the ready to pull Causes the PR to be imported into Google. Will be removed soon. label Oct 23, 2026
copybara-service Bot pushed a commit that referenced this pull request Oct 23, 2026
…stems are restored

For runsc restore --background, the page loader reads only one range of unawaited pages at a time, and only when no other read is in flight. Reads of awaited pages are not throttled. When the kernel and filesystems are restored, runsc stops the throttle, and the page loader uses all parallel reads again.

Fix: #15877
FUTURE_COPYBARA_INTEGRATE_REVIEW=#15880 from milantracy:cr-restore-throttle 30cec7d
PiperOrigin-RevId: 1004577251
copybara-service Bot pushed a commit that referenced this pull request Oct 23, 2026
…stems are restored

For runsc restore --background, the page loader reads only one range of unawaited pages at a time, and only when no other read is in flight. Reads of awaited pages are not throttled. When the kernel and filesystems are restored, runsc stops the throttle, and the page loader uses all parallel reads again.

Fix: #15877
Auto-fixed-by: [🤖] @EtiennePerot
FUTURE_COPYBARA_INTEGRATE_REVIEW=#15880 from milantracy:cr-restore-throttle 30cec7d
PiperOrigin-RevId: 1005832831
@copybara-service
copybara-service Bot merged commit 173413b into gvisor:master Oct 23, 2026
13 of 14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready to pull Causes the PR to be imported into Google. Will be removed soon.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Throttle background page loading until the kernel and filesystems are restored

3 participants