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 7549 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7560 return reinterpret_cast<const CpuProfileNode*>(profile->top_down()->root()); | 7560 return reinterpret_cast<const CpuProfileNode*>(profile->top_down()->root()); |
7561 } | 7561 } |
7562 | 7562 |
7563 | 7563 |
7564 const CpuProfileNode* CpuProfile::GetSample(int index) const { | 7564 const CpuProfileNode* CpuProfile::GetSample(int index) const { |
7565 const i::CpuProfile* profile = reinterpret_cast<const i::CpuProfile*>(this); | 7565 const i::CpuProfile* profile = reinterpret_cast<const i::CpuProfile*>(this); |
7566 return reinterpret_cast<const CpuProfileNode*>(profile->sample(index)); | 7566 return reinterpret_cast<const CpuProfileNode*>(profile->sample(index)); |
7567 } | 7567 } |
7568 | 7568 |
7569 | 7569 |
7570 double CpuProfile::GetStartTime() const { | 7570 int64_t CpuProfile::GetStartTime() const { |
7571 const i::CpuProfile* profile = reinterpret_cast<const i::CpuProfile*>(this); | 7571 const i::CpuProfile* profile = reinterpret_cast<const i::CpuProfile*>(this); |
7572 return profile->start_time_ms(); | 7572 return profile->start_time_us(); |
7573 } | 7573 } |
7574 | 7574 |
7575 | 7575 |
7576 double CpuProfile::GetEndTime() const { | 7576 int64_t CpuProfile::GetEndTime() const { |
7577 const i::CpuProfile* profile = reinterpret_cast<const i::CpuProfile*>(this); | 7577 const i::CpuProfile* profile = reinterpret_cast<const i::CpuProfile*>(this); |
7578 return profile->end_time_ms(); | 7578 return profile->end_time_us(); |
7579 } | 7579 } |
7580 | 7580 |
7581 | 7581 |
7582 int CpuProfile::GetSamplesCount() const { | 7582 int CpuProfile::GetSamplesCount() const { |
7583 return reinterpret_cast<const i::CpuProfile*>(this)->samples_count(); | 7583 return reinterpret_cast<const i::CpuProfile*>(this)->samples_count(); |
7584 } | 7584 } |
7585 | 7585 |
7586 | 7586 |
7587 int CpuProfiler::GetProfileCount() { | 7587 int CpuProfiler::GetProfileCount() { |
7588 return reinterpret_cast<i::CpuProfiler*>(this)->GetProfilesCount(); | 7588 return reinterpret_cast<i::CpuProfiler*>(this)->GetProfilesCount(); |
(...skipping 547 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8136 Isolate* isolate = reinterpret_cast<Isolate*>(info.GetIsolate()); | 8136 Isolate* isolate = reinterpret_cast<Isolate*>(info.GetIsolate()); |
8137 Address callback_address = | 8137 Address callback_address = |
8138 reinterpret_cast<Address>(reinterpret_cast<intptr_t>(callback)); | 8138 reinterpret_cast<Address>(reinterpret_cast<intptr_t>(callback)); |
8139 VMState<EXTERNAL> state(isolate); | 8139 VMState<EXTERNAL> state(isolate); |
8140 ExternalCallbackScope call_scope(isolate, callback_address); | 8140 ExternalCallbackScope call_scope(isolate, callback_address); |
8141 return callback(info); | 8141 return callback(info); |
8142 } | 8142 } |
8143 | 8143 |
8144 | 8144 |
8145 } } // namespace v8::internal | 8145 } } // namespace v8::internal |
OLD | NEW |