You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I suspect this isn't generally noticed on architectures that use a pagesize of 4096, since when we do a stackalloc, we'll typically do it for at least 4096, which is the nearest page size, so it usually works as expected.
As such, I suspect this is generally the most noticeable on mips64, ppc64, arm, arm64, etc.
This was discovered while working on the sparc64 port since the DefaultPhysPageSize is 8192.
When stackFromSystem = 1, the stack allocation size is rounded to the nearest page size:
...however, that rounded size is not returned to/used by the caller of stackalloc(), so when a stackfree() is later done:
We'll either set less than the actual bytes allocated for faulted access, or fail to free/unmap all of the memory.
The text was updated successfully, but these errors were encountered: