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

Side by Side Diff: lib/compiler/implementation/universe.dart

Issue 10827181: Collect call site information and use that for estimating parameter types (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Additional fix Created 8 years, 4 months 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 class Universe { 5 class Universe {
6 Map<Element, CodeBuffer> generatedCode; 6 Map<Element, CodeBuffer> generatedCode;
7 Map<Element, CodeBuffer> generatedBailoutCode; 7 Map<Element, CodeBuffer> generatedBailoutCode;
8 final Set<ClassElement> instantiatedClasses; 8 final Set<ClassElement> instantiatedClasses;
9 final Set<SourceString> instantiatedClassInstanceFields; 9 final Set<SourceString> instantiatedClassInstanceFields;
10 final Set<FunctionElement> staticFunctionsNeedingGetter; 10 final Set<FunctionElement> staticFunctionsNeedingGetter;
(...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after
276 if (namedArguments.isEmpty()) return namedArguments; 276 if (namedArguments.isEmpty()) return namedArguments;
277 if (!orderedNamedArguments.isEmpty()) return orderedNamedArguments; 277 if (!orderedNamedArguments.isEmpty()) return orderedNamedArguments;
278 278
279 orderedNamedArguments.addAll(namedArguments); 279 orderedNamedArguments.addAll(namedArguments);
280 orderedNamedArguments.sort((SourceString first, SourceString second) { 280 orderedNamedArguments.sort((SourceString first, SourceString second) {
281 return first.slowToString().compareTo(second.slowToString()); 281 return first.slowToString().compareTo(second.slowToString());
282 }); 282 });
283 return orderedNamedArguments; 283 return orderedNamedArguments;
284 } 284 }
285 285
286 toString() => '$kind $argumentCount'; 286 toString() => 'Selector($kind, $argumentCount)';
287 } 287 }
288 288
289 class TypedSelector extends Selector { 289 class TypedSelector extends Selector {
290 /** 290 /**
291 * The type of the receiver. Any subtype of that type can be the 291 * The type of the receiver. Any subtype of that type can be the
292 * target of the invocation. 292 * target of the invocation.
293 */ 293 */
294 final Type receiverType; 294 final Type receiverType;
295 295
296 TypedSelector(this.receiverType, Selector selector) 296 TypedSelector(this.receiverType, Selector selector)
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
346 } 346 }
347 347
348 return false; 348 return false;
349 } 349 }
350 350
351 bool operator ==(other) { 351 bool operator ==(other) {
352 if (other is !TypedSelector) return false; 352 if (other is !TypedSelector) return false;
353 if (other.receiverType !== receiverType) return false; 353 if (other.receiverType !== receiverType) return false;
354 return super == other; 354 return super == other;
355 } 355 }
356
357 toString() => 'TypedSelector($kind, $receiverType, $argumentCount)';
356 } 358 }
OLDNEW
« no previous file with comments | « lib/compiler/implementation/ssa/codegen.dart ('k') | tests/compiler/dart2js/call_site_type_inferer_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698