mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2026-04-25 07:46:01 +03:00
[PR #3639] [MERGED] Core: physical backing for flexible and pooled memory allocations #3629
Labels
No labels
Bloodborne
bug
contributor wanted
documentation
enhancement
frontend
good first issue
help wanted
linux
pull-request
question
release
verification progress
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/shadPS4#3629
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/shadps4-emu/shadPS4/pull/3639
Author: @StevenMiller123
Created: 9/21/2025
Status: ✅ Merged
Merged: 9/23/2025
Merged by: @georgemoralis
Base:
main← Head:flex-mem-backing📝 Commits (10+)
adccc11Fix isDevKit12ce66fPhysical backing for flexible allocationsd97454bVarious fixups81d0737Fix mistake #1871af75Assert + clangbe63ff2Fix 2a1c134aClang09c4f8dFix CanMergeWith0769de1Clangc7b9cdbPhysical backing for pooled memory📊 Changes
6 files changed (+179 additions, -44 deletions)
View changed files
📝
src/core/address_space.cpp(+3 -3)📝
src/core/libraries/kernel/memory.cpp(+1 -1)📝
src/core/libraries/kernel/memory.h(+19 -16)📝
src/core/linker.cpp(+2 -2)📝
src/core/memory.cpp(+113 -21)📝
src/core/memory.h(+41 -1)📄 Description
This PR handles partial unmaps of flexible memory. I've created a separate flexible memory map used to track flexible "physical" allocations, calculate free physical addresses to map, and implemented logic in MapMemory and UnmapBytesFromEntry for properly updating this flexible map.
I also added a fix for the isDevKit logic, the backing size wasn't properly updated for the increased direct memory size of isDevKit, which could cause weird issues with direct memory allocations that use the extra space.
This improves Uncharted 4: A Thief’s End™ (CUSA00341), The Last of Us™ Part II (CUSA07820), and FINAL FANTASY XV (CUSA01633) on Windows devices.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.