-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Enable linux OOP unwinder on Windows for cross DAC #35972
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
Conversation
Add libunwind_xdac Revise CMake files to enable compiling libunwind for UNW_REMOTE_ONLY Add minimum set of posix prototypes and constants to enable compilation Add minimum implementation of posix functions to satisfy linker. Copy freebsd-elf headers from mono include directory Cleanup comment Fix GCC constructs not supported by VC++ Use TARGET variables to configure libunwind Add PAL_VirtualUnwindOutOfProc to libunwind_xdac
|
Tagging subscribers to this area: @tommcdon |
|
@sdmaclea this is overall problematic. We don't want to make any changes to the libunwind sources in our repo since I expect that we would need to update them in the future from the upstream and making them diverse would cause pain once we need to sync. The exception is the CMakeLists.txt which is ours, so we can do whatever we want there. |
| void* mmap(void *addr, size_t length, int prot, int flags, int fd, size_t offset) | ||
| { | ||
| // We shouldn't be doing anything other than anonymous mappings | ||
| if ((flags & MAP_ANON) == 0) |
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.
nit: This should be MAP_ANONYMOUS as MAP_ANON is deprecated.
| if ((flags & MAP_ANON) == 0) | ||
| return MAP_FAILED; | ||
|
|
||
| return malloc(length); |
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.
MAP_ANONYMOUS guarantees a zero-initialized buffer, shouldn't we call memset on the buffer that was malloc'ed?
| return 0; | ||
| } | ||
|
|
||
| ssize_t read(int fd, void *buf, size_t count) |
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.
nit: Spacing?
|
Closing in favor of #37521 |
Add libunwind_xdac
Revise CMake files to enable compiling libunwind for UNW_REMOTE_ONLY
Add minimum set of posix prototypes and constants to enable compilation
Add minimum implementation of posix functions to satisfy linker.
Copy freebsd-elf headers from mono include directory
Cleanup comment
Fix GCC constructs not supported by VC++
Use TARGET variables to configure libunwind
Add PAL_VirtualUnwindOutOfProc to libunwind_xdac
/cc @hoyosjs