OLD | NEW |
1 // Copyright 2007-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2007-2008 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 2610 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2621 } | 2621 } |
2622 | 2622 |
2623 | 2623 |
2624 void V8::SetFailedAccessCheckCallbackFunction( | 2624 void V8::SetFailedAccessCheckCallbackFunction( |
2625 FailedAccessCheckCallback callback) { | 2625 FailedAccessCheckCallback callback) { |
2626 if (IsDeadCheck("v8::V8::SetFailedAccessCheckCallbackFunction()")) return; | 2626 if (IsDeadCheck("v8::V8::SetFailedAccessCheckCallbackFunction()")) return; |
2627 i::Top::SetFailedAccessCheckCallback(callback); | 2627 i::Top::SetFailedAccessCheckCallback(callback); |
2628 } | 2628 } |
2629 | 2629 |
2630 | 2630 |
2631 void V8::AddObjectToGroup(void* group_id, Persistent<Object> obj) { | 2631 void V8::AddObjectGroup(Persistent<Value>* objects, size_t length) { |
2632 if (IsDeadCheck("v8::V8::AddObjectToGroup()")) return; | 2632 if (IsDeadCheck("v8::V8::AddObjectGroup()")) return; |
2633 i::GlobalHandles::AddToGroup(group_id, reinterpret_cast<i::Object**>(*obj)); | 2633 STATIC_ASSERT(sizeof(Persistent<Value>) == sizeof(i::Object**)); |
| 2634 i::GlobalHandles::AddGroup(reinterpret_cast<i::Object***>(objects), length); |
2634 } | 2635 } |
2635 | 2636 |
2636 | 2637 |
2637 int V8::AdjustAmountOfExternalAllocatedMemory(int change_in_bytes) { | 2638 int V8::AdjustAmountOfExternalAllocatedMemory(int change_in_bytes) { |
2638 if (IsDeadCheck("v8::V8::AdjustAmountOfExternalAllocatedMemory()")) return 0; | 2639 if (IsDeadCheck("v8::V8::AdjustAmountOfExternalAllocatedMemory()")) return 0; |
2639 return i::Heap::AdjustAmountOfExternalAllocatedMemory(change_in_bytes); | 2640 return i::Heap::AdjustAmountOfExternalAllocatedMemory(change_in_bytes); |
2640 } | 2641 } |
2641 | 2642 |
2642 | 2643 |
2643 void V8::SetGlobalGCPrologueCallback(GCCallback callback) { | 2644 void V8::SetGlobalGCPrologueCallback(GCCallback callback) { |
(...skipping 352 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2996 reinterpret_cast<HandleScopeImplementer*>(storage); | 2997 reinterpret_cast<HandleScopeImplementer*>(storage); |
2997 List<void**>* blocks_of_archived_thread = thread_local->Blocks(); | 2998 List<void**>* blocks_of_archived_thread = thread_local->Blocks(); |
2998 ImplementationUtilities::HandleScopeData* handle_data_of_archived_thread = | 2999 ImplementationUtilities::HandleScopeData* handle_data_of_archived_thread = |
2999 &thread_local->handle_scope_data_; | 3000 &thread_local->handle_scope_data_; |
3000 Iterate(v, blocks_of_archived_thread, handle_data_of_archived_thread); | 3001 Iterate(v, blocks_of_archived_thread, handle_data_of_archived_thread); |
3001 | 3002 |
3002 return storage + ArchiveSpacePerThread(); | 3003 return storage + ArchiveSpacePerThread(); |
3003 } | 3004 } |
3004 | 3005 |
3005 } } // namespace v8::internal | 3006 } } // namespace v8::internal |
OLD | NEW |