OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
166 AddRange(to, size, trace_node_id); | 166 AddRange(to, size, trace_node_id); |
167 } | 167 } |
168 | 168 |
169 | 169 |
170 void AddressToTraceMap::Clear() { | 170 void AddressToTraceMap::Clear() { |
171 ranges_.clear(); | 171 ranges_.clear(); |
172 } | 172 } |
173 | 173 |
174 | 174 |
175 void AddressToTraceMap::Print() { | 175 void AddressToTraceMap::Print() { |
176 PrintF("[AddressToTraceMap (%lu): \n", ranges_.size()); | 176 PrintF("[AddressToTraceMap (%" V8PRIuPTR "): \n", ranges_.size()); |
177 for (RangeMap::iterator it = ranges_.begin(); it != ranges_.end(); ++it) { | 177 for (RangeMap::iterator it = ranges_.begin(); it != ranges_.end(); ++it) { |
178 PrintF("[%p - %p] => %u\n", it->second.start, it->first, | 178 PrintF("[%p - %p] => %u\n", it->second.start, it->first, |
179 it->second.trace_node_id); | 179 it->second.trace_node_id); |
180 } | 180 } |
181 PrintF("]\n"); | 181 PrintF("]\n"); |
182 } | 182 } |
183 | 183 |
184 | 184 |
185 void AddressToTraceMap::RemoveRange(Address start, Address end) { | 185 void AddressToTraceMap::RemoveRange(Address start, Address end) { |
186 RangeMap::iterator it = ranges_.upper_bound(start); | 186 RangeMap::iterator it = ranges_.upper_bound(start); |
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
362 void AllocationTracker::UnresolvedLocation::HandleWeakScript( | 362 void AllocationTracker::UnresolvedLocation::HandleWeakScript( |
363 const v8::WeakCallbackData<v8::Value, void>& data) { | 363 const v8::WeakCallbackData<v8::Value, void>& data) { |
364 UnresolvedLocation* loc = | 364 UnresolvedLocation* loc = |
365 reinterpret_cast<UnresolvedLocation*>(data.GetParameter()); | 365 reinterpret_cast<UnresolvedLocation*>(data.GetParameter()); |
366 GlobalHandles::Destroy(reinterpret_cast<Object**>(loc->script_.location())); | 366 GlobalHandles::Destroy(reinterpret_cast<Object**>(loc->script_.location())); |
367 loc->script_ = Handle<Script>::null(); | 367 loc->script_ = Handle<Script>::null(); |
368 } | 368 } |
369 | 369 |
370 | 370 |
371 } } // namespace v8::internal | 371 } } // namespace v8::internal |
OLD | NEW |