Index: src/builtins/s390/builtins-s390.cc |
diff --git a/src/builtins/s390/builtins-s390.cc b/src/builtins/s390/builtins-s390.cc |
index 3930fffbed0ce3e075031fb19f109ca773ef9888..41aa4a3c6ce7167760b74836c8ec543afcc22ded 100644 |
--- a/src/builtins/s390/builtins-s390.cc |
+++ b/src/builtins/s390/builtins-s390.cc |
@@ -1368,6 +1368,12 @@ |
Register closure = r3; |
Register map = r8; |
Register index = r4; |
+ |
+ // Do we have a valid feedback vector? |
+ __ LoadP(index, FieldMemOperand(closure, JSFunction::kLiteralsOffset)); |
+ __ LoadP(index, FieldMemOperand(index, LiteralsArray::kFeedbackVectorOffset)); |
+ __ JumpIfRoot(index, Heap::kUndefinedValueRootIndex, &gotta_call_runtime); |
+ |
__ LoadP(map, |
FieldMemOperand(closure, JSFunction::kSharedFunctionInfoOffset)); |
__ LoadP(map, |
@@ -1397,18 +1403,6 @@ |
__ LoadP(temp, FieldMemOperand(temp, WeakCell::kValueOffset)); |
__ CmpP(temp, native_context); |
__ bne(&loop_bottom, Label::kNear); |
- // Literals available? |
- __ LoadP(temp, |
- FieldMemOperand(array_pointer, |
- SharedFunctionInfo::kOffsetToPreviousLiterals)); |
- __ LoadP(temp, FieldMemOperand(temp, WeakCell::kValueOffset)); |
- __ JumpIfSmi(temp, &gotta_call_runtime); |
- |
- // Save the literals in the closure. |
- __ StoreP(temp, FieldMemOperand(closure, JSFunction::kLiteralsOffset), r0); |
- __ RecordWriteField(closure, JSFunction::kLiteralsOffset, temp, r6, |
- kLRHasNotBeenSaved, kDontSaveFPRegs, EMIT_REMEMBERED_SET, |
- OMIT_SMI_CHECK); |
// Code available? |
Register entry = r6; |
@@ -1418,7 +1412,7 @@ |
__ LoadP(entry, FieldMemOperand(entry, WeakCell::kValueOffset)); |
__ JumpIfSmi(entry, &try_shared); |
- // Found literals and code. Get them into the closure and return. |
+ // Found code. Get it into the closure and return. |
// Store code entry in the closure. |
__ AddP(entry, entry, Operand(Code::kHeaderSize - kHeapObjectTag)); |
__ StoreP(entry, FieldMemOperand(closure, JSFunction::kCodeEntryOffset), r0); |
@@ -1452,7 +1446,7 @@ |
__ CmpSmiLiteral(index, Smi::FromInt(1), r0); |
__ bgt(&loop_top); |
- // We found neither literals nor code. |
+ // We found no code. |
__ b(&gotta_call_runtime); |
__ bind(&try_shared); |