Modified: trunk/Source/_javascript_Core/jit/JITOperations.cpp (212145 => 212146)
--- trunk/Source/_javascript_Core/jit/JITOperations.cpp 2017-02-10 21:31:28 UTC (rev 212145)
+++ trunk/Source/_javascript_Core/jit/JITOperations.cpp 2017-02-10 21:34:27 UTC (rev 212146)
@@ -210,7 +210,7 @@
baseValue.getPropertySlot(exec, ident, slot);
RETURN_IF_EXCEPTION(scope, encodedJSValue());
- if (stubInfo->considerCaching(baseValue.structureOrNull()) && !slot.isTaintedByOpaqueObject() && (slot.isCacheableValue() || slot.isCacheableGetter() || slot.isUnset()))
+ if (stubInfo->considerCaching(exec->codeBlock(), baseValue.structureOrNull()) && !slot.isTaintedByOpaqueObject() && (slot.isCacheableValue() || slot.isCacheableGetter() || slot.isUnset()))
repatchGetByID(exec, baseValue, ident, slot, *stubInfo, GetByIDKind::Pure);
return JSValue::encode(slot.getPureResult());
@@ -259,7 +259,7 @@
LOG_IC((ICEvent::OperationGetByIdOptimize, baseValue.classInfoOrNull(*vm), ident));
return JSValue::encode(baseValue.getPropertySlot(exec, ident, [&] (bool found, PropertySlot& slot) -> JSValue {
- if (stubInfo->considerCaching(baseValue.structureOrNull()))
+ if (stubInfo->considerCaching(exec->codeBlock(), baseValue.structureOrNull()))
repatchGetByID(exec, baseValue, ident, slot, *stubInfo, GetByIDKind::Normal);
return found ? slot.getValue(exec, ident) : jsUndefined();
}));
@@ -288,7 +288,7 @@
RELEASE_ASSERT(accessType == stubInfo->accessType);
- if (stubInfo->considerCaching(asObject(base)->structure()))
+ if (stubInfo->considerCaching(exec->codeBlock(), asObject(base)->structure()))
repatchIn(exec, base, ident, result, slot, *stubInfo);
return JSValue::encode(jsBoolean(result));
@@ -403,7 +403,8 @@
JSValue value = JSValue::decode(encodedValue);
JSValue baseValue = JSValue::decode(encodedBase);
LOG_IC((ICEvent::OperationPutByIdStrictOptimize, baseValue.classInfoOrNull(*vm), ident));
- PutPropertySlot slot(baseValue, true, exec->codeBlock()->putByIdContext());
+ CodeBlock* codeBlock = exec->codeBlock();
+ PutPropertySlot slot(baseValue, true, codeBlock->putByIdContext());
Structure* structure = baseValue.isCell() ? baseValue.asCell()->structure(*vm) : nullptr;
baseValue.putInline(exec, ident, value, slot);
@@ -412,7 +413,7 @@
if (accessType != static_cast<AccessType>(stubInfo->accessType))
return;
- if (stubInfo->considerCaching(structure))
+ if (stubInfo->considerCaching(codeBlock, structure))
repatchPutByID(exec, baseValue, structure, ident, slot, *stubInfo, NotDirect);
}
@@ -430,7 +431,8 @@
JSValue value = JSValue::decode(encodedValue);
JSValue baseValue = JSValue::decode(encodedBase);
LOG_IC((ICEvent::OperationPutByIdNonStrictOptimize, baseValue.classInfoOrNull(*vm), ident));
- PutPropertySlot slot(baseValue, false, exec->codeBlock()->putByIdContext());
+ CodeBlock* codeBlock = exec->codeBlock();
+ PutPropertySlot slot(baseValue, false, codeBlock->putByIdContext());
Structure* structure = baseValue.isCell() ? baseValue.asCell()->structure(*vm) : nullptr;
baseValue.putInline(exec, ident, value, slot);
@@ -439,7 +441,7 @@
if (accessType != static_cast<AccessType>(stubInfo->accessType))
return;
- if (stubInfo->considerCaching(structure))
+ if (stubInfo->considerCaching(codeBlock, structure))
repatchPutByID(exec, baseValue, structure, ident, slot, *stubInfo, NotDirect);
}
@@ -456,7 +458,8 @@
JSValue value = JSValue::decode(encodedValue);
JSObject* baseObject = asObject(JSValue::decode(encodedBase));
LOG_IC((ICEvent::OperationPutByIdDirectStrictOptimize, baseObject->classInfo(*vm), ident));
- PutPropertySlot slot(baseObject, true, exec->codeBlock()->putByIdContext());
+ CodeBlock* codeBlock = exec->codeBlock();
+ PutPropertySlot slot(baseObject, true, codeBlock->putByIdContext());
Structure* structure = baseObject->structure(*vm);
baseObject->putDirect(exec->vm(), ident, value, slot);
@@ -464,7 +467,7 @@
if (accessType != static_cast<AccessType>(stubInfo->accessType))
return;
- if (stubInfo->considerCaching(structure))
+ if (stubInfo->considerCaching(codeBlock, structure))
repatchPutByID(exec, baseObject, structure, ident, slot, *stubInfo, Direct);
}
@@ -481,7 +484,8 @@
JSValue value = JSValue::decode(encodedValue);
JSObject* baseObject = asObject(JSValue::decode(encodedBase));
LOG_IC((ICEvent::OperationPutByIdDirectNonStrictOptimize, baseObject->classInfo(*vm), ident));
- PutPropertySlot slot(baseObject, false, exec->codeBlock()->putByIdContext());
+ CodeBlock* codeBlock = exec->codeBlock();
+ PutPropertySlot slot(baseObject, false, codeBlock->putByIdContext());
Structure* structure = baseObject->structure(*vm);
baseObject->putDirect(exec->vm(), ident, value, slot);
@@ -489,7 +493,7 @@
if (accessType != static_cast<AccessType>(stubInfo->accessType))
return;
- if (stubInfo->considerCaching(structure))
+ if (stubInfo->considerCaching(codeBlock, structure))
repatchPutByID(exec, baseObject, structure, ident, slot, *stubInfo, Direct);
}
@@ -612,7 +616,7 @@
ConcurrentJSLocker locker(codeBlock->m_lock);
byValInfo->arrayProfile->computeUpdatedPrediction(locker, codeBlock, structure);
- JIT::compilePutByVal(&vm, exec->codeBlock(), byValInfo, returnAddress, arrayMode);
+ JIT::compilePutByVal(&vm, codeBlock, byValInfo, returnAddress, arrayMode);
optimizationResult = OptimizationResult::Optimized;
}
}
@@ -696,7 +700,7 @@
ConcurrentJSLocker locker(codeBlock->m_lock);
byValInfo->arrayProfile->computeUpdatedPrediction(locker, codeBlock, structure);
- JIT::compileDirectPutByVal(&vm, exec->codeBlock(), byValInfo, returnAddress, arrayMode);
+ JIT::compileDirectPutByVal(&vm, codeBlock, byValInfo, returnAddress, arrayMode);
optimizationResult = OptimizationResult::Optimized;
}
}