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

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

Issue 2000223002: Revert "Adjusts dart2js backend to handle method type arguments." (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 years, 7 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
« no previous file with comments | « pkg/compiler/lib/src/ssa/builder.dart ('k') | tests/language/generic_local_functions_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 '../common/codegen.dart' show CodegenWorkItem; 5 import '../common/codegen.dart' show CodegenWorkItem;
6 import '../common/tasks.dart' show CompilerTask; 6 import '../common/tasks.dart' show CompilerTask;
7 import '../compiler.dart' show Compiler; 7 import '../compiler.dart' show Compiler;
8 import '../constants/constant_system.dart'; 8 import '../constants/constant_system.dart';
9 import '../constants/values.dart'; 9 import '../constants/values.dart';
10 import '../core_types.dart' show CoreClasses; 10 import '../core_types.dart' show CoreClasses;
(...skipping 762 matching lines...) Expand 10 before | Expand all | Expand 10 after
773 } 773 }
774 774
775 HInstruction removeIfCheckAlwaysSucceeds(HCheck node, TypeMask checkedType) { 775 HInstruction removeIfCheckAlwaysSucceeds(HCheck node, TypeMask checkedType) {
776 ClassWorld classWorld = compiler.world; 776 ClassWorld classWorld = compiler.world;
777 if (checkedType.containsAll(classWorld)) return node; 777 if (checkedType.containsAll(classWorld)) return node;
778 HInstruction input = node.checkedInput; 778 HInstruction input = node.checkedInput;
779 TypeMask inputType = input.instructionType; 779 TypeMask inputType = input.instructionType;
780 return inputType.isInMask(checkedType, classWorld) ? input : node; 780 return inputType.isInMask(checkedType, classWorld) ? input : node;
781 } 781 }
782 782
783 HInstruction removeCheck(HCheck node) => node.checkedInput;
784
785 VariableElement findConcreteFieldForDynamicAccess( 783 VariableElement findConcreteFieldForDynamicAccess(
786 HInstruction receiver, Selector selector) { 784 HInstruction receiver, Selector selector) {
787 TypeMask receiverType = receiver.instructionType; 785 TypeMask receiverType = receiver.instructionType;
788 return compiler.world.locateSingleField(selector, receiverType); 786 return compiler.world.locateSingleField(selector, receiverType);
789 } 787 }
790 788
791 HInstruction visitFieldGet(HFieldGet node) { 789 HInstruction visitFieldGet(HFieldGet node) {
792 if (node.isNullCheck) return node; 790 if (node.isNullCheck) return node;
793 var receiver = node.receiver; 791 var receiver = node.receiver;
794 if (node.element == helpers.jsIndexableLength) { 792 if (node.element == helpers.jsIndexableLength) {
(...skipping 1586 matching lines...) Expand 10 before | Expand all | Expand 10 after
2381 2379
2382 keyedValues.forEach((receiver, values) { 2380 keyedValues.forEach((receiver, values) {
2383 result.keyedValues[receiver] = 2381 result.keyedValues[receiver] =
2384 new Map<HInstruction, HInstruction>.from(values); 2382 new Map<HInstruction, HInstruction>.from(values);
2385 }); 2383 });
2386 2384
2387 result.nonEscapingReceivers.addAll(nonEscapingReceivers); 2385 result.nonEscapingReceivers.addAll(nonEscapingReceivers);
2388 return result; 2386 return result;
2389 } 2387 }
2390 } 2388 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/ssa/builder.dart ('k') | tests/language/generic_local_functions_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698