-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[release/5.0] Fix debugger attach+read on Linux 32 bit #45882
Conversation
Activation tests are known, fixed on 5.0 by #45525 The mono failures are #45524. @akoeplinger any idea why the Windows tests are failing fatally on mono because of the VS update? We'd seen this in master when I disabled the leg, I started the backport PR as it's blocking 5.0, but I don't know if it's a good idea. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thank you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved. We should consider this for 5.0.2
tactics approved by email |
All the three failures are known and fixed |
Backport of #45506 to release/5.0, fixes #44745
Description
The debug PAL was undefining of macros that cause 32 bit POSIX syscalls to use 64 bit offsets. The offsets are defined in a signed manner, which means that any address over the 2GB range that we use will result in an incoherent call to pread and similar APIs. This has been the case for years, but it only affected ARMv7 systems as they are currently our only Unix 32 bit target. Customers started reporting being unable to attach to their processes using the debugger. The bug became a blocker as we changed the debugger startup path to use symbol exports in CoreCLR for our single file story, meaning that the DAC no longer used a compile time header but an export. That read resulted in an access on the >2GB virtual memory region when run in a device with enough memory available with a signed address. In this sense, this is a regression from 3.1.
Customer Impact
Customers targeting linux-arm running on devices with more than 2 GB of memory will see spurious failures. Most of the times it will manifest as being unable to attach. There are no work arounds.
Testing
Manual testing on a device that matches the requirements for the bug to repro using VS as the test debugger.
Risk
Very low. Only impacts ARMv7 and the functions in this file are only used by the debugger.