OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 4108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4119 if (IsDeadCheck("v8::V8::SetFailedAccessCheckCallbackFunction()")) return; | 4119 if (IsDeadCheck("v8::V8::SetFailedAccessCheckCallbackFunction()")) return; |
4120 i::Top::SetFailedAccessCheckCallback(callback); | 4120 i::Top::SetFailedAccessCheckCallback(callback); |
4121 } | 4121 } |
4122 | 4122 |
4123 | 4123 |
4124 void V8::AddObjectGroup(Persistent<Value>* objects, | 4124 void V8::AddObjectGroup(Persistent<Value>* objects, |
4125 size_t length, | 4125 size_t length, |
4126 RetainedObjectInfo* info) { | 4126 RetainedObjectInfo* info) { |
4127 if (IsDeadCheck("v8::V8::AddObjectGroup()")) return; | 4127 if (IsDeadCheck("v8::V8::AddObjectGroup()")) return; |
4128 STATIC_ASSERT(sizeof(Persistent<Value>) == sizeof(i::Object**)); | 4128 STATIC_ASSERT(sizeof(Persistent<Value>) == sizeof(i::Object**)); |
4129 i::GlobalHandles::AddGroup( | 4129 i::GlobalHandles::AddObjectGroup( |
4130 reinterpret_cast<i::Object***>(objects), length, info); | 4130 reinterpret_cast<i::Object***>(objects), length, info); |
4131 } | 4131 } |
4132 | 4132 |
4133 | 4133 |
| 4134 void V8::AddImplicitRefGroup(Persistent<Object> parent, |
| 4135 Persistent<Value>* children, |
| 4136 size_t length) { |
| 4137 if (IsDeadCheck("v8::V8::AddImplicitRefGroup()")) return; |
| 4138 STATIC_ASSERT(sizeof(Persistent<Value>) == sizeof(i::Object**)); |
| 4139 i::GlobalHandles::AddImplicitRefGroup( |
| 4140 *Utils::OpenHandle(*parent), |
| 4141 reinterpret_cast<i::Object***>(children), length); |
| 4142 } |
| 4143 |
| 4144 |
4134 int V8::AdjustAmountOfExternalAllocatedMemory(int change_in_bytes) { | 4145 int V8::AdjustAmountOfExternalAllocatedMemory(int change_in_bytes) { |
4135 if (IsDeadCheck("v8::V8::AdjustAmountOfExternalAllocatedMemory()")) return 0; | 4146 if (IsDeadCheck("v8::V8::AdjustAmountOfExternalAllocatedMemory()")) return 0; |
4136 return i::Heap::AdjustAmountOfExternalAllocatedMemory(change_in_bytes); | 4147 return i::Heap::AdjustAmountOfExternalAllocatedMemory(change_in_bytes); |
4137 } | 4148 } |
4138 | 4149 |
4139 | 4150 |
4140 void V8::SetGlobalGCPrologueCallback(GCCallback callback) { | 4151 void V8::SetGlobalGCPrologueCallback(GCCallback callback) { |
4141 if (IsDeadCheck("v8::V8::SetGlobalGCPrologueCallback()")) return; | 4152 if (IsDeadCheck("v8::V8::SetGlobalGCPrologueCallback()")) return; |
4142 i::Heap::SetGlobalGCPrologueCallback(callback); | 4153 i::Heap::SetGlobalGCPrologueCallback(callback); |
4143 } | 4154 } |
(...skipping 1080 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5224 | 5235 |
5225 | 5236 |
5226 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) { | 5237 char* HandleScopeImplementer::Iterate(ObjectVisitor* v, char* storage) { |
5227 HandleScopeImplementer* thread_local = | 5238 HandleScopeImplementer* thread_local = |
5228 reinterpret_cast<HandleScopeImplementer*>(storage); | 5239 reinterpret_cast<HandleScopeImplementer*>(storage); |
5229 thread_local->IterateThis(v); | 5240 thread_local->IterateThis(v); |
5230 return storage + ArchiveSpacePerThread(); | 5241 return storage + ArchiveSpacePerThread(); |
5231 } | 5242 } |
5232 | 5243 |
5233 } } // namespace v8::internal | 5244 } } // namespace v8::internal |
OLD | NEW |