dart-sdk/runtime
Gabriel Terwesten e2d6cb69fb Reland "[vm/compiler] Optimize switch statements"
This is a reland of commit f5228127f8

Original change's description:
> [vm/compiler] Optimize switch statements
>
> Switch statements that either contain only integers or only enum values of the same type can be optimized.
>
> Depending on the number of switch expressions and the number of holes that the range of switch expressions contains, either a binary search or a jump table is used.
>
> TEST=runtime/test/vm/dart{,_2}/optimized_switch
> TEST=tests/language{,_2}/switch
>
> Fixes: https://github.com/dart-lang/sdk/issues/49585
>
> Co-authored-by: Gabriel Terwesten gabriel@terwesten.net
>
> Change-Id: I62dcdb7843107f03de7e468c60b4db52ec78f676
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/253787
> Reviewed-by: Alexander Markov <alexmarkov@google.com>
> Commit-Queue: Alexander Markov <alexmarkov@google.com>

TEST=runtime/test/vm/dart{,_2}/optimized_switch
TEST=tests/language{,_2}/switch

Change-Id: Ie96e5ff41dce33e2425ba9ad15ecd931d09bec6e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/255700
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2022-08-22 15:09:17 +00:00
..
bin [vm/test] Remove checked-in binaries from MachO test. 2022-08-17 16:18:35 +00:00
docs [vm/inliner] Tweak inlining heuristic, improve List.of inlining. 2022-08-15 21:14:36 +00:00
include [vm, gc] Very basic RAIL. 2022-07-27 16:40:38 +00:00
lib [vm] Prevent Dart_NewSendPort from bypassing the arbitrary object checks. 2022-08-19 18:10:15 +00:00
observatory Fixed various typos in a lot of files 2022-07-25 12:21:59 +00:00
observatory_2 Fixed various typos in a lot of files 2022-07-25 12:21:59 +00:00
platform [vm] Fix kNumberOfReservedCpuRegisters on ARM64 2022-08-10 18:04:09 +00:00
tests Reland "[vm/compiler] Optimize switch statements" 2022-08-22 15:09:17 +00:00
third_party [vm] More pieces of Windows ARM support. 2022-04-07 23:15:48 +00:00
tools Use DartType.element2 instead of 'element'. 2022-08-18 15:56:14 +00:00
vm Reland "[vm/compiler] Optimize switch statements" 2022-08-22 15:09:17 +00:00
.clang-tidy
.gitignore
BUILD.gn [build] -fno-strict-vtable-pointers is a Clang-only flag. 2022-03-30 17:34:20 +00:00
codereview.settings
configs.gni
CPPLINT.cfg
OWNERS [infra] Add OWNERS to the Dart SDK 2022-02-14 14:06:34 +00:00
PRESUBMIT.py [python3] Migrate PRESUBMIT.py files 2021-08-16 08:29:54 +00:00
runtime_args.gni [VM] error: ‘mallinfo mallinfo()’ is deprecated 2021-12-08 00:25:10 +00:00