OLD | NEW |
1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 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 1116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1127 | 1127 |
1128 | 1128 |
1129 #ifdef ENABLE_LOGGING_AND_PROFILING | 1129 #ifdef ENABLE_LOGGING_AND_PROFILING |
1130 void Logger::TickEvent(TickSample* sample, bool overflow) { | 1130 void Logger::TickEvent(TickSample* sample, bool overflow) { |
1131 if (!log_->IsEnabled() || !FLAG_prof) return; | 1131 if (!log_->IsEnabled() || !FLAG_prof) return; |
1132 LogMessageBuilder msg(this); | 1132 LogMessageBuilder msg(this); |
1133 msg.Append("%s,", kLogEventsNames[TICK_EVENT]); | 1133 msg.Append("%s,", kLogEventsNames[TICK_EVENT]); |
1134 msg.AppendAddress(sample->pc); | 1134 msg.AppendAddress(sample->pc); |
1135 msg.Append(','); | 1135 msg.Append(','); |
1136 msg.AppendAddress(sample->sp); | 1136 msg.AppendAddress(sample->sp); |
1137 msg.Append(','); | |
1138 if (sample->has_external_callback) { | 1137 if (sample->has_external_callback) { |
1139 msg.Append(",1,"); | 1138 msg.Append(",1,"); |
1140 msg.AppendAddress(sample->external_callback); | 1139 msg.AppendAddress(sample->external_callback); |
1141 } else { | 1140 } else { |
1142 msg.Append(",0,"); | 1141 msg.Append(",0,"); |
1143 msg.AppendAddress(sample->tos); | 1142 msg.AppendAddress(sample->tos); |
1144 } | 1143 } |
1145 msg.Append(",%d", static_cast<int>(sample->state)); | 1144 msg.Append(",%d", static_cast<int>(sample->state)); |
1146 if (overflow) { | 1145 if (overflow) { |
1147 msg.Append(",overflow"); | 1146 msg.Append(",overflow"); |
(...skipping 509 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1657 void SamplerRegistry::RemoveActiveSampler(Sampler* sampler) { | 1656 void SamplerRegistry::RemoveActiveSampler(Sampler* sampler) { |
1658 ASSERT(sampler->IsActive()); | 1657 ASSERT(sampler->IsActive()); |
1659 ScopedLock lock(mutex_); | 1658 ScopedLock lock(mutex_); |
1660 ASSERT(active_samplers_ != NULL); | 1659 ASSERT(active_samplers_ != NULL); |
1661 bool removed = active_samplers_->RemoveElement(sampler); | 1660 bool removed = active_samplers_->RemoveElement(sampler); |
1662 ASSERT(removed); | 1661 ASSERT(removed); |
1663 USE(removed); | 1662 USE(removed); |
1664 } | 1663 } |
1665 | 1664 |
1666 } } // namespace v8::internal | 1665 } } // namespace v8::internal |
OLD | NEW |