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 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 entry->set_shared_id(code_map->GetSharedId(shared)); | 44 entry->set_shared_id(code_map->GetSharedId(shared)); |
45 } | 45 } |
46 } | 46 } |
47 | 47 |
48 | 48 |
49 void CodeMoveEventRecord::UpdateCodeMap(CodeMap* code_map) { | 49 void CodeMoveEventRecord::UpdateCodeMap(CodeMap* code_map) { |
50 code_map->MoveCode(from, to); | 50 code_map->MoveCode(from, to); |
51 } | 51 } |
52 | 52 |
53 | 53 |
54 void CodeDeleteEventRecord::UpdateCodeMap(CodeMap* code_map) { | |
55 code_map->DeleteCode(start); | |
56 } | |
57 | |
58 | |
59 void SharedFunctionInfoMoveEventRecord::UpdateCodeMap(CodeMap* code_map) { | 54 void SharedFunctionInfoMoveEventRecord::UpdateCodeMap(CodeMap* code_map) { |
60 code_map->MoveCode(from, to); | 55 code_map->MoveCode(from, to); |
61 } | 56 } |
62 | 57 |
63 | 58 |
64 TickSample* ProfilerEventsProcessor::TickSampleEvent() { | 59 TickSample* ProfilerEventsProcessor::TickSampleEvent() { |
65 generator_->Tick(); | 60 generator_->Tick(); |
66 TickSampleEventRecord* evt = | 61 TickSampleEventRecord* evt = |
67 new(ticks_buffer_.Enqueue()) TickSampleEventRecord(enqueue_order_); | 62 new(ticks_buffer_.Enqueue()) TickSampleEventRecord(enqueue_order_); |
68 return &evt->sample; | 63 return &evt->sample; |
69 } | 64 } |
70 | 65 |
71 | 66 |
72 bool ProfilerEventsProcessor::FilterOutCodeCreateEvent( | 67 bool ProfilerEventsProcessor::FilterOutCodeCreateEvent( |
73 Logger::LogEventsAndTags tag) { | 68 Logger::LogEventsAndTags tag) { |
74 return FLAG_prof_browser_mode | 69 return FLAG_prof_browser_mode |
75 && (tag != Logger::CALLBACK_TAG | 70 && (tag != Logger::CALLBACK_TAG |
76 && tag != Logger::FUNCTION_TAG | 71 && tag != Logger::FUNCTION_TAG |
77 && tag != Logger::LAZY_COMPILE_TAG | 72 && tag != Logger::LAZY_COMPILE_TAG |
78 && tag != Logger::REG_EXP_TAG | 73 && tag != Logger::REG_EXP_TAG |
79 && tag != Logger::SCRIPT_TAG); | 74 && tag != Logger::SCRIPT_TAG); |
80 } | 75 } |
81 | 76 |
82 } } // namespace v8::internal | 77 } } // namespace v8::internal |
83 | 78 |
84 #endif // V8_CPU_PROFILER_INL_H_ | 79 #endif // V8_CPU_PROFILER_INL_H_ |
OLD | NEW |