mirror of
https://github.com/dart-lang/sdk
synced 2024-09-05 00:13:50 +00:00
5117c45770
Previously, when preparing a Parameter stub during inlining, compiler unconditionally used argument type (from the caller). This type could be less accurate than static or inferred parameter type of the callee. For example, the argument could originate from inlined generic ListIterator.current: v24 <- LoadField(v23 . _current@9040228) T{X0??} and static type could be 'int'. This change combines argument type from callee with a parameter type from caller during inlining. In order to get parameter type for optional parameters, ParameterInstr is extended to hold real parameter index and ParameterIndex::ComputeType is extended to work on parameters which are not passed directly. Also, this change fixes the incorrect non-nullable receiver type for Object and Null methods. TEST=runtime/tests/vm/dart/regress_51790_il_test.dart Fixes https://github.com/dart-lang/sdk/issues/51790 Change-Id: I19fff19833a6148ed36a16895626e4e1d8ae62d3 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/290602 Reviewed-by: Slava Egorov <vegorov@google.com> Commit-Queue: Alexander Markov <alexmarkov@google.com> |
||
---|---|---|
.. | ||
bin | ||
docs | ||
include | ||
lib | ||
observatory | ||
observatory_2 | ||
platform | ||
tests | ||
third_party | ||
tools | ||
vm | ||
.clang-tidy | ||
.gitignore | ||
BUILD.gn | ||
codereview.settings | ||
configs.gni | ||
CPPLINT.cfg | ||
OWNERS | ||
PRESUBMIT.py | ||
runtime_args.gni |