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 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
52 bool CodeEntry::is_js_function_tag(Logger::LogEventsAndTags tag) { | 52 bool CodeEntry::is_js_function_tag(Logger::LogEventsAndTags tag) { |
53 return tag == Logger::FUNCTION_TAG | 53 return tag == Logger::FUNCTION_TAG |
54 || tag == Logger::LAZY_COMPILE_TAG | 54 || tag == Logger::LAZY_COMPILE_TAG |
55 || tag == Logger::SCRIPT_TAG | 55 || tag == Logger::SCRIPT_TAG |
56 || tag == Logger::NATIVE_FUNCTION_TAG | 56 || tag == Logger::NATIVE_FUNCTION_TAG |
57 || tag == Logger::NATIVE_LAZY_COMPILE_TAG | 57 || tag == Logger::NATIVE_LAZY_COMPILE_TAG |
58 || tag == Logger::NATIVE_SCRIPT_TAG; | 58 || tag == Logger::NATIVE_SCRIPT_TAG; |
59 } | 59 } |
60 | 60 |
61 | 61 |
62 ProfileNode::ProfileNode(CodeEntry* entry) | 62 ProfileNode::ProfileNode(ProfileTree* tree, CodeEntry* entry) |
63 : entry_(entry), | 63 : tree_(tree), |
| 64 entry_(entry), |
64 total_ticks_(0), | 65 total_ticks_(0), |
65 self_ticks_(0), | 66 self_ticks_(0), |
66 children_(CodeEntriesMatch) { | 67 children_(CodeEntriesMatch) { |
67 } | 68 } |
68 | 69 |
69 | 70 |
70 void CodeMap::AddCode(Address addr, CodeEntry* entry, unsigned size) { | 71 void CodeMap::AddCode(Address addr, CodeEntry* entry, unsigned size) { |
71 CodeTree::Locator locator; | 72 CodeTree::Locator locator; |
72 tree_.Insert(addr, &locator); | 73 tree_.Insert(addr, &locator); |
73 locator.set_value(CodeEntryInfo(entry, size)); | 74 locator.set_value(CodeEntryInfo(entry, size)); |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
114 return program_entry_; | 115 return program_entry_; |
115 default: return NULL; | 116 default: return NULL; |
116 } | 117 } |
117 } | 118 } |
118 | 119 |
119 } } // namespace v8::internal | 120 } } // namespace v8::internal |
120 | 121 |
121 #endif // ENABLE_LOGGING_AND_PROFILING | 122 #endif // ENABLE_LOGGING_AND_PROFILING |
122 | 123 |
123 #endif // V8_PROFILE_GENERATOR_INL_H_ | 124 #endif // V8_PROFILE_GENERATOR_INL_H_ |
OLD | NEW |