enclose-io/compiler

View on GitHub
lts/deps/v8/tools/profile.js

Summary

Maintainability
F
3 wks
Test Coverage

File profile.js has 597 lines of code (exceeds 250 allowed). Consider refactoring.
Open

// Copyright 2009 the V8 project authors. All rights reserved.
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
//
Severity: Major
Found in lts/deps/v8/tools/profile.js - About 1 day to fix

    Function resolveAndFilterFuncs_ has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring.
    Open

    Profile.prototype.resolveAndFilterFuncs_ = function(stack) {
      var result = [];
      var last_seen_c_function = '';
      var look_for_first_c_function = false;
      for (var i = 0; i < stack.length; ++i) {
    Severity: Minor
    Found in lts/deps/v8/tools/profile.js - About 3 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

    Function getFlatProfile has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring.
    Open

    Profile.prototype.getFlatProfile = function(opt_label) {
      var counters = new CallTree();
      var rootLabel = opt_label || CallTree.ROOT_NODE_LABEL;
      var precs = {};
      precs[rootLabel] = 0;
    Severity: Minor
    Found in lts/deps/v8/tools/profile.js - About 2 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

    Function getFlatProfile has 39 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    Profile.prototype.getFlatProfile = function(opt_label) {
      var counters = new CallTree();
      var rootLabel = opt_label || CallTree.ROOT_NODE_LABEL;
      var precs = {};
      precs[rootLabel] = 0;
    Severity: Minor
    Found in lts/deps/v8/tools/profile.js - About 1 hr to fix

      Function addFuncCode has 37 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      JsonProfile.prototype.addFuncCode = function(
          kind, name, timestamp, start, size, funcAddr, state) {
        // As code and functions are in the same address space,
        // it is safe to put them in a single code map.
        var func = this.codeMap_.findDynamicEntryByStartAddress(funcAddr);
      Severity: Minor
      Found in lts/deps/v8/tools/profile.js - About 1 hr to fix

        Function resolveAndFilterFuncs_ has 32 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        Profile.prototype.resolveAndFilterFuncs_ = function(stack) {
          var result = [];
          var last_seen_c_function = '';
          var look_for_first_c_function = false;
          for (var i = 0; i < stack.length; ++i) {
        Severity: Minor
        Found in lts/deps/v8/tools/profile.js - About 1 hr to fix

          Function addSourcePositions has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
          Open

          JsonProfile.prototype.addSourcePositions = function(
              start, script, startPos, endPos, sourcePositions, inliningPositions,
              inlinedFunctions) {
            var entry = this.codeMap_.findDynamicEntryByStartAddress(start);
            if (!entry) return;
          Severity: Minor
          Found in lts/deps/v8/tools/profile.js - About 1 hr to fix

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Function addFuncCode has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
          Open

          JsonProfile.prototype.addFuncCode = function(
              kind, name, timestamp, start, size, funcAddr, state) {
            // As code and functions are in the same address space,
            // it is safe to put them in a single code map.
            var func = this.codeMap_.findDynamicEntryByStartAddress(funcAddr);
          Severity: Minor
          Found in lts/deps/v8/tools/profile.js - About 1 hr to fix

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Function cleanUpFuncEntries has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
          Open

          Profile.prototype.cleanUpFuncEntries = function() {
            var referencedFuncEntries = [];
            var entries = this.codeMap_.getAllDynamicEntriesWithAddresses();
            for (var i = 0, l = entries.length; i < l; ++i) {
              if (entries[i][1].constructor === Profile.FunctionEntry) {
          Severity: Minor
          Found in lts/deps/v8/tools/profile.js - About 1 hr to fix

          Cognitive Complexity

          Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

          A method's cognitive complexity is based on a few simple rules:

          • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
          • Code is considered more complex for each "break in the linear flow of the code"
          • Code is considered more complex when "flow breaking structures are nested"

          Further reading

          Function addSourcePositions has 26 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          JsonProfile.prototype.addSourcePositions = function(
              start, script, startPos, endPos, sourcePositions, inliningPositions,
              inlinedFunctions) {
            var entry = this.codeMap_.findDynamicEntryByStartAddress(start);
            if (!entry) return;
          Severity: Minor
          Found in lts/deps/v8/tools/profile.js - About 1 hr to fix

            Function addFuncCode has 7 arguments (exceeds 4 allowed). Consider refactoring.
            Open

                type, name, timestamp, start, size, funcAddr, state) {
            Severity: Major
            Found in lts/deps/v8/tools/profile.js - About 50 mins to fix

              Function addFuncCode has 7 arguments (exceeds 4 allowed). Consider refactoring.
              Open

                  kind, name, timestamp, start, size, funcAddr, state) {
              Severity: Major
              Found in lts/deps/v8/tools/profile.js - About 50 mins to fix

                Function addSourcePositions has 7 arguments (exceeds 4 allowed). Consider refactoring.
                Open

                    start, script, startPos, endPos, sourcePositions, inliningPositions,
                    inlinedFunctions) {
                Severity: Major
                Found in lts/deps/v8/tools/profile.js - About 50 mins to fix

                  Function deoptCode has 7 arguments (exceeds 4 allowed). Consider refactoring.
                  Open

                      timestamp, code, inliningId, scriptOffset, bailoutType,
                      sourcePositionText, deoptReasonText) {
                  Severity: Major
                  Found in lts/deps/v8/tools/profile.js - About 50 mins to fix

                    Function deoptCode has 7 arguments (exceeds 4 allowed). Consider refactoring.
                    Open

                        timestamp, code, inliningId, scriptOffset, bailoutType,
                        sourcePositionText, deoptReasonText) {
                    Severity: Major
                    Found in lts/deps/v8/tools/profile.js - About 50 mins to fix

                      Function addSourcePositions has 7 arguments (exceeds 4 allowed). Consider refactoring.
                      Open

                          start, script, startPos, endPos, sourcePositions, inliningPositions,
                          inlinedFunctions) {
                      Severity: Major
                      Found in lts/deps/v8/tools/profile.js - About 50 mins to fix

                        Function writeJson has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                        Open

                        JsonProfile.prototype.writeJson = function() {
                          // Write out the JSON in a partially manual way to avoid creating too-large
                          // strings in one JSON.stringify call when there are a lot of ticks.
                          write('{\n')
                        
                        
                        Severity: Minor
                        Found in lts/deps/v8/tools/profile.js - About 45 mins to fix

                        Cognitive Complexity

                        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                        A method's cognitive complexity is based on a few simple rules:

                        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                        • Code is considered more complex for each "break in the linear flow of the code"
                        • Code is considered more complex when "flow breaking structures are nested"

                        Further reading

                        Function addCode has 5 arguments (exceeds 4 allowed). Consider refactoring.
                        Open

                            type, name, timestamp, start, size) {
                        Severity: Minor
                        Found in lts/deps/v8/tools/profile.js - About 35 mins to fix

                          Function addCode has 5 arguments (exceeds 4 allowed). Consider refactoring.
                          Open

                              kind, name, timestamp, start, size) {
                          Severity: Minor
                          Found in lts/deps/v8/tools/profile.js - About 35 mins to fix

                            Function addFuncCode has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                            Open

                            Profile.prototype.addFuncCode = function(
                                type, name, timestamp, start, size, funcAddr, state) {
                              // As code and functions are in the same address space,
                              // it is safe to put them in a single code map.
                              var func = this.codeMap_.findDynamicEntryByStartAddress(funcAddr);
                            Severity: Minor
                            Found in lts/deps/v8/tools/profile.js - About 35 mins to fix

                            Cognitive Complexity

                            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                            A method's cognitive complexity is based on a few simple rules:

                            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                            • Code is considered more complex for each "break in the linear flow of the code"
                            • Code is considered more complex when "flow breaking structures are nested"

                            Further reading

                            Similar blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.prototype.getFlatProfile = function(opt_label) {
                              var counters = new CallTree();
                              var rootLabel = opt_label || CallTree.ROOT_NODE_LABEL;
                              var precs = {};
                              precs[rootLabel] = 0;
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 2 days to fix
                            current/deps/v8/tools/profile.js on lines 378..424

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 446.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Similar blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.prototype.resolveAndFilterFuncs_ = function(stack) {
                              var result = [];
                              var last_seen_c_function = '';
                              var look_for_first_c_function = false;
                              for (var i = 0; i < stack.length; ++i) {
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 2 days to fix
                            current/deps/v8/tools/profile.js on lines 276..309

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 362.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.prototype.cleanUpFuncEntries = function() {
                              var referencedFuncEntries = [];
                              var entries = this.codeMap_.getAllDynamicEntriesWithAddresses();
                              for (var i = 0, l = entries.length; i < l; ++i) {
                                if (entries[i][1].constructor === Profile.FunctionEntry) {
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 day to fix
                            current/deps/v8/tools/profile.js on lines 452..471

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 302.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            JsonProfile.prototype.addSourcePositions = function(
                                start, script, startPos, endPos, sourcePositions, inliningPositions,
                                inlinedFunctions) {
                              var entry = this.codeMap_.findDynamicEntryByStartAddress(start);
                              if (!entry) return;
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 day to fix
                            current/deps/v8/tools/profile.js on lines 985..1017

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 299.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            JsonProfile.prototype.writeJson = function() {
                              // Write out the JSON in a partially manual way to avoid creating too-large
                              // strings in one JSON.stringify call when there are a lot of ticks.
                              write('{\n')
                            
                            
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 day to fix
                            current/deps/v8/tools/profile.js on lines 1086..1115

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 213.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            JsonProfile.prototype.addCode = function(
                                kind, name, timestamp, start, size) {
                              let codeId = this.codeEntries_.length;
                              // Find out if we have a static code entry for the code. If yes, we will
                              // make sure it is written to the JSON file just once.
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 7 hrs to fix
                            current/deps/v8/tools/profile.js on lines 897..919

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 194.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Similar blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.prototype.getCEntryProfile = function() {
                              var result = [new Profile.CEntryNode("TOTAL", 0)];
                              var total_ticks = 0;
                              for (var f in this.c_entries_) {
                                var ticks = this.c_entries_[f];
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 7 hrs to fix
                            current/deps/v8/tools/profile.js on lines 433..446

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 185.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.prototype.traverse = function(f) {
                              var pairsToProcess = new ConsArray();
                              pairsToProcess.concat([{node: this.root_, param: null}]);
                              while (!pairsToProcess.atEnd()) {
                                var pair = pairsToProcess.next();
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 7 hrs to fix
                            current/deps/v8/tools/profile.js on lines 709..721

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 178.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            JsonProfile.prototype.recordTick = function(time_ns, vmState, stack) {
                              // TODO(jarin) Resolve the frame-less case (when top of stack is
                              // known code).
                              var processedStack = [];
                              for (var i = 0; i < stack.length; i++) {
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 6 hrs to fix
                            current/deps/v8/tools/profile.js on lines 1067..1080

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 168.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                              if (!func) {
                                var func = new CodeMap.CodeEntry(0, name, 'SFI');
                                this.codeMap_.addCode(funcAddr, func);
                            
                                func.funcId = this.functionEntries_.length;
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 6 hrs to fix
                            current/deps/v8/tools/profile.js on lines 926..938

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 165.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            JsonProfile.prototype.deoptCode = function(
                                timestamp, code, inliningId, scriptOffset, bailoutType,
                                sourcePositionText, deoptReasonText) {
                              let entry = this.codeMap_.findDynamicEntryByStartAddress(code);
                              if (entry) {
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 5 hrs to fix
                            current/deps/v8/tools/profile.js on lines 1027..1047

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 139.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Similar blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.prototype.cloneSubtree = function(label) {
                              var subTree = new CallTree();
                              this.traverse(function(node, parent) {
                                if (!parent && node.label != label) {
                                  return null;
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 4 hrs to fix
                            current/deps/v8/tools/profile.js on lines 668..679

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 123.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.prototype.addPath = function(path) {
                              if (path.length == 0) {
                                return;
                              }
                              var curr = this.root_;
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 4 hrs to fix
                            current/deps/v8/tools/profile.js on lines 627..637

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 118.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Similar blocks of code found in 4 locations. Consider refactoring.
                            Open

                            JsonProfile.prototype.addLibrary = function(
                                name, startAddr, endAddr) {
                              var entry = new CodeMap.CodeEntry(
                                  endAddr - startAddr, name, 'SHARED_LIB');
                              this.codeMap_.addLibrary(startAddr, entry);
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 3 other locations - About 4 hrs to fix
                            current/deps/v8/tools/profile.js on lines 875..884
                            current/deps/v8/tools/profile.js on lines 886..895
                            lts/deps/v8/tools/profile.js on lines 882..891

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 116.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Similar blocks of code found in 4 locations. Consider refactoring.
                            Open

                            JsonProfile.prototype.addStaticCode = function(
                                name, startAddr, endAddr) {
                              var entry = new CodeMap.CodeEntry(
                                  endAddr - startAddr, name, 'CPP');
                              this.codeMap_.addStaticCode(startAddr, entry);
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 3 other locations - About 4 hrs to fix
                            current/deps/v8/tools/profile.js on lines 875..884
                            current/deps/v8/tools/profile.js on lines 886..895
                            lts/deps/v8/tools/profile.js on lines 871..880

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 116.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.Node.prototype.descendToChild = function(
                                labels, opt_f) {
                              for (var pos = 0, curr = this; pos < labels.length && curr != null; pos++) {
                                var child = curr.findChild(labels[pos]);
                                if (opt_f) {
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 3 hrs to fix
                            current/deps/v8/tools/profile.js on lines 855..865

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 112.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            function Profile() {
                              this.codeMap_ = new CodeMap();
                              this.topDownTree_ = new CallTree();
                              this.bottomUpTree_ = new CallTree();
                              this.c_entries_ = {};
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 3 hrs to fix
                            current/deps/v8/tools/profile.js on lines 35..41

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 102.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.FunctionEntry.prototype.getName = function() {
                              var name = this.name;
                              if (name.length == 0) {
                                name = '<anonymous>';
                              } else if (name.charAt(0) == ' ') {
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 3 hrs to fix
                            current/deps/v8/tools/profile.js on lines 578..587

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 95.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.prototype.recordTick = function(time_ns, vmState, stack) {
                              var processedStack = this.resolveAndFilterFuncs_(stack);
                              this.bottomUpTree_.addPath(processedStack);
                              processedStack.reverse();
                              this.topDownTree_.addPath(processedStack);
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 2 hrs to fix
                            current/deps/v8/tools/profile.js on lines 262..267

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 82.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.Node.prototype.computeTotalWeight =
                                function() {
                              var totalWeight = this.selfWeight;
                              this.forEachChild(function(child) {
                                  totalWeight += child.computeTotalWeight(); });
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 2 hrs to fix
                            current/deps/v8/tools/profile.js on lines 785..791

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 81.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.prototype.getTreeProfile_ = function(tree, opt_label) {
                              if (!opt_label) {
                                tree.computeTotalWeights();
                                return tree;
                              } else {
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 2 hrs to fix
                            current/deps/v8/tools/profile.js on lines 360..369

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 80.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.prototype.deleteCode = function(start) {
                              try {
                                this.codeMap_.deleteCode(start);
                              } catch (e) {
                                this.handleUnknownCode(Profile.Operation.DELETE, start);
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 209..215

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 74.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.prototype.moveCode = function(from, to) {
                              try {
                                this.codeMap_.moveCode(from, to);
                              } catch (e) {
                                this.handleUnknownCode(Profile.Operation.MOVE, from);
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 191..197

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 74.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.DynamicFuncCodeEntry.prototype.getName = function() {
                              var name = this.func.getName();
                              return this.type + ': ' + this.getState() + name;
                            };
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 540..543

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 72.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.prototype.traverseInDepth = function(enter, exit) {
                              function traverse(node) {
                                enter(node);
                                node.forEachChild(traverse);
                                exit(node);
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 732..739

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 71.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            function JsonProfile() {
                              this.codeMap_ = new CodeMap();
                              this.codeEntries_ = [];
                              this.functionEntries_ = [];
                              this.ticks_ = [];
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 867..873

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 70.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                              if (!func) {
                                func = new Profile.FunctionEntry(name);
                                this.codeMap_.addCode(funcAddr, func);
                              } else if (func.name !== name) {
                                // Function object has been overwritten with a new one.
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 160..166

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 69.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.Node.prototype.exportChildren = function() {
                              var result = [];
                              this.forEachChild(function (node) { result.push(node); });
                              return result;
                            };
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 797..801

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 67.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Similar blocks of code found in 4 locations. Consider refactoring.
                            Open

                            Profile.prototype.addLibrary = function(
                                name, startAddr, endAddr) {
                              var entry = new CodeMap.CodeEntry(
                                  endAddr - startAddr, name, 'SHARED_LIB');
                              this.codeMap_.addLibrary(startAddr, entry);
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 3 other locations - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 104..110
                            current/deps/v8/tools/profile.js on lines 120..126
                            lts/deps/v8/tools/profile.js on lines 120..126

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 67.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Similar blocks of code found in 4 locations. Consider refactoring.
                            Open

                            Profile.prototype.addStaticCode = function(
                                name, startAddr, endAddr) {
                              var entry = new CodeMap.CodeEntry(
                                  endAddr - startAddr, name, 'CPP');
                              this.codeMap_.addStaticCode(startAddr, entry);
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 3 other locations - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 104..110
                            current/deps/v8/tools/profile.js on lines 120..126
                            lts/deps/v8/tools/profile.js on lines 104..110

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 67.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.prototype.addCode = function(
                                type, name, timestamp, start, size) {
                              var entry = new Profile.DynamicCodeEntry(size, type, name);
                              this.codeMap_.addCode(start, entry);
                              return entry;
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 137..142

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 65.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.Node.prototype.walkUpToRoot = function(f) {
                              for (var curr = this; curr != null; curr = curr.parent) {
                                f(curr);
                              }
                            };
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 842..846

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 65.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.Node.prototype.addChild = function(label) {
                              var child = new CallTree.Node(label, this);
                              this.children[label] = child;
                              return child;
                            };
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 775..779

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 63.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            JsonProfile.prototype.moveCode = function(from, to) {
                              try {
                                this.codeMap_.moveCode(from, to);
                              } catch (e) {
                                printErr("Move: unknown source " + from);
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 977..983

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 63.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.DynamicFuncCodeEntry = function(size, type, func, state) {
                              CodeMap.CodeEntry.call(this, size, '', type);
                              this.func = func;
                              this.state = state;
                            };
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 522..526

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 62.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            JsonProfile.prototype.deleteCode = function(start) {
                              try {
                                this.codeMap_.deleteCode(start);
                              } catch (e) {
                                printErr("Delete: unknown address " + start);
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 1049..1055

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 61.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.Node.prototype.forEachChild = function(f) {
                              for (var c in this.children) {
                                f(this.children[c]);
                              }
                            };
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 830..834

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 61.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.prototype.computeTotalWeights = function() {
                              if (this.totalsComputed_) {
                                return;
                              }
                              this.root_.computeTotalWeight();
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 685..691

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 61.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.prototype.moveFunc = function(from, to) {
                              if (this.codeMap_.findDynamicEntryByStartAddress(from)) {
                                this.codeMap_.moveCode(from, to);
                              }
                            };
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 239..243

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 61.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            JsonProfile.prototype.moveFunc = function(from, to) {
                              if (this.codeMap_.findDynamicEntryByStartAddress(from)) {
                                this.codeMap_.moveCode(from, to);
                              }
                            };
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 1057..1061

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 57.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Similar blocks of code found in 4 locations. Consider refactoring.
                            Open

                            Profile.DynamicFuncCodeEntry.prototype.toString = function() {
                              return this.getName() + ': ' + this.size.toString(16);
                            };
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 3 other locations - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 508..510
                            current/deps/v8/tools/profile.js on lines 559..561
                            lts/deps/v8/tools/profile.js on lines 504..506

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 56.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Similar blocks of code found in 4 locations. Consider refactoring.
                            Open

                            Profile.DynamicCodeEntry.prototype.toString = function() {
                              return this.getName() + ': ' + this.size.toString(16);
                            };
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 3 other locations - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 508..510
                            current/deps/v8/tools/profile.js on lines 559..561
                            lts/deps/v8/tools/profile.js on lines 555..557

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 56.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.Node = function(label, opt_parent) {
                              this.label = label;
                              this.parent = opt_parent;
                              this.children = {};
                            };
                            Severity: Major
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 1 hr to fix
                            current/deps/v8/tools/profile.js on lines 748..752

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 56.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                                this.codeEntries_.push({
                                    name : entry.name,
                                    type : entry.type,
                                    kind : kind,
                                    func : func.funcId,
                            Severity: Minor
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 55 mins to fix
                            current/deps/v8/tools/profile.js on lines 966..972

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 53.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            CallTree.Node.prototype.findOrAddChild = function(label) {
                              return this.findChild(label) || this.addChild(label);
                            };
                            Severity: Minor
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 50 mins to fix
                            current/deps/v8/tools/profile.js on lines 820..822

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 52.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            JsonProfile.prototype.addScriptSource = function(script, url, source) {
                              this.scripts_[script] = {
                                name : url,
                                source : source
                              };
                            Severity: Minor
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 40 mins to fix
                            current/deps/v8/tools/profile.js on lines 1019..1024

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 49.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.DynamicFuncCodeEntry.prototype.getState = function() {
                              return Profile.DynamicFuncCodeEntry.STATE_PREFIX[this.state];
                            };
                            Severity: Minor
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 35 mins to fix
                            current/deps/v8/tools/profile.js on lines 533..535

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 47.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            Identical blocks of code found in 2 locations. Consider refactoring.
                            Open

                            Profile.DynamicCodeEntry.prototype.getName = function() {
                              return this.type + ': ' + this.name;
                            };
                            Severity: Minor
                            Found in lts/deps/v8/tools/profile.js and 1 other location - About 35 mins to fix
                            current/deps/v8/tools/profile.js on lines 490..492

                            Duplicated Code

                            Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                            Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                            When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                            Tuning

                            This issue has a mass of 47.

                            We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                            The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                            If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                            See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                            Refactorings

                            Further Reading

                            There are no issues that match your filters.

                            Category
                            Status