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

Side by Side Diff: src/objects.h

Issue 8345038: Handlify the runtime lookup of CallIC and KeyedCallIC. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 2 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 895 matching lines...) Expand 10 before | Expand all | Expand 10 after
906 // Property access. 906 // Property access.
907 MUST_USE_RESULT inline MaybeObject* GetProperty(String* key); 907 MUST_USE_RESULT inline MaybeObject* GetProperty(String* key);
908 MUST_USE_RESULT inline MaybeObject* GetProperty( 908 MUST_USE_RESULT inline MaybeObject* GetProperty(
909 String* key, 909 String* key,
910 PropertyAttributes* attributes); 910 PropertyAttributes* attributes);
911 MUST_USE_RESULT MaybeObject* GetPropertyWithReceiver( 911 MUST_USE_RESULT MaybeObject* GetPropertyWithReceiver(
912 Object* receiver, 912 Object* receiver,
913 String* key, 913 String* key,
914 PropertyAttributes* attributes); 914 PropertyAttributes* attributes);
915 915
916 static Handle<Object> GetProperty(Isolate* isolate, 916 static Handle<Object> GetProperty(Handle<Object> object,
917 Handle<Object> object,
918 Handle<Object> receiver, 917 Handle<Object> receiver,
919 LookupResult* result, 918 LookupResult* result,
920 Handle<String> key, 919 Handle<String> key,
921 PropertyAttributes* attributes); 920 PropertyAttributes* attributes);
922 921
923 MUST_USE_RESULT MaybeObject* GetProperty(Object* receiver, 922 MUST_USE_RESULT MaybeObject* GetProperty(Object* receiver,
924 LookupResult* result, 923 LookupResult* result,
925 String* key, 924 String* key,
926 PropertyAttributes* attributes); 925 PropertyAttributes* attributes);
927 926
928 MUST_USE_RESULT MaybeObject* GetPropertyWithDefinedGetter(Object* receiver, 927 MUST_USE_RESULT MaybeObject* GetPropertyWithDefinedGetter(Object* receiver,
929 JSReceiver* getter); 928 JSReceiver* getter);
930 929
930 static Handle<Object> GetElement(Handle<Object> object, uint32_t index);
931 inline MaybeObject* GetElement(uint32_t index); 931 inline MaybeObject* GetElement(uint32_t index);
932 // For use when we know that no exception can be thrown. 932 // For use when we know that no exception can be thrown.
933 inline Object* GetElementNoExceptionThrown(uint32_t index); 933 inline Object* GetElementNoExceptionThrown(uint32_t index);
934 MaybeObject* GetElementWithReceiver(Object* receiver, uint32_t index); 934 MaybeObject* GetElementWithReceiver(Object* receiver, uint32_t index);
935 935
936 // Return the object's prototype (might be Heap::null_value()). 936 // Return the object's prototype (might be Heap::null_value()).
937 Object* GetPrototype(); 937 Object* GetPrototype();
938 938
939 // Tries to convert an object to an array index. Returns true and sets 939 // Tries to convert an object to an array index. Returns true and sets
940 // the output parameter if it succeeds. 940 // the output parameter if it succeeds.
(...skipping 3966 matching lines...) Expand 10 before | Expand all | Expand 10 after
4907 #ifdef OBJECT_PRINT 4907 #ifdef OBJECT_PRINT
4908 inline void SharedFunctionInfoPrint() { 4908 inline void SharedFunctionInfoPrint() {
4909 SharedFunctionInfoPrint(stdout); 4909 SharedFunctionInfoPrint(stdout);
4910 } 4910 }
4911 void SharedFunctionInfoPrint(FILE* out); 4911 void SharedFunctionInfoPrint(FILE* out);
4912 #endif 4912 #endif
4913 #ifdef DEBUG 4913 #ifdef DEBUG
4914 void SharedFunctionInfoVerify(); 4914 void SharedFunctionInfoVerify();
4915 #endif 4915 #endif
4916 4916
4917 // Helpers to compile the shared code. Returns true on success, false on
4918 // failure (e.g., stack overflow during compilation).
4919 static bool EnsureCompiled(Handle<SharedFunctionInfo> shared,
4920 ClearExceptionFlag flag);
4921 static bool CompileLazy(Handle<SharedFunctionInfo> shared,
4922 ClearExceptionFlag flag);
4923
4917 // Casting. 4924 // Casting.
4918 static inline SharedFunctionInfo* cast(Object* obj); 4925 static inline SharedFunctionInfo* cast(Object* obj);
4919 4926
4920 // Constants. 4927 // Constants.
4921 static const int kDontAdaptArgumentsSentinel = -1; 4928 static const int kDontAdaptArgumentsSentinel = -1;
4922 4929
4923 // Layout description. 4930 // Layout description.
4924 // Pointer fields. 4931 // Pointer fields.
4925 static const int kNameOffset = HeapObject::kHeaderSize; 4932 static const int kNameOffset = HeapObject::kHeaderSize;
4926 static const int kCodeOffset = kNameOffset + kPointerSize; 4933 static const int kCodeOffset = kNameOffset + kPointerSize;
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
5128 // Tells whether or not this function has been optimized. 5135 // Tells whether or not this function has been optimized.
5129 inline bool IsOptimized(); 5136 inline bool IsOptimized();
5130 5137
5131 // Tells whether or not this function can be optimized. 5138 // Tells whether or not this function can be optimized.
5132 inline bool IsOptimizable(); 5139 inline bool IsOptimizable();
5133 5140
5134 // Mark this function for lazy recompilation. The function will be 5141 // Mark this function for lazy recompilation. The function will be
5135 // recompiled the next time it is executed. 5142 // recompiled the next time it is executed.
5136 void MarkForLazyRecompilation(); 5143 void MarkForLazyRecompilation();
5137 5144
5145 // Helpers to compile this function. Returns true on success, false on
5146 // failure (e.g., stack overflow during compilation).
5147 static bool CompileLazy(Handle<JSFunction> function,
5148 ClearExceptionFlag flag);
5149 static bool CompileOptimized(Handle<JSFunction> function,
5150 int osr_ast_id,
5151 ClearExceptionFlag flag);
5152
5138 // Tells whether or not the function is already marked for lazy 5153 // Tells whether or not the function is already marked for lazy
5139 // recompilation. 5154 // recompilation.
5140 inline bool IsMarkedForLazyRecompilation(); 5155 inline bool IsMarkedForLazyRecompilation();
5141 5156
5142 // Check whether or not this function is inlineable. 5157 // Check whether or not this function is inlineable.
5143 bool IsInlineable(); 5158 bool IsInlineable();
5144 5159
5145 // [literals_or_bindings]: Fixed array holding either 5160 // [literals_or_bindings]: Fixed array holding either
5146 // the materialized literals or the bindings of a bound function. 5161 // the materialized literals or the bindings of a bound function.
5147 // 5162 //
(...skipping 2484 matching lines...) Expand 10 before | Expand all | Expand 10 after
7632 } else { 7647 } else {
7633 value &= ~(1 << bit_position); 7648 value &= ~(1 << bit_position);
7634 } 7649 }
7635 return value; 7650 return value;
7636 } 7651 }
7637 }; 7652 };
7638 7653
7639 } } // namespace v8::internal 7654 } } // namespace v8::internal
7640 7655
7641 #endif // V8_OBJECTS_H_ 7656 #endif // V8_OBJECTS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698