Repository navigation
Conversation
… Motion can start NVIDIA Smooth Motion (driver frame generation, RTX 50, now also for Vulkan) makes its frames with CUDA in the driver's present layer, which initializes CUDA when the swapchain is created. By then the guest address space owns every free range below HOST_USER_MAX, so CUDA finds no room for its address range and cuInit fails with CUDA_ERROR_OUT_OF_MEMORY (2). Smooth Motion then stays off for Kyty even when it is enabled in the NVIDIA App; the layer's log (C:/NvPresent/logs/kyty_emulator.exe) shows "CUDA initialization failed. Error code 2". Main now calls cuInit before any reservation. CUDA's range must not land where the guest maps at fixed addresses (the default map base 0x200000000 and up, the AGC driver memory at 0xfe0000000; initializing CUDA there made that mapping fail), so the free ranges below a floor (512 GiB) are held during cuInit and released right after it. CUDA's range lands above the floor and the guest address space reserves everything around it. The layer's own cuInit then succeeds: "Feature Smooth Motion requested. System support: 1. Device support: 1", and its swapchain is created. KYTY_CUDA_EARLY_INIT=0 turns it off; KYTY_CUDA_VA_FLOOR_GB moves the floor. Without nvcuda.dll (no NVIDIA driver) nothing happens. Tested with Astro Bot on an RTX 5070 Ti, driver 617.42.
Jetsku
added a commit
that referenced
this pull request
Oct 20, 2026
PR #58 ran cuInit on every NVIDIA run and let CUDA reserve its range above 512 GiB. The guest user range runs to HOST_USER_MAX (0xfb_ffff_ffff, about 1008 GiB), so CUDA could land inside it and leave a permanent hole that a fixed-address guest mapping would hit. - KYTY_CUDA_EARLY_INIT=1 now turns it on; default off. Only drivers with Smooth Motion gain anything, and the rest would pay for an extra DLL, CUDA threads and startup time. - The floor defaults to 1024 GiB (0x100_0000_0000) and KYTY_CUDA_VA_FLOOR_GB can only raise it (clamped to 1024..65536). Co-Authored-By: Jetsku <59046009+Jetsku@users.noreply.github.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
biggsymobile-png
added a commit
to biggsymobile-png/KytyPS5
that referenced
this pull request
Oct 22, 2026
…ged first At 1008 GiB cuInit still failed with 2 (only 48 MiB of small allocations were made). 512 GiB is the floor it worked with in PR Jetsku#58. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01MYrbTh2mTBkYrpBvqMpKd7
Owner
|
Has been merged and added to a release |
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
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
… Motion can start
NVIDIA Smooth Motion (driver frame generation, RTX 50, now also for Vulkan) makes its frames with CUDA in the driver's present layer, which initializes CUDA when the swapchain is created. By then the guest address space owns every free range below HOST_USER_MAX, so CUDA finds no room for its address range and cuInit fails with CUDA_ERROR_OUT_OF_MEMORY (2). Smooth Motion then stays off for Kyty even when it is enabled in the NVIDIA App; the layer's log (C:/NvPresent/logs/kyty_emulator.exe) shows "CUDA initialization failed. Error code 2".
Main now calls cuInit before any reservation. CUDA's range must not land where the guest maps at fixed addresses (the default map base 0x200000000 and up, the AGC driver memory at 0xfe0000000; initializing CUDA there made that mapping fail), so the free ranges below a floor (512 GiB) are held during cuInit and released right after it. CUDA's range lands above the floor and the guest address space reserves everything around it. The layer's own cuInit then succeeds: "Feature Smooth Motion requested. System support: 1. Device support: 1", and its swapchain is created.
KYTY_CUDA_EARLY_INIT=0 turns it off; KYTY_CUDA_VA_FLOOR_GB moves the floor. Without nvcuda.dll (no NVIDIA driver) nothing happens. Tested with Astro Bot on an RTX 5070 Ti, driver 617.42.