mirror of
https://github.com/dart-lang/sdk
synced 2024-10-14 12:14:36 +00:00
397ed8673c
Suppose we have code like if (isDevMode) { // do foo } else { // do bar } where isDevMode is const (or can be evaluated as const). In particular, isDevMode can be controlled by compile-time options, like bool.fromEnvironment. We currently eliminate the dead branch during SSA, but that means we do the work of compiling dead code in the previous phases. Instead, we can recognize that the condition is const (or effectively const) and eliminate the dead AST subtree directly. Change-Id: Ia91da5ebc7fa496a1b963308c6e02d572cab936e Bug: b/254543452 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/270281 Reviewed-by: Sigmund Cherem <sigmund@google.com> |
||
---|---|---|
.. | ||
co19 | ||
co19_2 | ||
corelib | ||
corelib_2 | ||
dartdevc | ||
dartdevc_2 | ||
ffi | ||
ffi_2 | ||
language | ||
language_2 | ||
lib | ||
lib_2 | ||
modular | ||
standalone | ||
standalone_2 | ||
web | ||
web_2 | ||
legacy_status_dart2js.csv | ||
OWNERS | ||
README.md |
This directory contains tests of the language and core library implementations. For more information, see https://github.com/dart-lang/sdk/wiki/Testing.