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

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

Issue 2002203002: [api] Add more parameters to Object::GetPropertyNames (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@2016-05-06_keys_fast_path_1995263002
Patch Set: addressing nits Created 4 years, 6 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/objects.cc ('k') | src/runtime/runtime-array.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 // Review notes: 5 // Review notes:
6 // 6 //
7 // - The use of macros in these inline functions may seem superfluous 7 // - The use of macros in these inline functions may seem superfluous
8 // but it is absolutely needed to make sure gcc generates optimal 8 // but it is absolutely needed to make sure gcc generates optimal
9 // code. gcc is not happy when attempting to inline too deep. 9 // code. gcc is not happy when attempting to inline too deep.
10 // 10 //
(...skipping 1096 matching lines...) Expand 10 before | Expand all | Expand 10 after
1107 MaybeHandle<Object> JSReceiver::GetProperty(Isolate* isolate, 1107 MaybeHandle<Object> JSReceiver::GetProperty(Isolate* isolate,
1108 Handle<JSReceiver> receiver, 1108 Handle<JSReceiver> receiver,
1109 const char* name) { 1109 const char* name) {
1110 Handle<String> str = isolate->factory()->InternalizeUtf8String(name); 1110 Handle<String> str = isolate->factory()->InternalizeUtf8String(name);
1111 return GetProperty(receiver, str); 1111 return GetProperty(receiver, str);
1112 } 1112 }
1113 1113
1114 // static 1114 // static
1115 MUST_USE_RESULT MaybeHandle<FixedArray> JSReceiver::OwnPropertyKeys( 1115 MUST_USE_RESULT MaybeHandle<FixedArray> JSReceiver::OwnPropertyKeys(
1116 Handle<JSReceiver> object) { 1116 Handle<JSReceiver> object) {
1117 return KeyAccumulator::GetKeys(object, OWN_ONLY, ALL_PROPERTIES, 1117 return KeyAccumulator::GetKeys(object, KeyCollectionMode::kOwnOnly,
1118 CONVERT_TO_STRING); 1118 ALL_PROPERTIES,
1119 GetKeysConversion::kConvertToString);
1119 } 1120 }
1120 1121
1121 #define FIELD_ADDR(p, offset) \ 1122 #define FIELD_ADDR(p, offset) \
1122 (reinterpret_cast<byte*>(p) + offset - kHeapObjectTag) 1123 (reinterpret_cast<byte*>(p) + offset - kHeapObjectTag)
1123 1124
1124 #define FIELD_ADDR_CONST(p, offset) \ 1125 #define FIELD_ADDR_CONST(p, offset) \
1125 (reinterpret_cast<const byte*>(p) + offset - kHeapObjectTag) 1126 (reinterpret_cast<const byte*>(p) + offset - kHeapObjectTag)
1126 1127
1127 #define READ_FIELD(p, offset) \ 1128 #define READ_FIELD(p, offset) \
1128 (*reinterpret_cast<Object* const*>(FIELD_ADDR_CONST(p, offset))) 1129 (*reinterpret_cast<Object* const*>(FIELD_ADDR_CONST(p, offset)))
(...skipping 6717 matching lines...) Expand 10 before | Expand all | Expand 10 after
7846 #undef WRITE_INT64_FIELD 7847 #undef WRITE_INT64_FIELD
7847 #undef READ_BYTE_FIELD 7848 #undef READ_BYTE_FIELD
7848 #undef WRITE_BYTE_FIELD 7849 #undef WRITE_BYTE_FIELD
7849 #undef NOBARRIER_READ_BYTE_FIELD 7850 #undef NOBARRIER_READ_BYTE_FIELD
7850 #undef NOBARRIER_WRITE_BYTE_FIELD 7851 #undef NOBARRIER_WRITE_BYTE_FIELD
7851 7852
7852 } // namespace internal 7853 } // namespace internal
7853 } // namespace v8 7854 } // namespace v8
7854 7855
7855 #endif // V8_OBJECTS_INL_H_ 7856 #endif // V8_OBJECTS_INL_H_
OLDNEW
« no previous file with comments | « src/objects.cc ('k') | src/runtime/runtime-array.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698