Index: src/ic/ia32/handler-compiler-ia32.cc |
diff --git a/src/ic/ia32/handler-compiler-ia32.cc b/src/ic/ia32/handler-compiler-ia32.cc |
index 3df2140f5766906add336138e02259d86d3f9550..d0b940bcc550b38711f3b28fde0eaa337d0a3ac5 100644 |
--- a/src/ic/ia32/handler-compiler-ia32.cc |
+++ b/src/ic/ia32/handler-compiler-ia32.cc |
@@ -415,12 +415,6 @@ Register PropertyHandlerCompiler::CheckPrototypes( |
reg = holder_reg; // From now on the object will be in holder_reg. |
__ mov(reg, FieldOperand(scratch1, Map::kPrototypeOffset)); |
} else { |
- bool in_new_space = heap()->InNewSpace(*prototype); |
- // Two possible reasons for loading the prototype from the map: |
- // (1) Can't store references to new space in code. |
- // (2) Handler is shared for all receivers with the same prototype |
- // map (but not necessarily the same prototype instance). |
- bool load_prototype_from_map = in_new_space || depth == 1; |
if (depth != 1 || check == CHECK_ALL_MAPS) { |
__ CheckMap(reg, current_map, miss, DONT_DO_SMI_CHECK); |
} |
@@ -438,18 +432,9 @@ Register PropertyHandlerCompiler::CheckPrototypes( |
name, scratch2, miss); |
} |
- if (load_prototype_from_map) { |
- // Save the map in scratch1 for later. |
- __ mov(scratch1, FieldOperand(reg, HeapObject::kMapOffset)); |
- } |
- |
+ __ mov(scratch1, FieldOperand(reg, HeapObject::kMapOffset)); |
reg = holder_reg; // From now on the object will be in holder_reg. |
- |
- if (load_prototype_from_map) { |
- __ mov(reg, FieldOperand(scratch1, Map::kPrototypeOffset)); |
- } else { |
- __ mov(reg, prototype); |
- } |
+ __ mov(reg, FieldOperand(scratch1, Map::kPrototypeOffset)); |
} |
// Go to the next object in the prototype chain. |