| 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 7727 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7738 return reinterpret_cast<i::HeapProfiler*>(this)->GetSnapshotsCount(); | 7738 return reinterpret_cast<i::HeapProfiler*>(this)->GetSnapshotsCount(); |
| 7739 } | 7739 } |
| 7740 | 7740 |
| 7741 | 7741 |
| 7742 const HeapSnapshot* HeapProfiler::GetHeapSnapshot(int index) { | 7742 const HeapSnapshot* HeapProfiler::GetHeapSnapshot(int index) { |
| 7743 return reinterpret_cast<const HeapSnapshot*>( | 7743 return reinterpret_cast<const HeapSnapshot*>( |
| 7744 reinterpret_cast<i::HeapProfiler*>(this)->GetSnapshot(index)); | 7744 reinterpret_cast<i::HeapProfiler*>(this)->GetSnapshot(index)); |
| 7745 } | 7745 } |
| 7746 | 7746 |
| 7747 | 7747 |
| 7748 const HeapSnapshot* HeapProfiler::FindHeapSnapshot(unsigned uid) { | |
| 7749 return reinterpret_cast<const HeapSnapshot*>( | |
| 7750 reinterpret_cast<i::HeapProfiler*>(this)->FindSnapshot(uid)); | |
| 7751 } | |
| 7752 | |
| 7753 | |
| 7754 SnapshotObjectId HeapProfiler::GetObjectId(Handle<Value> value) { | 7748 SnapshotObjectId HeapProfiler::GetObjectId(Handle<Value> value) { |
| 7755 i::Handle<i::Object> obj = Utils::OpenHandle(*value); | 7749 i::Handle<i::Object> obj = Utils::OpenHandle(*value); |
| 7756 return reinterpret_cast<i::HeapProfiler*>(this)->GetSnapshotObjectId(obj); | 7750 return reinterpret_cast<i::HeapProfiler*>(this)->GetSnapshotObjectId(obj); |
| 7757 } | 7751 } |
| 7758 | 7752 |
| 7759 | 7753 |
| 7760 const HeapSnapshot* HeapProfiler::TakeHeapSnapshot( | 7754 const HeapSnapshot* HeapProfiler::TakeHeapSnapshot( |
| 7761 Handle<String> title, | 7755 Handle<String> title, |
| 7762 ActivityControl* control, | 7756 ActivityControl* control, |
| 7763 ObjectNameResolver* resolver) { | 7757 ObjectNameResolver* resolver) { |
| (...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8063 Isolate* isolate = reinterpret_cast<Isolate*>(info.GetIsolate()); | 8057 Isolate* isolate = reinterpret_cast<Isolate*>(info.GetIsolate()); |
| 8064 Address callback_address = | 8058 Address callback_address = |
| 8065 reinterpret_cast<Address>(reinterpret_cast<intptr_t>(callback)); | 8059 reinterpret_cast<Address>(reinterpret_cast<intptr_t>(callback)); |
| 8066 VMState<EXTERNAL> state(isolate); | 8060 VMState<EXTERNAL> state(isolate); |
| 8067 ExternalCallbackScope call_scope(isolate, callback_address); | 8061 ExternalCallbackScope call_scope(isolate, callback_address); |
| 8068 return callback(info); | 8062 return callback(info); |
| 8069 } | 8063 } |
| 8070 | 8064 |
| 8071 | 8065 |
| 8072 } } // namespace v8::internal | 8066 } } // namespace v8::internal |
| OLD | NEW |