| OLD | NEW |
| 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 part of dart2js; | 5 part of dart2js; |
| 6 | 6 |
| 7 class EnqueueTask extends CompilerTask { | 7 class EnqueueTask extends CompilerTask { |
| 8 final Enqueuer codegen; | 8 final Enqueuer codegen; |
| 9 final Enqueuer resolution; | 9 final Enqueuer resolution; |
| 10 | 10 |
| (...skipping 374 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 385 registerNewSelector(setterName, | 385 registerNewSelector(setterName, |
| 386 new TypedSelector(type, setter), | 386 new TypedSelector(type, setter), |
| 387 universe.fieldSetters); | 387 universe.fieldSetters); |
| 388 }); | 388 }); |
| 389 } | 389 } |
| 390 | 390 |
| 391 void registerIsCheck(DartType type) { | 391 void registerIsCheck(DartType type) { |
| 392 universe.isChecks.add(type); | 392 universe.isChecks.add(type); |
| 393 } | 393 } |
| 394 | 394 |
| 395 void registerJsCall(Send node, ResolverVisitor resolver) { |
| 396 nativeEnqueuer.registerJsCall(node, this, resolver); |
| 397 } |
| 398 |
| 399 |
| 395 void forEach(f(WorkItem work)) { | 400 void forEach(f(WorkItem work)) { |
| 396 while (!queue.isEmpty) { | 401 while (!queue.isEmpty) { |
| 397 f(queue.removeLast()); // TODO(kasperl): Why isn't this removeFirst? | 402 f(queue.removeLast()); // TODO(kasperl): Why isn't this removeFirst? |
| 398 } | 403 } |
| 399 } | 404 } |
| 400 | 405 |
| 401 String toString() => 'Enqueuer($name)'; | 406 String toString() => 'Enqueuer($name)'; |
| 402 | 407 |
| 403 void logSummary(log(message)) { | 408 void logSummary(log(message)) { |
| 404 log(isResolutionQueue | 409 log(isResolutionQueue |
| 405 ? 'Resolved ${resolvedElements.length} elements.' | 410 ? 'Resolved ${resolvedElements.length} elements.' |
| 406 : 'Compiled ${universe.generatedCode.length} methods.'); | 411 : 'Compiled ${universe.generatedCode.length} methods.'); |
| 407 nativeEnqueuer.logSummary(log); | 412 nativeEnqueuer.logSummary(log); |
| 408 } | 413 } |
| 409 } | 414 } |
| OLD | NEW |