Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(154)

Side by Side Diff: src/isolate-inl.h

Issue 2900333002: Revert of [turbofan] Speculatively optimize string character access. (Closed)
Patch Set: Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/isolate.h ('k') | test/mjsunit/regress/regress-6391.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_ISOLATE_INL_H_ 5 #ifndef V8_ISOLATE_INL_H_
6 #define V8_ISOLATE_INL_H_ 6 #define V8_ISOLATE_INL_H_
7 7
8 #include "src/isolate.h" 8 #include "src/isolate.h"
9 #include "src/objects-inl.h" 9 #include "src/objects-inl.h"
10 10
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 // All that could be checked reliably is that 126 // All that could be checked reliably is that
127 // Array.prototype.constructor == Array. Given that limitation, no check is 127 // Array.prototype.constructor == Array. Given that limitation, no check is
128 // done here. In place, there are mjsunit tests harmony/array-species* which 128 // done here. In place, there are mjsunit tests harmony/array-species* which
129 // ensure that behavior is correct in various invalid protector cases. 129 // ensure that behavior is correct in various invalid protector cases.
130 130
131 Cell* species_cell = heap()->species_protector(); 131 Cell* species_cell = heap()->species_protector();
132 return species_cell->value()->IsSmi() && 132 return species_cell->value()->IsSmi() &&
133 Smi::cast(species_cell->value())->value() == kProtectorValid; 133 Smi::cast(species_cell->value())->value() == kProtectorValid;
134 } 134 }
135 135
136 bool Isolate::IsStringBoundsCheckIntact() {
137 Cell* string_bounds_check_cell = heap()->string_bounds_check_protector();
138 return string_bounds_check_cell->value() == Smi::FromInt(kProtectorValid);
139 }
140
141 bool Isolate::IsStringLengthOverflowIntact() { 136 bool Isolate::IsStringLengthOverflowIntact() {
142 PropertyCell* string_length_cell = heap()->string_length_protector(); 137 PropertyCell* string_length_cell = heap()->string_length_protector();
143 return string_length_cell->value() == Smi::FromInt(kProtectorValid); 138 return string_length_cell->value() == Smi::FromInt(kProtectorValid);
144 } 139 }
145 140
146 bool Isolate::IsFastArrayIterationIntact() { 141 bool Isolate::IsFastArrayIterationIntact() {
147 Cell* fast_iteration_cell = heap()->fast_array_iteration_protector(); 142 Cell* fast_iteration_cell = heap()->fast_array_iteration_protector();
148 return fast_iteration_cell->value() == Smi::FromInt(kProtectorValid); 143 return fast_iteration_cell->value() == Smi::FromInt(kProtectorValid);
149 } 144 }
150 145
151 bool Isolate::IsArrayBufferNeuteringIntact() { 146 bool Isolate::IsArrayBufferNeuteringIntact() {
152 PropertyCell* buffer_neutering = heap()->array_buffer_neutering_protector(); 147 PropertyCell* buffer_neutering = heap()->array_buffer_neutering_protector();
153 return buffer_neutering->value() == Smi::FromInt(kProtectorValid); 148 return buffer_neutering->value() == Smi::FromInt(kProtectorValid);
154 } 149 }
155 150
156 bool Isolate::IsArrayIteratorLookupChainIntact() { 151 bool Isolate::IsArrayIteratorLookupChainIntact() {
157 PropertyCell* array_iterator_cell = heap()->array_iterator_protector(); 152 PropertyCell* array_iterator_cell = heap()->array_iterator_protector();
158 return array_iterator_cell->value() == Smi::FromInt(kProtectorValid); 153 return array_iterator_cell->value() == Smi::FromInt(kProtectorValid);
159 } 154 }
160 155
161 } // namespace internal 156 } // namespace internal
162 } // namespace v8 157 } // namespace v8
163 158
164 #endif // V8_ISOLATE_INL_H_ 159 #endif // V8_ISOLATE_INL_H_
OLDNEW
« no previous file with comments | « src/isolate.h ('k') | test/mjsunit/regress/regress-6391.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698