| Index: pkg/compiler/lib/src/ssa/optimize.dart
|
| diff --git a/pkg/compiler/lib/src/ssa/optimize.dart b/pkg/compiler/lib/src/ssa/optimize.dart
|
| index e3e5a51d1a54d60f761c59b540b24a37b12a8f65..2893b87fa61fa69deead301cfc8c4a0837576215 100644
|
| --- a/pkg/compiler/lib/src/ssa/optimize.dart
|
| +++ b/pkg/compiler/lib/src/ssa/optimize.dart
|
| @@ -468,7 +468,7 @@ class SsaInstructionSimplifier extends HBaseVisitor
|
| node.selector.applies(element)) {
|
| MethodElement method = element;
|
|
|
| - if (backend.isNative(method)) {
|
| + if (backend.nativeData.isNativeMember(method)) {
|
| HInstruction folded = tryInlineNativeMethod(node, method);
|
| if (folded != null) return folded;
|
| } else {
|
| @@ -494,7 +494,8 @@ class SsaInstructionSimplifier extends HBaseVisitor
|
| element.isField &&
|
| element.name == node.selector.name) {
|
| FieldEntity field = element;
|
| - if (!backend.isNative(field) && !node.isCallOnInterceptor(closedWorld)) {
|
| + if (!backend.nativeData.isNativeMember(field) &&
|
| + !node.isCallOnInterceptor(closedWorld)) {
|
| HInstruction receiver = node.getDartReceiver(closedWorld);
|
| TypeMask type = TypeMaskFactory.inferredTypeForElement(
|
| field as Entity, globalInferenceResults);
|
| @@ -569,7 +570,7 @@ class SsaInstructionSimplifier extends HBaseVisitor
|
| // Strengthen instruction type from annotations to help optimize
|
| // dependent instructions.
|
| native.NativeBehavior nativeBehavior =
|
| - backend.getNativeMethodBehavior(method);
|
| + backend.nativeData.getNativeMethodBehavior(method);
|
| TypeMask returnType =
|
| TypeMaskFactory.fromNativeBehavior(nativeBehavior, closedWorld);
|
| HInvokeDynamicMethod result =
|
| @@ -958,12 +959,12 @@ class SsaInstructionSimplifier extends HBaseVisitor
|
| }
|
|
|
| HInstruction directFieldGet(HInstruction receiver, FieldEntity field) {
|
| - bool isAssignable = !closedWorld.fieldNeverChanges(field as MemberEntity);
|
| + bool isAssignable = !closedWorld.fieldNeverChanges(field);
|
|
|
| TypeMask type;
|
| - if (backend.isNative(field.enclosingClass)) {
|
| + if (backend.nativeData.isNativeClass(field.enclosingClass)) {
|
| type = TypeMaskFactory.fromNativeBehavior(
|
| - backend.getNativeFieldLoadBehavior(field), closedWorld);
|
| + backend.nativeData.getNativeFieldLoadBehavior(field), closedWorld);
|
| } else {
|
| type = TypeMaskFactory.inferredTypeForElement(
|
| field as Entity, globalInferenceResults);
|
|
|