Index: src/ia32/stub-cache-ia32.cc |
diff --git a/src/ia32/stub-cache-ia32.cc b/src/ia32/stub-cache-ia32.cc |
index c27a60fd06573ae7fc91c30fd343886f3772d453..051a8177eac0f10bf168ed6324f50c5947766df4 100644 |
--- a/src/ia32/stub-cache-ia32.cc |
+++ b/src/ia32/stub-cache-ia32.cc |
@@ -878,13 +878,10 @@ Register StubCompiler::CheckPrototypes(Handle<JSObject> object, |
if (in_new_space) { |
// Save the map in scratch1 for later. |
__ mov(scratch1, FieldOperand(reg, HeapObject::kMapOffset)); |
- __ cmp(scratch1, Immediate(current_map)); |
- } else { |
- __ cmp(FieldOperand(reg, HeapObject::kMapOffset), |
- Immediate(current_map)); |
} |
- // Branch on the result of the map check. |
- __ j(not_equal, miss); |
+ __ CheckMap(reg, current_map, miss, DONT_DO_SMI_CHECK, |
fschneider
2012/01/04 09:20:18
Is this part of the change missing in stub-cache-a
danno
2012/01/04 10:42:15
Done.
|
+ ALLOW_ELEMENT_TRANSITION_MAPS); |
+ |
// Check access rights to the global object. This has to happen after |
// the map check so that we know that the object is actually a global |
// object. |
@@ -916,9 +913,8 @@ Register StubCompiler::CheckPrototypes(Handle<JSObject> object, |
LOG(isolate(), IntEvent("check-maps-depth", depth + 1)); |
// Check the holder map. |
- __ cmp(FieldOperand(reg, HeapObject::kMapOffset), |
- Immediate(Handle<Map>(holder->map()))); |
- __ j(not_equal, miss); |
+ __ CheckMap(reg, Handle<Map>(holder->map()), |
+ miss, DONT_DO_SMI_CHECK, ALLOW_ELEMENT_TRANSITION_MAPS); |
// Perform security check for access to the global object. |
ASSERT(holder->IsJSGlobalProxy() || !holder->IsAccessCheckNeeded()); |