LCOV - code coverage report
Current view: top level - src/heap - incremental-marking-inl.h (source / functions) Hit Total Coverage
Test: app.info Lines: 11 12 91.7 %
Date: 2017-04-26 Functions: 1 1 100.0 %

          Line data    Source code
       1             : // Copyright 2012 the V8 project authors. All rights reserved.
       2             : // Use of this source code is governed by a BSD-style license that can be
       3             : // found in the LICENSE file.
       4             : 
       5             : #ifndef V8_HEAP_INCREMENTAL_MARKING_INL_H_
       6             : #define V8_HEAP_INCREMENTAL_MARKING_INL_H_
       7             : 
       8             : #include "src/heap/incremental-marking.h"
       9             : #include "src/isolate.h"
      10             : 
      11             : namespace v8 {
      12             : namespace internal {
      13             : 
      14             : 
      15             : void IncrementalMarking::RecordWrite(HeapObject* obj, Object** slot,
      16             :                                      Object* value) {
      17  2996730859 :   if (IsMarking() && value->IsHeapObject()) {
      18   109709277 :     RecordWriteSlow(obj, slot, value);
      19             :   }
      20             : }
      21             : 
      22             : 
      23             : void IncrementalMarking::RecordWriteOfCodeEntry(JSFunction* host, Object** slot,
      24             :                                                 Code* value) {
      25    29785539 :   if (IsMarking()) {
      26     1145455 :     RecordWriteOfCodeEntrySlow(host, slot, value);
      27             :   }
      28             : }
      29             : 
      30             : void IncrementalMarking::RecordWriteIntoCode(Code* host, RelocInfo* rinfo,
      31             :                                              Object* value) {
      32    35392921 :   if (IsMarking() && value->IsHeapObject()) {
      33      985530 :     RecordWriteIntoCodeSlow(host, rinfo, value);
      34             :   }
      35             : }
      36             : 
      37     2217012 : void IncrementalMarking::RestartIfNotMarking() {
      38     2217012 :   if (state_ == COMPLETE) {
      39         558 :     state_ = MARKING;
      40         558 :     if (FLAG_trace_incremental_marking) {
      41             :       heap()->isolate()->PrintWithTimestamp(
      42           0 :           "[IncrementalMarking] Restarting (new grey objects)\n");
      43             :     }
      44             :   }
      45     2217012 : }
      46             : 
      47             : }  // namespace internal
      48             : }  // namespace v8
      49             : 
      50             : #endif  // V8_HEAP_INCREMENTAL_MARKING_INL_H_

Generated by: LCOV version 1.10