Open
Description
The initial implementation of records in dart2js (#49718) has overly conservative inference results.
This leads to dispatch overhead (e.g. getInterceptor vs array access).
This task is to improve the analysis.
- Perform inference on record fields
- Inference should have similar precision for each field of a returned record to what it does for returning a non-record value
- The result of a dynamic getter of a field name should include fields with that name
- Trace records from constants and literals to see if they would benefit from specialization
TODO(50701)
is used to mark some the the locations that need improvement.