OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 1723 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1734 heap->CopyBlock(target->address(), source->address(), size); | 1734 heap->CopyBlock(target->address(), source->address(), size); |
1735 | 1735 |
1736 // Set the forwarding address. | 1736 // Set the forwarding address. |
1737 source->set_map_word(MapWord::FromForwardingAddress(target)); | 1737 source->set_map_word(MapWord::FromForwardingAddress(target)); |
1738 | 1738 |
1739 if (logging_and_profiling_mode == LOGGING_AND_PROFILING_ENABLED) { | 1739 if (logging_and_profiling_mode == LOGGING_AND_PROFILING_ENABLED) { |
1740 // Update NewSpace stats if necessary. | 1740 // Update NewSpace stats if necessary. |
1741 RecordCopiedObject(heap, target); | 1741 RecordCopiedObject(heap, target); |
1742 HEAP_PROFILE(heap, ObjectMoveEvent(source->address(), target->address())); | 1742 HEAP_PROFILE(heap, ObjectMoveEvent(source->address(), target->address())); |
1743 Isolate* isolate = heap->isolate(); | 1743 Isolate* isolate = heap->isolate(); |
1744 if (isolate->logger()->is_logging_code_events() || | 1744 if (isolate->logger()->is_logging() || |
1745 CpuProfiler::is_profiling(isolate)) { | 1745 CpuProfiler::is_profiling(isolate)) { |
1746 if (target->IsSharedFunctionInfo()) { | 1746 if (target->IsSharedFunctionInfo()) { |
1747 PROFILE(isolate, SharedFunctionInfoMoveEvent( | 1747 PROFILE(isolate, SharedFunctionInfoMoveEvent( |
1748 source->address(), target->address())); | 1748 source->address(), target->address())); |
1749 } | 1749 } |
1750 } | 1750 } |
1751 } | 1751 } |
1752 | 1752 |
1753 if (marks_handling == TRANSFER_MARKS) { | 1753 if (marks_handling == TRANSFER_MARKS) { |
1754 if (Marking::TransferColor(source, target)) { | 1754 if (Marking::TransferColor(source, target)) { |
(...skipping 5528 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7283 static_cast<int>(object_sizes_last_time_[index])); | 7283 static_cast<int>(object_sizes_last_time_[index])); |
7284 FIXED_ARRAY_SUB_INSTANCE_TYPE_LIST(ADJUST_LAST_TIME_OBJECT_COUNT) | 7284 FIXED_ARRAY_SUB_INSTANCE_TYPE_LIST(ADJUST_LAST_TIME_OBJECT_COUNT) |
7285 #undef ADJUST_LAST_TIME_OBJECT_COUNT | 7285 #undef ADJUST_LAST_TIME_OBJECT_COUNT |
7286 | 7286 |
7287 memcpy(object_counts_last_time_, object_counts_, sizeof(object_counts_)); | 7287 memcpy(object_counts_last_time_, object_counts_, sizeof(object_counts_)); |
7288 memcpy(object_sizes_last_time_, object_sizes_, sizeof(object_sizes_)); | 7288 memcpy(object_sizes_last_time_, object_sizes_, sizeof(object_sizes_)); |
7289 ClearObjectStats(); | 7289 ClearObjectStats(); |
7290 } | 7290 } |
7291 | 7291 |
7292 } } // namespace v8::internal | 7292 } } // namespace v8::internal |
OLD | NEW |