Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(77)

Unified Diff: src/compiler.h

Issue 996153003: CpuProfiler: simplify inlined function info magic. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: comments addressed Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/compiler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler.h
diff --git a/src/compiler.h b/src/compiler.h
index 598c7c51c30c66eeb8010b1629de012542c0cbc3..b3f49931cc3acc8807ab68f7dcdfc9d6d64b2a84 100644
--- a/src/compiler.h
+++ b/src/compiler.h
@@ -86,17 +86,19 @@ class SourcePosition {
std::ostream& operator<<(std::ostream& os, const SourcePosition& p);
-class InlinedFunctionInfo {
- public:
- explicit InlinedFunctionInfo(Handle<SharedFunctionInfo> shared)
- : shared_(shared), start_position_(shared->start_position()) {}
-
- Handle<SharedFunctionInfo> shared() const { return shared_; }
- int start_position() const { return start_position_; }
-
- private:
- Handle<SharedFunctionInfo> shared_;
- int start_position_;
+struct InlinedFunctionInfo {
+ InlinedFunctionInfo(int parent_id, SourcePosition inline_position,
+ int script_id, int start_position)
+ : parent_id(parent_id),
+ inline_position(inline_position),
+ script_id(script_id),
+ start_position(start_position) {}
+ int parent_id;
+ SourcePosition inline_position;
+ int script_id;
+ int start_position;
+
+ static const int kNoParentId = -1;
};
@@ -338,11 +340,8 @@ class CompilationInfo {
List<InlinedFunctionInfo>* inlined_function_infos() {
return inlined_function_infos_;
}
- List<int>* inlining_id_to_function_id() {
- return inlining_id_to_function_id_;
- }
int TraceInlinedFunction(Handle<SharedFunctionInfo> shared,
- SourcePosition position);
+ SourcePosition position, int pareint_id);
Handle<Foreign> object_wrapper() {
if (object_wrapper_.is_null()) {
@@ -450,7 +449,6 @@ class CompilationInfo {
List<OffsetRange>* no_frame_ranges_;
List<InlinedFunctionInfo>* inlined_function_infos_;
- List<int>* inlining_id_to_function_id_;
// A copy of shared_info()->opt_count() to avoid handle deref
// during graph optimization.
« no previous file with comments | « no previous file | src/compiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698