FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Add compile.offload_activation_pin_memory for DeepCompile activation offload by sfc-gh-truwase · Pull Request #8258 · deepspeedai/DeepSpeed · GitHub

Add compile.offload_activation_pin_memory for DeepCompile activation offload - #8258

Merged
pengdurice merged 1 commit into
masterfrom
tjruwase/pin-memory-compile-offload-pin
Aug 16, 2026
Merged

Add compile.offload_activation_pin_memory for DeepCompile activation offload#8258
pengdurice merged 1 commit into
masterfrom
tjruwase/pin-memory-compile-offload-pin

Conversation

Copy link
Copy Markdown
Collaborator

Summary

  • Add compile.offload_activation_pin_memory (default true) on CompileConfig and wire it into DeepCompile C++ offloadTensor via at::TensorOptions().pinned_memory(...).
  • Document honestly: the offload pass is not in the default schedule (offload_activation alone does nothing); pinning here uses ATen/Torch host pin and does not consult DS_PIN_MEMORY_BACKEND.

Test plan

  • pre-commit run --files on touched paths (already run locally)
  • Rebuild deepcompile extension and confirm default still pins host offload buffers when the offload pass is scheduled
  • With a custom schedule that includes activation offload, offload_activation_pin_memory: false yields pageable host buffers

…offload

Expose a default-true knob so DeepCompile host offload buffers can use
pageable memory under tight memlock limits, without changing the default
pinned behavior.

Signed-off-by: Olatunji Ruwase <tunji.ruwase@snowflake.com>
Co-authored-by: Cursor <cursoragent@cursor.com>

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.

Copy link
Copy Markdown
Collaborator Author

@pengdurice @tohtana FYI

PKUWZP self-requested a review August 16, 2026 03:26

Copy link
Copy Markdown
Contributor

@sfc-gh-truwase , thank you for the PR! #8255 is for enabling activation offload in the deep compile schedules. Feel free to review when it is ready;-)

pengdurice added this pull request to the merge queue Aug 16, 2026
Merged via the queue into master with commit c952d92 Aug 16, 2026
16 of 23 checks passed
pengdurice deleted the tjruwase/pin-memory-compile-offload-pin branch August 16, 2026 05:49
sfc-gh-truwase added a commit that referenced this pull request Aug 20, 2026
Honor DS_PIN_MEMORY_BACKEND for the common contiguous checkpoint-input
path. Strided views keep ATen empty_strided pin because native pin cannot
preserve arbitrary strides. Document pin on/off vs backend; DeepCompile
compile.offload_activation_pin_memory already landed in #8258.

Signed-off-by: Olatunji Ruwase <tunji.ruwase@snowflake.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
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.

3 participants


Back | FazBrowse Home | New Git URL