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

Side by Side Diff: pkg/compiler/lib/src/ssa/builder.dart

Issue 1809533004: Support serialization of WorldImpact (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Updated cf. comments + cleanup. Created 4 years, 9 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
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 import 'dart:collection'; 5 import 'dart:collection';
6 6
7 import 'package:js_runtime/shared/embedded_names.dart'; 7 import 'package:js_runtime/shared/embedded_names.dart';
8 8
9 import '../closure.dart'; 9 import '../closure.dart';
10 import '../common.dart'; 10 import '../common.dart';
(...skipping 5986 matching lines...) Expand 10 before | Expand all | Expand 10 after
5997 nativeBehavior.typesReturned.add(constructor.enclosingClass.thisType); 5997 nativeBehavior.typesReturned.add(constructor.enclosingClass.thisType);
5998 } 5998 }
5999 return new HForeignCode( 5999 return new HForeignCode(
6000 codeTemplate, 6000 codeTemplate,
6001 backend.dynamicType, filteredArguments, 6001 backend.dynamicType, filteredArguments,
6002 nativeBehavior: nativeBehavior) 6002 nativeBehavior: nativeBehavior)
6003 ..sourceInformation = sourceInformation; 6003 ..sourceInformation = sourceInformation;
6004 } 6004 }
6005 var target = new HForeignCode(js.js.parseForeignJS( 6005 var target = new HForeignCode(js.js.parseForeignJS(
6006 "${backend.namer.fixedBackendPath(element)}." 6006 "${backend.namer.fixedBackendPath(element)}."
6007 "${backend.getFixedBackendName(element)}"), 6007 "${backend.nativeData.getFixedBackendName(element)}"),
6008 backend.dynamicType, 6008 backend.dynamicType,
6009 <HInstruction>[]); 6009 <HInstruction>[]);
6010 add(target); 6010 add(target);
6011 // Strip off trailing arguments that were not specified. 6011 // Strip off trailing arguments that were not specified.
6012 // we could assert that the trailing arguments are all null. 6012 // we could assert that the trailing arguments are all null.
6013 // TODO(jacobr): rewrite named arguments to an object literal matching 6013 // TODO(jacobr): rewrite named arguments to an object literal matching
6014 // the factory constructor case. 6014 // the factory constructor case.
6015 arguments = arguments.where((arg) => arg != null).toList(); 6015 arguments = arguments.where((arg) => arg != null).toList();
6016 var inputs = <HInstruction>[target]..addAll(arguments); 6016 var inputs = <HInstruction>[target]..addAll(arguments);
6017 6017
(...skipping 3305 matching lines...) Expand 10 before | Expand all | Expand 10 after
9323 const _LoopTypeVisitor(); 9323 const _LoopTypeVisitor();
9324 int visitNode(ast.Node node) => HLoopBlockInformation.NOT_A_LOOP; 9324 int visitNode(ast.Node node) => HLoopBlockInformation.NOT_A_LOOP;
9325 int visitWhile(ast.While node) => HLoopBlockInformation.WHILE_LOOP; 9325 int visitWhile(ast.While node) => HLoopBlockInformation.WHILE_LOOP;
9326 int visitFor(ast.For node) => HLoopBlockInformation.FOR_LOOP; 9326 int visitFor(ast.For node) => HLoopBlockInformation.FOR_LOOP;
9327 int visitDoWhile(ast.DoWhile node) => HLoopBlockInformation.DO_WHILE_LOOP; 9327 int visitDoWhile(ast.DoWhile node) => HLoopBlockInformation.DO_WHILE_LOOP;
9328 int visitAsyncForIn(ast.AsyncForIn node) => HLoopBlockInformation.FOR_IN_LOOP; 9328 int visitAsyncForIn(ast.AsyncForIn node) => HLoopBlockInformation.FOR_IN_LOOP;
9329 int visitSyncForIn(ast.SyncForIn node) => HLoopBlockInformation.FOR_IN_LOOP; 9329 int visitSyncForIn(ast.SyncForIn node) => HLoopBlockInformation.FOR_IN_LOOP;
9330 int visitSwitchStatement(ast.SwitchStatement node) => 9330 int visitSwitchStatement(ast.SwitchStatement node) =>
9331 HLoopBlockInformation.SWITCH_CONTINUE_LOOP; 9331 HLoopBlockInformation.SWITCH_CONTINUE_LOOP;
9332 } 9332 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698