mirror of
https://github.com/dart-lang/sdk
synced 2024-09-16 04:47:03 +00:00
3675fd25f4
The representation of record shape in record instances and record types is changed from a pair int num_fields Array field_names to a single integer - packed bitfield int num_fields(16) int field_names_index(kSmiBits-16) where field names index is an index in the array available from ObjectStore. With the new representation of record shapes: 1) Size of record instances is reduced. 2) Number of comparisons for a shape test reduced from 2 to 1 (shape test is used during type checks). 3) A few operations removed from Record.hashCode. 4) Type testing stubs (TTS) are now supported for record types with named fields. Previously it was not possible to check shape of records with named fields in TTS as TTS cannot access object pool and cannot load field names array). TEST=existing Issue: https://github.com/dart-lang/sdk/issues/49719 Change-Id: I7cdcbb53938aba5d561cd24dc99530395dbbea7e Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/276201 Reviewed-by: Ryan Macnak <rmacnak@google.com> Commit-Queue: Alexander Markov <alexmarkov@google.com> |
||
---|---|---|
.. | ||
concurrency | ||
vm |