1210d27678
Allocate the canonical true and false objects right after the null
object such that their pointers are the same except for a single bit.
This enables a number of optimizations:
- Test of a bool value becomes a bit test when it is known that the
value is a bool. on ARM64, this bit test can be combined with the
branch.
- Negation of a bool value becomes an xor when it is known that the
value is a bool.
- Load of a bool value becomes an immediate add with the null register
on ARM64.
This is a reland of f8ead09ba2
Change-Id: Iadb2169f80d3731153df3a93772f6142c3197260
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/142375
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Aske Simon Christensen <askesc@google.com>