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

Side by Side Diff: src/runtime/runtime.h

Issue 1199983002: [strong] Implement strong property access semantics (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Choose generic path less Created 5 years, 5 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
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 #ifndef V8_RUNTIME_RUNTIME_H_ 5 #ifndef V8_RUNTIME_RUNTIME_H_
6 #define V8_RUNTIME_RUNTIME_H_ 6 #define V8_RUNTIME_RUNTIME_H_
7 7
8 #include "src/allocation.h" 8 #include "src/allocation.h"
9 #include "src/objects.h" 9 #include "src/objects.h"
10 #include "src/zone.h" 10 #include "src/zone.h"
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 F(ThrowUnsupportedSuperError, 0, 1) \ 71 F(ThrowUnsupportedSuperError, 0, 1) \
72 F(ThrowConstructorNonCallableError, 0, 1) \ 72 F(ThrowConstructorNonCallableError, 0, 1) \
73 F(ThrowArrayNotSubclassableError, 0, 1) \ 73 F(ThrowArrayNotSubclassableError, 0, 1) \
74 F(ThrowStaticPrototypeError, 0, 1) \ 74 F(ThrowStaticPrototypeError, 0, 1) \
75 F(ThrowIfStaticPrototype, 1, 1) \ 75 F(ThrowIfStaticPrototype, 1, 1) \
76 F(ToMethod, 2, 1) \ 76 F(ToMethod, 2, 1) \
77 F(HomeObjectSymbol, 0, 1) \ 77 F(HomeObjectSymbol, 0, 1) \
78 F(DefineClass, 6, 1) \ 78 F(DefineClass, 6, 1) \
79 F(DefineClassMethod, 3, 1) \ 79 F(DefineClassMethod, 3, 1) \
80 F(ClassGetSourceCode, 1, 1) \ 80 F(ClassGetSourceCode, 1, 1) \
81 F(LoadFromSuper, 3, 1) \ 81 F(LoadFromSuper, 4, 1) \
82 F(LoadKeyedFromSuper, 3, 1) \ 82 F(LoadKeyedFromSuper, 4, 1) \
83 F(StoreToSuper_Strict, 4, 1) \ 83 F(StoreToSuper_Strict, 4, 1) \
84 F(StoreToSuper_Sloppy, 4, 1) \ 84 F(StoreToSuper_Sloppy, 4, 1) \
85 F(StoreKeyedToSuper_Strict, 4, 1) \ 85 F(StoreKeyedToSuper_Strict, 4, 1) \
86 F(StoreKeyedToSuper_Sloppy, 4, 1) \ 86 F(StoreKeyedToSuper_Sloppy, 4, 1) \
87 F(HandleStepInForDerivedConstructors, 1, 1) \ 87 F(HandleStepInForDerivedConstructors, 1, 1) \
88 F(DefaultConstructorCallSuper, 2, 1) \ 88 F(DefaultConstructorCallSuper, 2, 1) \
89 F(CallSuperWithSpread, 1, 1) 89 F(CallSuperWithSpread, 1, 1)
90 90
91 91
92 #define FOR_EACH_INTRINSIC_COLLECTIONS(F) \ 92 #define FOR_EACH_INTRINSIC_COLLECTIONS(F) \
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
293 F(CheckIsBootstrapping, 0, 1) \ 293 F(CheckIsBootstrapping, 0, 1) \
294 F(Throw, 1, 1) \ 294 F(Throw, 1, 1) \
295 F(ReThrow, 1, 1) \ 295 F(ReThrow, 1, 1) \
296 F(UnwindAndFindExceptionHandler, 0, 1) \ 296 F(UnwindAndFindExceptionHandler, 0, 1) \
297 F(PromoteScheduledException, 0, 1) \ 297 F(PromoteScheduledException, 0, 1) \
298 F(ThrowReferenceError, 1, 1) \ 298 F(ThrowReferenceError, 1, 1) \
299 F(NewTypeError, 2, 1) \ 299 F(NewTypeError, 2, 1) \
300 F(NewSyntaxError, 2, 1) \ 300 F(NewSyntaxError, 2, 1) \
301 F(NewReferenceError, 2, 1) \ 301 F(NewReferenceError, 2, 1) \
302 F(ThrowIteratorResultNotAnObject, 1, 1) \ 302 F(ThrowIteratorResultNotAnObject, 1, 1) \
303 F(ThrowStrongModeImplicitConversion, 0, 1) \
303 F(PromiseRejectEvent, 3, 1) \ 304 F(PromiseRejectEvent, 3, 1) \
304 F(PromiseRevokeReject, 1, 1) \ 305 F(PromiseRevokeReject, 1, 1) \
305 F(PromiseHasHandlerSymbol, 0, 1) \ 306 F(PromiseHasHandlerSymbol, 0, 1) \
306 F(StackGuard, 0, 1) \ 307 F(StackGuard, 0, 1) \
307 F(Interrupt, 0, 1) \ 308 F(Interrupt, 0, 1) \
308 F(AllocateInNewSpace, 1, 1) \ 309 F(AllocateInNewSpace, 1, 1) \
309 F(AllocateInTargetSpace, 2, 1) \ 310 F(AllocateInTargetSpace, 2, 1) \
310 F(CollectStackTrace, 2, 1) \ 311 F(CollectStackTrace, 2, 1) \
311 F(RenderCallSite, 0, 1) \ 312 F(RenderCallSite, 0, 1) \
312 F(GetFromCacheRT, 2, 1) \ 313 F(GetFromCacheRT, 2, 1) \
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
428 F(IsInPrototypeChain, 2, 1) \ 429 F(IsInPrototypeChain, 2, 1) \
429 F(GetOwnProperty, 2, 1) \ 430 F(GetOwnProperty, 2, 1) \
430 F(PreventExtensions, 1, 1) \ 431 F(PreventExtensions, 1, 1) \
431 F(IsExtensible, 1, 1) \ 432 F(IsExtensible, 1, 1) \
432 F(DisableAccessChecks, 1, 1) \ 433 F(DisableAccessChecks, 1, 1) \
433 F(EnableAccessChecks, 1, 1) \ 434 F(EnableAccessChecks, 1, 1) \
434 F(OptimizeObjectForAddingMultipleProperties, 2, 1) \ 435 F(OptimizeObjectForAddingMultipleProperties, 2, 1) \
435 F(ObjectFreeze, 1, 1) \ 436 F(ObjectFreeze, 1, 1) \
436 F(ObjectSeal, 1, 1) \ 437 F(ObjectSeal, 1, 1) \
437 F(GetProperty, 2, 1) \ 438 F(GetProperty, 2, 1) \
439 F(GetPropertyStrong, 2, 1) \
438 F(KeyedGetProperty, 2, 1) \ 440 F(KeyedGetProperty, 2, 1) \
441 F(KeyedGetPropertyStrong, 2, 1) \
439 F(AddNamedProperty, 4, 1) \ 442 F(AddNamedProperty, 4, 1) \
440 F(SetProperty, 4, 1) \ 443 F(SetProperty, 4, 1) \
441 F(AddElement, 3, 1) \ 444 F(AddElement, 3, 1) \
442 F(AppendElement, 2, 1) \ 445 F(AppendElement, 2, 1) \
443 F(DeleteProperty, 3, 1) \ 446 F(DeleteProperty, 3, 1) \
444 F(HasOwnProperty, 2, 1) \ 447 F(HasOwnProperty, 2, 1) \
445 F(HasProperty, 2, 1) \ 448 F(HasProperty, 2, 1) \
446 F(HasElement, 2, 1) \ 449 F(HasElement, 2, 1) \
447 F(IsPropertyEnumerable, 2, 1) \ 450 F(IsPropertyEnumerable, 2, 1) \
448 F(GetPropertyNames, 1, 1) \ 451 F(GetPropertyNames, 1, 1) \
(...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after
811 814
812 // Get the intrinsic function with the given function entry address. 815 // Get the intrinsic function with the given function entry address.
813 static const Function* FunctionForEntry(Address ref); 816 static const Function* FunctionForEntry(Address ref);
814 817
815 // TODO(1240886): Some of the following methods are *not* handle safe, but 818 // TODO(1240886): Some of the following methods are *not* handle safe, but
816 // accept handle arguments. This seems fragile. 819 // accept handle arguments. This seems fragile.
817 820
818 // Support getting the characters in a string using [] notation as 821 // Support getting the characters in a string using [] notation as
819 // in Firefox/SpiderMonkey, Safari and Opera. 822 // in Firefox/SpiderMonkey, Safari and Opera.
820 MUST_USE_RESULT static MaybeHandle<Object> GetElementOrCharAt( 823 MUST_USE_RESULT static MaybeHandle<Object> GetElementOrCharAt(
821 Isolate* isolate, Handle<Object> object, uint32_t index); 824 Isolate* isolate, Handle<Object> object, uint32_t index,
825 LanguageMode language_mode = SLOPPY);
822 826
823 MUST_USE_RESULT static MaybeHandle<Object> SetObjectProperty( 827 MUST_USE_RESULT static MaybeHandle<Object> SetObjectProperty(
824 Isolate* isolate, Handle<Object> object, Handle<Object> key, 828 Isolate* isolate, Handle<Object> object, Handle<Object> key,
825 Handle<Object> value, LanguageMode language_mode); 829 Handle<Object> value, LanguageMode language_mode);
826 830
827 MUST_USE_RESULT static MaybeHandle<Object> GetObjectProperty( 831 MUST_USE_RESULT static MaybeHandle<Object> GetObjectProperty(
828 Isolate* isolate, Handle<Object> object, Handle<Object> key); 832 Isolate* isolate, Handle<Object> object, Handle<Object> key,
833 LanguageMode language_mode = SLOPPY);
834
835 MUST_USE_RESULT static MaybeHandle<Object> KeyedGetObjectProperty(
836 Isolate* isolate, Handle<Object> receiver_obj, Handle<Object> key_obj,
837 LanguageMode language_mode);
829 838
830 MUST_USE_RESULT static MaybeHandle<Object> GetPrototype( 839 MUST_USE_RESULT static MaybeHandle<Object> GetPrototype(
831 Isolate* isolate, Handle<Object> object); 840 Isolate* isolate, Handle<Object> object);
832 841
833 MUST_USE_RESULT static MaybeHandle<Name> ToName(Isolate* isolate, 842 MUST_USE_RESULT static MaybeHandle<Name> ToName(Isolate* isolate,
834 Handle<Object> key); 843 Handle<Object> key);
835 844
836 static void SetupArrayBuffer(Isolate* isolate, 845 static void SetupArrayBuffer(Isolate* isolate,
837 Handle<JSArrayBuffer> array_buffer, 846 Handle<JSArrayBuffer> array_buffer,
838 bool is_external, void* data, 847 bool is_external, void* data,
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
929 inline bool Runtime::AtomicIsLockFree(uint32_t size) { 938 inline bool Runtime::AtomicIsLockFree(uint32_t size) {
930 return size == 1 || size == 2 || size == 4; 939 return size == 1 || size == 2 || size == 4;
931 } 940 }
932 941
933 #endif 942 #endif
934 943
935 } // namespace internal 944 } // namespace internal
936 } // namespace v8 945 } // namespace v8
937 946
938 #endif // V8_RUNTIME_RUNTIME_H_ 947 #endif // V8_RUNTIME_RUNTIME_H_
OLDNEW
« src/objects.cc ('K') | « src/runtime.js ('k') | src/runtime/runtime-classes.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698