Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(525)

Unified Diff: sdk/lib/_internal/compiler/implementation/ssa/codegen.dart

Issue 11421056: Re-apply issue 11308169: GVN getInterceptor and use the interceptor constant when the type is known. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: sdk/lib/_internal/compiler/implementation/ssa/codegen.dart
===================================================================
--- sdk/lib/_internal/compiler/implementation/ssa/codegen.dart (revision 15379)
+++ sdk/lib/_internal/compiler/implementation/ssa/codegen.dart (working copy)
@@ -1559,18 +1559,12 @@
arguments = visitArguments(node.inputs);
bool inLoop = node.block.enclosingLoopHeader != null;
- // Register this invocation to collect the types used at all call sites.
Selector selector = getOptimizedSelectorFor(node, node.selector);
- // TODO(ngeoffray): Remove the following restriction. Because
- // the second input of this interceptor call is the actual
- // receiver (the first is the interceptor), the backend gets
- // confused. We should pass a list of types instead of a node to
- // [registerDynamicInvocation].
- if (!node.isInterceptorCall) {
- backend.registerDynamicInvocation(node, selector, types);
- } else {
+ if (node.isInterceptorCall) {
backend.addInterceptedSelector(selector);
}
+ // Register this invocation to collect the types used at all call sites.
+ backend.registerDynamicInvocation(node, selector, types);
// If we don't know what we're calling or if we are calling a getter,
// we need to register that fact that we may be calling a closure

Powered by Google App Engine
This is Rietveld 408576698