| 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 359 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 370 } | 370 } |
| 371 | 371 |
| 372 // This returns the address of an object that has been described in the | 372 // This returns the address of an object that has been described in the |
| 373 // snapshot as being offset bytes back in a particular space. | 373 // snapshot as being offset bytes back in a particular space. |
| 374 HeapObject* GetAddressFromEnd(int space) { | 374 HeapObject* GetAddressFromEnd(int space) { |
| 375 int offset = source_->GetInt(); | 375 int offset = source_->GetInt(); |
| 376 offset <<= kObjectAlignmentBits; | 376 offset <<= kObjectAlignmentBits; |
| 377 return HeapObject::FromAddress(high_water_[space] - offset); | 377 return HeapObject::FromAddress(high_water_[space] - offset); |
| 378 } | 378 } |
| 379 | 379 |
| 380 void FlushICacheForNewCodeObjects(); |
| 380 | 381 |
| 381 // Cached current isolate. | 382 // Cached current isolate. |
| 382 Isolate* isolate_; | 383 Isolate* isolate_; |
| 383 | 384 |
| 384 SnapshotByteSource* source_; | 385 SnapshotByteSource* source_; |
| 385 // This is the address of the next object that will be allocated in each | 386 // This is the address of the next object that will be allocated in each |
| 386 // space. It is used to calculate the addresses of back-references. | 387 // space. It is used to calculate the addresses of back-references. |
| 387 Address high_water_[LAST_SPACE + 1]; | 388 Address high_water_[LAST_SPACE + 1]; |
| 388 | 389 |
| 389 int reservations_[LAST_SPACE + 1]; | 390 int reservations_[LAST_SPACE + 1]; |
| (...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 663 private: | 664 private: |
| 664 virtual bool ShouldBeInThePartialSnapshotCache(HeapObject* o) { | 665 virtual bool ShouldBeInThePartialSnapshotCache(HeapObject* o) { |
| 665 return false; | 666 return false; |
| 666 } | 667 } |
| 667 }; | 668 }; |
| 668 | 669 |
| 669 | 670 |
| 670 } } // namespace v8::internal | 671 } } // namespace v8::internal |
| 671 | 672 |
| 672 #endif // V8_SERIALIZE_H_ | 673 #endif // V8_SERIALIZE_H_ |
| OLD | NEW |