| Index: pkg/compiler/lib/src/ssa/types_propagation.dart
|
| diff --git a/pkg/compiler/lib/src/ssa/types_propagation.dart b/pkg/compiler/lib/src/ssa/types_propagation.dart
|
| index eb21bb402cb70999d5514ab5e0ceea01109835e3..4f3e7eec8f94605553b1d5fb0e39d066f961fe10 100644
|
| --- a/pkg/compiler/lib/src/ssa/types_propagation.dart
|
| +++ b/pkg/compiler/lib/src/ssa/types_propagation.dart
|
| @@ -183,13 +183,21 @@ class SsaTypePropagator extends HBaseVisitor implements OptimizationPhase {
|
| }
|
| }
|
| }
|
| + if (inputType != outputType) {
|
| + input.replaceAllUsersDominatedBy(instruction.next, instruction);
|
| + }
|
| return outputType;
|
| }
|
|
|
| TypeMask visitTypeKnown(HTypeKnown instruction) {
|
| HInstruction input = instruction.checkedInput;
|
| - return instruction.knownType.intersection(
|
| - input.instructionType, classWorld);
|
| + TypeMask inputType = input.instructionType;
|
| + TypeMask outputType =
|
| + instruction.knownType.intersection(inputType, classWorld);
|
| + if (inputType != outputType) {
|
| + input.replaceAllUsersDominatedBy(instruction.next, instruction);
|
| + }
|
| + return outputType;
|
| }
|
|
|
| void convertInput(HInvokeDynamic instruction,
|
|
|