Inline fast-bailout-checks for LookupIterator::UpdateProtector

BUG=

Review URL: https://codereview.chromium.org/1754023003

Cr-Commit-Position: refs/heads/master@{#34438}
This commit is contained in:
verwaest 2016-03-02 08:42:46 -08:00 committed by Commit bot
parent ca5bd8d4a9
commit d98570a1eb
2 changed files with 10 additions and 5 deletions

View File

@ -171,10 +171,7 @@ bool LookupIterator::HolderIsInContextIndex(uint32_t index) const {
return false;
}
void LookupIterator::UpdateProtector() {
if (!FLAG_harmony_species) return;
if (IsElement()) return;
void LookupIterator::InternalUpdateProtector() {
if (isolate_->bootstrapper()->IsActive()) return;
if (!isolate_->IsArraySpeciesLookupChainIntact()) return;

View File

@ -257,9 +257,17 @@ class LookupIterator final BASE_EMBEDDED {
}
Handle<Object> GetDataValue() const;
void WriteDataValue(Handle<Object> value);
void UpdateProtector();
inline void UpdateProtector() {
if (FLAG_harmony_species && !IsElement() &&
(*name_ == heap()->constructor_string() ||
*name_ == heap()->species_symbol())) {
InternalUpdateProtector();
}
}
private:
void InternalUpdateProtector();
enum class InterceptorState {
kUninitialized,
kSkipNonMasking,