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

Side by Side Diff: src/objects.h

Issue 2484003002: [builtins] implement JSBuiltinReducer for ArrayIteratorNext() (Closed)
Patch Set: fix tests when ignition is used Created 4 years, 1 month 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-inl.h ('k') | src/objects.cc » ('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_OBJECTS_H_ 5 #ifndef V8_OBJECTS_H_
6 #define V8_OBJECTS_H_ 6 #define V8_OBJECTS_H_
7 7
8 #include <iosfwd> 8 #include <iosfwd>
9 #include <memory> 9 #include <memory>
10 10
(...skipping 7261 matching lines...) Expand 10 before | Expand all | Expand 10 after
7272 #define DECLARE_FUNCTION_ID(ignored1, ignore2, name) \ 7272 #define DECLARE_FUNCTION_ID(ignored1, ignore2, name) \
7273 k##name, 7273 k##name,
7274 FUNCTIONS_WITH_ID_LIST(DECLARE_FUNCTION_ID) 7274 FUNCTIONS_WITH_ID_LIST(DECLARE_FUNCTION_ID)
7275 ATOMIC_FUNCTIONS_WITH_ID_LIST(DECLARE_FUNCTION_ID) 7275 ATOMIC_FUNCTIONS_WITH_ID_LIST(DECLARE_FUNCTION_ID)
7276 #undef DECLARE_FUNCTION_ID 7276 #undef DECLARE_FUNCTION_ID
7277 // Fake id for a special case of Math.pow. Note, it continues the 7277 // Fake id for a special case of Math.pow. Note, it continues the
7278 // list of math functions. 7278 // list of math functions.
7279 kMathPowHalf, 7279 kMathPowHalf,
7280 // These are manually assigned to special getters during bootstrapping. 7280 // These are manually assigned to special getters during bootstrapping.
7281 kArrayBufferByteLength, 7281 kArrayBufferByteLength,
7282 kArrayEntries,
7283 kArrayKeys,
7284 kArrayValues,
7285 kArrayIteratorNext,
7282 kDataViewBuffer, 7286 kDataViewBuffer,
7283 kDataViewByteLength, 7287 kDataViewByteLength,
7284 kDataViewByteOffset, 7288 kDataViewByteOffset,
7285 kGlobalDecodeURI, 7289 kGlobalDecodeURI,
7286 kGlobalDecodeURIComponent, 7290 kGlobalDecodeURIComponent,
7287 kGlobalEncodeURI, 7291 kGlobalEncodeURI,
7288 kGlobalEncodeURIComponent, 7292 kGlobalEncodeURIComponent,
7289 kGlobalEscape, 7293 kGlobalEscape,
7290 kGlobalUnescape, 7294 kGlobalUnescape,
7291 kGlobalIsFinite, 7295 kGlobalIsFinite,
7292 kGlobalIsNaN, 7296 kGlobalIsNaN,
7293 kTypedArrayByteLength, 7297 kTypedArrayByteLength,
7294 kTypedArrayByteOffset, 7298 kTypedArrayByteOffset,
7299 kTypedArrayEntries,
7300 kTypedArrayKeys,
7295 kTypedArrayLength, 7301 kTypedArrayLength,
7302 kTypedArrayValues,
7296 kSharedArrayBufferByteLength, 7303 kSharedArrayBufferByteLength,
7297 kStringIterator, 7304 kStringIterator,
7298 kStringIteratorNext, 7305 kStringIteratorNext,
7299 }; 7306 };
7300 7307
7301 7308
7302 // Result of searching in an optimized code map of a SharedFunctionInfo. Note 7309 // Result of searching in an optimized code map of a SharedFunctionInfo. Note
7303 // that both {code} and {literals} can be NULL to pass search result status. 7310 // that both {code} and {literals} can be NULL to pass search result status.
7304 struct CodeAndLiterals { 7311 struct CodeAndLiterals {
7305 Code* code; // Cached optimized code. 7312 Code* code; // Cached optimized code.
(...skipping 3396 matching lines...) Expand 10 before | Expand all | Expand 10 after
10702 // [object]: the [[IteratedObject]] internal field. 10709 // [object]: the [[IteratedObject]] internal field.
10703 DECL_ACCESSORS(object, Object) 10710 DECL_ACCESSORS(object, Object)
10704 10711
10705 // [index]: The [[ArrayIteratorNextIndex]] internal field. 10712 // [index]: The [[ArrayIteratorNextIndex]] internal field.
10706 DECL_ACCESSORS(index, Object) 10713 DECL_ACCESSORS(index, Object)
10707 10714
10708 // [map]: The Map of the [[IteratedObject]] field at the time the iterator is 10715 // [map]: The Map of the [[IteratedObject]] field at the time the iterator is
10709 // allocated. 10716 // allocated.
10710 DECL_ACCESSORS(object_map, Object) 10717 DECL_ACCESSORS(object_map, Object)
10711 10718
10719 // Return the ElementsKind that a JSArrayIterator's [[IteratedObject]] is
10720 // expected to have, based on its instance type.
10721 static ElementsKind ElementsKindForInstanceType(InstanceType instance_type);
10722
10712 static const int kIteratedObjectOffset = JSObject::kHeaderSize; 10723 static const int kIteratedObjectOffset = JSObject::kHeaderSize;
10713 static const int kNextIndexOffset = kIteratedObjectOffset + kPointerSize; 10724 static const int kNextIndexOffset = kIteratedObjectOffset + kPointerSize;
10714 static const int kIteratedObjectMapOffset = kNextIndexOffset + kPointerSize; 10725 static const int kIteratedObjectMapOffset = kNextIndexOffset + kPointerSize;
10715 static const int kSize = kIteratedObjectMapOffset + kPointerSize; 10726 static const int kSize = kIteratedObjectMapOffset + kPointerSize;
10716 10727
10717 private: 10728 private:
10718 DISALLOW_IMPLICIT_CONSTRUCTORS(JSArrayIterator); 10729 DISALLOW_IMPLICIT_CONSTRUCTORS(JSArrayIterator);
10719 }; 10730 };
10720 10731
10721 class JSStringIterator : public JSObject { 10732 class JSStringIterator : public JSObject {
(...skipping 1101 matching lines...) Expand 10 before | Expand all | Expand 10 after
11823 } 11834 }
11824 return value; 11835 return value;
11825 } 11836 }
11826 }; 11837 };
11827 11838
11828 11839
11829 } // NOLINT, false-positive due to second-order macros. 11840 } // NOLINT, false-positive due to second-order macros.
11830 } // NOLINT, false-positive due to second-order macros. 11841 } // NOLINT, false-positive due to second-order macros.
11831 11842
11832 #endif // V8_OBJECTS_H_ 11843 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/isolate-inl.h ('k') | src/objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698