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 7240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7251 DECL_ACCESSORS(prototype_or_initial_map, Object) | 7251 DECL_ACCESSORS(prototype_or_initial_map, Object) |
7252 | 7252 |
7253 // [shared]: The information about the function that | 7253 // [shared]: The information about the function that |
7254 // can be shared by instances. | 7254 // can be shared by instances. |
7255 DECL_ACCESSORS(shared, SharedFunctionInfo) | 7255 DECL_ACCESSORS(shared, SharedFunctionInfo) |
7256 | 7256 |
7257 // [context]: The context for this function. | 7257 // [context]: The context for this function. |
7258 inline Context* context(); | 7258 inline Context* context(); |
7259 inline void set_context(Object* context); | 7259 inline void set_context(Object* context); |
7260 | 7260 |
| 7261 // [constant_pool]: The constant pool for this function. |
| 7262 inline ConstantPoolArray* constant_pool(); |
| 7263 inline void set_constant_pool(Object* context); |
| 7264 |
7261 // [code]: The generated code object for this function. Executed | 7265 // [code]: The generated code object for this function. Executed |
7262 // when the function is invoked, e.g. foo() or new foo(). See | 7266 // when the function is invoked, e.g. foo() or new foo(). See |
7263 // [[Call]] and [[Construct]] description in ECMA-262, section | 7267 // [[Call]] and [[Construct]] description in ECMA-262, section |
7264 // 8.6.2, page 27. | 7268 // 8.6.2, page 27. |
7265 inline Code* code(); | 7269 inline Code* code(); |
7266 inline void set_code(Code* code); | 7270 inline void set_code(Code* code); |
7267 inline void set_code_no_write_barrier(Code* code); | 7271 inline void set_code_no_write_barrier(Code* code); |
7268 inline void ReplaceCode(Code* code); | 7272 inline void ReplaceCode(Code* code); |
7269 | 7273 |
7270 // Tells whether this function is builtin. | 7274 // Tells whether this function is builtin. |
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7395 bool PassesFilter(const char* raw_filter); | 7399 bool PassesFilter(const char* raw_filter); |
7396 | 7400 |
7397 // Layout descriptors. The last property (from kNonWeakFieldsEndOffset to | 7401 // Layout descriptors. The last property (from kNonWeakFieldsEndOffset to |
7398 // kSize) is weak and has special handling during garbage collection. | 7402 // kSize) is weak and has special handling during garbage collection. |
7399 static const int kCodeEntryOffset = JSObject::kHeaderSize; | 7403 static const int kCodeEntryOffset = JSObject::kHeaderSize; |
7400 static const int kPrototypeOrInitialMapOffset = | 7404 static const int kPrototypeOrInitialMapOffset = |
7401 kCodeEntryOffset + kPointerSize; | 7405 kCodeEntryOffset + kPointerSize; |
7402 static const int kSharedFunctionInfoOffset = | 7406 static const int kSharedFunctionInfoOffset = |
7403 kPrototypeOrInitialMapOffset + kPointerSize; | 7407 kPrototypeOrInitialMapOffset + kPointerSize; |
7404 static const int kContextOffset = kSharedFunctionInfoOffset + kPointerSize; | 7408 static const int kContextOffset = kSharedFunctionInfoOffset + kPointerSize; |
7405 static const int kLiteralsOffset = kContextOffset + kPointerSize; | 7409 static const int kConstantPoolOffset = kContextOffset + kPointerSize; |
| 7410 static const int kLiteralsOffset = kConstantPoolOffset + kPointerSize; |
7406 static const int kNonWeakFieldsEndOffset = kLiteralsOffset + kPointerSize; | 7411 static const int kNonWeakFieldsEndOffset = kLiteralsOffset + kPointerSize; |
7407 static const int kNextFunctionLinkOffset = kNonWeakFieldsEndOffset; | 7412 static const int kNextFunctionLinkOffset = kNonWeakFieldsEndOffset; |
7408 static const int kSize = kNextFunctionLinkOffset + kPointerSize; | 7413 static const int kSize = kNextFunctionLinkOffset + kPointerSize; |
7409 | 7414 |
7410 // Layout of the literals array. | 7415 // Layout of the literals array. |
7411 static const int kLiteralsPrefixSize = 1; | 7416 static const int kLiteralsPrefixSize = 1; |
7412 static const int kLiteralNativeContextIndex = 0; | 7417 static const int kLiteralNativeContextIndex = 0; |
7413 | 7418 |
7414 // Layout of the bound-function binding array. | 7419 // Layout of the bound-function binding array. |
7415 static const int kBoundFunctionIndex = 0; | 7420 static const int kBoundFunctionIndex = 0; |
(...skipping 3179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10595 } else { | 10600 } else { |
10596 value &= ~(1 << bit_position); | 10601 value &= ~(1 << bit_position); |
10597 } | 10602 } |
10598 return value; | 10603 return value; |
10599 } | 10604 } |
10600 }; | 10605 }; |
10601 | 10606 |
10602 } } // namespace v8::internal | 10607 } } // namespace v8::internal |
10603 | 10608 |
10604 #endif // V8_OBJECTS_H_ | 10609 #endif // V8_OBJECTS_H_ |
OLD | NEW |