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 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
68 typedef uint32_t SnapshotObjectId; | 68 typedef uint32_t SnapshotObjectId; |
69 | 69 |
70 /** | 70 /** |
71 * CpuProfileNode represents a node in a call graph. | 71 * CpuProfileNode represents a node in a call graph. |
72 */ | 72 */ |
73 class V8EXPORT CpuProfileNode { | 73 class V8EXPORT CpuProfileNode { |
74 public: | 74 public: |
75 /** Returns function name (empty string for anonymous functions.) */ | 75 /** Returns function name (empty string for anonymous functions.) */ |
76 Handle<String> GetFunctionName() const; | 76 Handle<String> GetFunctionName() const; |
77 | 77 |
78 /** Returns id of the script where function is located. */ | |
79 int GetScriptId() const; | |
yurys
2013/06/25 09:16:55
In v8.h Script::Id returns v8::Local<v8::Value> an
| |
80 | |
78 /** Returns resource name for script from where the function originates. */ | 81 /** Returns resource name for script from where the function originates. */ |
79 Handle<String> GetScriptResourceName() const; | 82 Handle<String> GetScriptResourceName() const; |
80 | 83 |
81 /** | 84 /** |
82 * Returns the number, 1-based, of the line where the function originates. | 85 * Returns the number, 1-based, of the line where the function originates. |
83 * kNoLineNumberInfo if no line number information is available. | 86 * kNoLineNumberInfo if no line number information is available. |
84 */ | 87 */ |
85 int GetLineNumber() const; | 88 int GetLineNumber() const; |
86 | 89 |
87 /** | 90 /** |
(...skipping 19 matching lines...) Expand all Loading... | |
107 | 110 |
108 /** Returns id of the node. The id is unique within the tree */ | 111 /** Returns id of the node. The id is unique within the tree */ |
109 unsigned GetNodeId() const; | 112 unsigned GetNodeId() const; |
110 | 113 |
111 /** Returns child nodes count of the node. */ | 114 /** Returns child nodes count of the node. */ |
112 int GetChildrenCount() const; | 115 int GetChildrenCount() const; |
113 | 116 |
114 /** Retrieves a child node by index. */ | 117 /** Retrieves a child node by index. */ |
115 const CpuProfileNode* GetChild(int index) const; | 118 const CpuProfileNode* GetChild(int index) const; |
116 | 119 |
120 static const int kNoScriptId = 0; | |
117 static const int kNoLineNumberInfo = Message::kNoLineNumberInfo; | 121 static const int kNoLineNumberInfo = Message::kNoLineNumberInfo; |
118 }; | 122 }; |
119 | 123 |
120 | 124 |
121 /** | 125 /** |
122 * CpuProfile contains a CPU profile in a form of top-down call tree | 126 * CpuProfile contains a CPU profile in a form of top-down call tree |
123 * (from main() down to functions that do all the work). | 127 * (from main() down to functions that do all the work). |
124 */ | 128 */ |
125 class V8EXPORT CpuProfile { | 129 class V8EXPORT CpuProfile { |
126 public: | 130 public: |
(...skipping 472 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
599 }; | 603 }; |
600 | 604 |
601 | 605 |
602 } // namespace v8 | 606 } // namespace v8 |
603 | 607 |
604 | 608 |
605 #undef V8EXPORT | 609 #undef V8EXPORT |
606 | 610 |
607 | 611 |
608 #endif // V8_V8_PROFILER_H_ | 612 #endif // V8_V8_PROFILER_H_ |
OLD | NEW |