-
Notifications
You must be signed in to change notification settings - Fork 7.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
Testing ASan for MSVC #15978
Closed
Closed
Testing ASan for MSVC #15978
Conversation
This file contains 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
This was referenced Oct 19, 2024
According to Microsoft, ASan is already supported as of Visual Studio 16.9, but that support might be limited, and we can't easily check versions prior to 16.11 anyway, so we require 16.10 for now. We also move the `ARG_ENABLE` to the top-level, since `ARG_*` has special treatment by buildconf anyway, so there are no conditionally declared `ARG_*`s.
This *might* "solve" the `C00000FF` (`STATUS_BAD_FUNCTION_TABLE`) errors, we're seeing for some tests.
This is, of course, mandatory.
We're in need for speed regarding CI.
This reverts commit a261b4c.
This reverts commit 5c420a5.
This reverts commit 2339153.
These tests execute php.exe without passing the PATH, what might be a more general issues, but at least with ASan enabled, the required DLLs could usually not be found, resulting in the tests stalling.
For some reason, terminating the child process by sending CTRL+C won't work under ASan instrumentation. Since termination via CTRL+BREAK works, there is apparently nothing fundamentally wrong, so we just skip the test.
This reverts commit ec8fe7f.
These look related to php#15709, but apparently only fail with ASan instrumentation. Let's xfail these for now.
Finally green. \o/ |
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.
If this works, this PR supersedes #6964.
From my limited testing, the crux to avoid the
0xc0000028
errors (STATUS_BAD_STACK
, i.e. "An invalid or unaligned stack was encountered during an unwind operation."), is to enableZEND_DEBUG
. That may require further investigation, although it is probably not a bad idea to have debug assertions enabled when running with ASan. If we keep this, this PR likely supersedes #15544 as well.TODO:
ARG_ENABLE("sanitizer")
out of the conditional (see how buildconf handles these when generating configure)Further notes:
0xC00000FF
(STATUS_BAD_FUNCTION_TABLE
, "A malformed function table was encountered during an unwind operation.")