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

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

Issue 10539156: Track fields which are known to be always set to integer constants (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 6 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 EnqueueTask extends CompilerTask { 5 class EnqueueTask extends CompilerTask {
6 final Enqueuer codegen; 6 final Enqueuer codegen;
7 final Enqueuer resolution; 7 final Enqueuer resolution;
8 8
9 String get name() => 'Enqueue'; 9 String get name() => 'Enqueue';
10 10
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after
295 } 295 }
296 296
297 void registerFieldGetter(SourceString getterName, Type type) { 297 void registerFieldGetter(SourceString getterName, Type type) {
298 task.measure(() { 298 task.measure(() {
299 registerNewSelector(getterName, 299 registerNewSelector(getterName,
300 new TypedSelector(type, Selector.GETTER), 300 new TypedSelector(type, Selector.GETTER),
301 universe.fieldGetters); 301 universe.fieldGetters);
302 }); 302 });
303 } 303 }
304 304
305 void registerFieldSetter(SourceString setterName, Type type) { 305 void registerFieldSetter(SourceString setterName, Type type, bool isInteger) {
306 task.measure(() { 306 task.measure(() {
307 registerNewSelector(setterName, 307 registerNewSelector(setterName,
308 new TypedSelector(type, Selector.SETTER), 308 new TypedSelector(type, Selector.SETTER),
309 universe.fieldSetters); 309 universe.fieldSetters);
310 universe.updateFieldIntegerSetters(type, setterName, isInteger);
310 }); 311 });
311 } 312 }
312 313
313 // TODO(ngeoffray): This should get a type. 314 // TODO(ngeoffray): This should get a type.
314 void registerIsCheck(Element element) { 315 void registerIsCheck(Element element) {
315 universe.isChecks.add(element); 316 universe.isChecks.add(element);
316 } 317 }
317 318
318 void forEach(f(WorkItem work)) { 319 void forEach(f(WorkItem work)) {
319 while (!queue.isEmpty()) { 320 while (!queue.isEmpty()) {
320 f(queue.removeLast()); 321 f(queue.removeLast());
321 } 322 }
322 } 323 }
323 } 324 }
OLDNEW
« no previous file with comments | « no previous file | lib/compiler/implementation/ssa/codegen.dart » ('j') | lib/compiler/implementation/ssa/codegen.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698