OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 4543 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4554 void InvalidateRelocation(); | 4554 void InvalidateRelocation(); |
4555 | 4555 |
4556 // [handler_table]: Fixed array containing offsets of exception handlers. | 4556 // [handler_table]: Fixed array containing offsets of exception handlers. |
4557 DECL_ACCESSORS(handler_table, FixedArray) | 4557 DECL_ACCESSORS(handler_table, FixedArray) |
4558 | 4558 |
4559 // [deoptimization_data]: Array containing data for deopt. | 4559 // [deoptimization_data]: Array containing data for deopt. |
4560 DECL_ACCESSORS(deoptimization_data, FixedArray) | 4560 DECL_ACCESSORS(deoptimization_data, FixedArray) |
4561 | 4561 |
4562 // [type_feedback_info]: Struct containing type feedback information for | 4562 // [type_feedback_info]: Struct containing type feedback information for |
4563 // unoptimized code. Optimized code can temporarily store the head of | 4563 // unoptimized code. Optimized code can temporarily store the head of |
4564 // the list of the dependent optimized functions during deoptimization. | 4564 // the list of code to be deoptimized during mark-compact GC. |
4565 // STUBs can use this slot to store arbitrary information as a Smi. | 4565 // STUBs can use this slot to store arbitrary information as a Smi. |
4566 // Will contain either a TypeFeedbackInfo object, or JSFunction object, | 4566 // Will contain either a TypeFeedbackInfo object, or JSFunction object, |
4567 // or undefined, or a Smi. | 4567 // or undefined, or a Smi. |
4568 DECL_ACCESSORS(type_feedback_info, Object) | 4568 DECL_ACCESSORS(type_feedback_info, Object) |
4569 inline void InitializeTypeFeedbackInfoNoWriteBarrier(Object* value); | 4569 inline void InitializeTypeFeedbackInfoNoWriteBarrier(Object* value); |
4570 inline int stub_info(); | 4570 inline int stub_info(); |
4571 inline void set_stub_info(int info); | 4571 inline void set_stub_info(int info); |
4572 inline Object* deoptimizing_functions(); | 4572 |
4573 inline void set_deoptimizing_functions(Object* value); | 4573 // Used during GC to code a list of code objects to deoptimize. |
| 4574 inline Object* code_to_deoptimize_link(); |
| 4575 inline void set_code_to_deoptimize_link(Object* value); |
| 4576 inline Object** code_to_deoptimize_link_slot(); |
4574 | 4577 |
4575 // [gc_metadata]: Field used to hold GC related metadata. The contents of this | 4578 // [gc_metadata]: Field used to hold GC related metadata. The contents of this |
4576 // field does not have to be traced during garbage collection since | 4579 // field does not have to be traced during garbage collection since |
4577 // it is only used by the garbage collector itself. | 4580 // it is only used by the garbage collector itself. |
4578 DECL_ACCESSORS(gc_metadata, Object) | 4581 DECL_ACCESSORS(gc_metadata, Object) |
4579 | 4582 |
4580 // [ic_age]: Inline caching age: the value of the Heap::global_ic_age | 4583 // [ic_age]: Inline caching age: the value of the Heap::global_ic_age |
4581 // at the moment when this object was created. | 4584 // at the moment when this object was created. |
4582 inline void set_ic_age(int count); | 4585 inline void set_ic_age(int count); |
4583 inline int ic_age(); | 4586 inline int ic_age(); |
(...skipping 2171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6755 // Dispatched behavior. | 6758 // Dispatched behavior. |
6756 DECLARE_PRINTER(JSFunction) | 6759 DECLARE_PRINTER(JSFunction) |
6757 DECLARE_VERIFIER(JSFunction) | 6760 DECLARE_VERIFIER(JSFunction) |
6758 | 6761 |
6759 // Returns the number of allocated literals. | 6762 // Returns the number of allocated literals. |
6760 inline int NumberOfLiterals(); | 6763 inline int NumberOfLiterals(); |
6761 | 6764 |
6762 // Retrieve the native context from a function's literal array. | 6765 // Retrieve the native context from a function's literal array. |
6763 static Context* NativeContextFromLiterals(FixedArray* literals); | 6766 static Context* NativeContextFromLiterals(FixedArray* literals); |
6764 | 6767 |
6765 #ifdef DEBUG | |
6766 bool FunctionsInFunctionListShareSameCode() { | |
6767 Object* current = this; | |
6768 while (!current->IsUndefined()) { | |
6769 JSFunction* function = JSFunction::cast(current); | |
6770 current = function->next_function_link(); | |
6771 if (function->code() != this->code()) return false; | |
6772 } | |
6773 return true; | |
6774 } | |
6775 #endif | |
6776 | |
6777 bool PassesHydrogenFilter(); | 6768 bool PassesHydrogenFilter(); |
6778 | 6769 |
6779 // Layout descriptors. The last property (from kNonWeakFieldsEndOffset to | 6770 // Layout descriptors. The last property (from kNonWeakFieldsEndOffset to |
6780 // kSize) is weak and has special handling during garbage collection. | 6771 // kSize) is weak and has special handling during garbage collection. |
6781 static const int kCodeEntryOffset = JSObject::kHeaderSize; | 6772 static const int kCodeEntryOffset = JSObject::kHeaderSize; |
6782 static const int kPrototypeOrInitialMapOffset = | 6773 static const int kPrototypeOrInitialMapOffset = |
6783 kCodeEntryOffset + kPointerSize; | 6774 kCodeEntryOffset + kPointerSize; |
6784 static const int kSharedFunctionInfoOffset = | 6775 static const int kSharedFunctionInfoOffset = |
6785 kPrototypeOrInitialMapOffset + kPointerSize; | 6776 kPrototypeOrInitialMapOffset + kPointerSize; |
6786 static const int kContextOffset = kSharedFunctionInfoOffset + kPointerSize; | 6777 static const int kContextOffset = kSharedFunctionInfoOffset + kPointerSize; |
(...skipping 3091 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
9878 } else { | 9869 } else { |
9879 value &= ~(1 << bit_position); | 9870 value &= ~(1 << bit_position); |
9880 } | 9871 } |
9881 return value; | 9872 return value; |
9882 } | 9873 } |
9883 }; | 9874 }; |
9884 | 9875 |
9885 } } // namespace v8::internal | 9876 } } // namespace v8::internal |
9886 | 9877 |
9887 #endif // V8_OBJECTS_H_ | 9878 #endif // V8_OBJECTS_H_ |
OLD | NEW |