DescriptionVM: Improve specialization of calls on receiver in AOT mode.
When encountering call this.m(...) we can check if m resolves to the same
method in all concrete subclasses of the receiver class. If it does then
we don't need any checks and can just use a StaticCall instead of InstanceCall.
This is allows us to improve code quality for cases like:
class Base {
var _field;
foo() { _field = true; }
}
class A01 extends Base { }
...
class A16 extends Base { }
Previously AOT would generate InstanceCall(get:_field) in the method foo.
However with this change we generate StaticCall(...) which subsequently gets
handled by the inliner.
R=fschneider@google.com
BUG=
Committed: https://github.com/dart-lang/sdk/commit/ec9b1c385a4e7824cf133cffb834bb38d65fe1fc
Patch Set 1 #
Total comments: 2
Messages
Total messages: 5 (1 generated)
|