| 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 8385 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8396 | 8396 |
| 8397 class PolymorphicCodeCache: public Struct { | 8397 class PolymorphicCodeCache: public Struct { |
| 8398 public: | 8398 public: |
| 8399 DECL_ACCESSORS(cache, Object) | 8399 DECL_ACCESSORS(cache, Object) |
| 8400 | 8400 |
| 8401 static void Update(Handle<PolymorphicCodeCache> cache, | 8401 static void Update(Handle<PolymorphicCodeCache> cache, |
| 8402 MapHandleList* maps, | 8402 MapHandleList* maps, |
| 8403 Code::Flags flags, | 8403 Code::Flags flags, |
| 8404 Handle<Code> code); | 8404 Handle<Code> code); |
| 8405 | 8405 |
| 8406 MUST_USE_RESULT MaybeObject* Update(MapHandleList* maps, | |
| 8407 Code::Flags flags, | |
| 8408 Code* code); | |
| 8409 | 8406 |
| 8410 // Returns an undefined value if the entry is not found. | 8407 // Returns an undefined value if the entry is not found. |
| 8411 Handle<Object> Lookup(MapHandleList* maps, Code::Flags flags); | 8408 Handle<Object> Lookup(MapHandleList* maps, Code::Flags flags); |
| 8412 | 8409 |
| 8413 static inline PolymorphicCodeCache* cast(Object* obj); | 8410 static inline PolymorphicCodeCache* cast(Object* obj); |
| 8414 | 8411 |
| 8415 // Dispatched behavior. | 8412 // Dispatched behavior. |
| 8416 DECLARE_PRINTER(PolymorphicCodeCache) | 8413 DECLARE_PRINTER(PolymorphicCodeCache) |
| 8417 DECLARE_VERIFIER(PolymorphicCodeCache) | 8414 DECLARE_VERIFIER(PolymorphicCodeCache) |
| 8418 | 8415 |
| 8419 static const int kCacheOffset = HeapObject::kHeaderSize; | 8416 static const int kCacheOffset = HeapObject::kHeaderSize; |
| 8420 static const int kSize = kCacheOffset + kPointerSize; | 8417 static const int kSize = kCacheOffset + kPointerSize; |
| 8421 | 8418 |
| 8422 private: | 8419 private: |
| 8423 DISALLOW_IMPLICIT_CONSTRUCTORS(PolymorphicCodeCache); | 8420 DISALLOW_IMPLICIT_CONSTRUCTORS(PolymorphicCodeCache); |
| 8424 }; | 8421 }; |
| 8425 | 8422 |
| 8426 | 8423 |
| 8427 class PolymorphicCodeCacheHashTable | 8424 class PolymorphicCodeCacheHashTable |
| 8428 : public HashTable<PolymorphicCodeCacheHashTable, | 8425 : public HashTable<PolymorphicCodeCacheHashTable, |
| 8429 CodeCacheHashTableShape, | 8426 CodeCacheHashTableShape, |
| 8430 HashTableKey*> { | 8427 HashTableKey*> { |
| 8431 public: | 8428 public: |
| 8432 Object* Lookup(MapHandleList* maps, int code_kind); | 8429 Object* Lookup(MapHandleList* maps, int code_kind); |
| 8433 | 8430 |
| 8434 MUST_USE_RESULT MaybeObject* Put(MapHandleList* maps, | 8431 static Handle<PolymorphicCodeCacheHashTable> Put( |
| 8435 int code_kind, | 8432 Handle<PolymorphicCodeCacheHashTable> hash_table, |
| 8436 Code* code); | 8433 MapHandleList* maps, |
| 8434 int code_kind, |
| 8435 Handle<Code> code); |
| 8437 | 8436 |
| 8438 static inline PolymorphicCodeCacheHashTable* cast(Object* obj); | 8437 static inline PolymorphicCodeCacheHashTable* cast(Object* obj); |
| 8439 | 8438 |
| 8440 static const int kInitialSize = 64; | 8439 static const int kInitialSize = 64; |
| 8441 private: | 8440 private: |
| 8442 DISALLOW_IMPLICIT_CONSTRUCTORS(PolymorphicCodeCacheHashTable); | 8441 DISALLOW_IMPLICIT_CONSTRUCTORS(PolymorphicCodeCacheHashTable); |
| 8443 }; | 8442 }; |
| 8444 | 8443 |
| 8445 | 8444 |
| 8446 class TypeFeedbackInfo: public Struct { | 8445 class TypeFeedbackInfo: public Struct { |
| (...skipping 2653 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 11100 } else { | 11099 } else { |
| 11101 value &= ~(1 << bit_position); | 11100 value &= ~(1 << bit_position); |
| 11102 } | 11101 } |
| 11103 return value; | 11102 return value; |
| 11104 } | 11103 } |
| 11105 }; | 11104 }; |
| 11106 | 11105 |
| 11107 } } // namespace v8::internal | 11106 } } // namespace v8::internal |
| 11108 | 11107 |
| 11109 #endif // V8_OBJECTS_H_ | 11108 #endif // V8_OBJECTS_H_ |
| OLD | NEW |