Bug 286591
| Summary: | [ANGLE] Add envvar to allow gating ASSERTs at runtime | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | zak ridouh <zakr> |
| Component: | New Bugs | Assignee: | Nobody <webkit-unassigned> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | webkit-bug-importer |
| Priority: | P2 | Keywords: | InRadar |
| Version: | WebKit Nightly Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
zak ridouh
Add a `ANGLE_ASSERTS_OFF` environment variable that allows us to disable asserts at runtime regardless of how ANGLE was built.
This is necessary due to how some of our build systems work, where we need to be able to disable asserts at runtime regardless of if we built ANGLE with the `ANGLE_ASSERT_ALWAYS_ON` or `ANGLE_ENABLE_ASSERTS` flag set.
We cache the value from the `envvar`, so that we don't incur a `getenv` check penalty on every ASSERT. Additionally, this will not impact release and production builds as this function is gated by a guard: `#if defined(ANGLE_ENABLE_ASSERTS)`.
This is essentially a reland of https://bugs.webkit.org/show_bug.cgi?id=281156, with fixes.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Radar WebKit Bug Importer
<rdar://problem/143716846>
zak ridouh
Pull request: https://github.com/WebKit/WebKit/pull/39628
EWS
Committed 289548@main (591d8cca0024): <https://commits.webkit.org/289548@main>
Reviewed commits have been landed. Closing PR #39628 and removing active labels.