<html>
    <head>
      <base href="https://bugs.webkit.org/" />
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - Web Inspector: Code hotness visualizer: introduce &quot;parsed: true&quot; property"
   href="https://bugs.webkit.org/show_bug.cgi?id=151470">151470</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Web Inspector: Code hotness visualizer: introduce &quot;parsed: true&quot; property
          </td>
        </tr>

        <tr>
          <th>Classification</th>
          <td>Unclassified
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>WebKit
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>WebKit Local Build
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>Normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P2
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Web Inspector
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>webkit-unassigned&#64;lists.webkit.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>nvasilyev&#64;apple.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>bburg&#64;apple.com, graouts&#64;webkit.org, joepeck&#64;webkit.org, mattbaker&#64;apple.com, nvasilyev&#64;apple.com, timothy&#64;apple.com, webkit-bug-importer&#64;group.apple.com
          </td>
        </tr>

        <tr>
          <th>Blocks</th>
          <td>146115
          </td>
        </tr></table>
      <p>
        <div>
        <pre>TL;DR
<a href="https://github.com/WebKit/webkit/blob/a7970c63ab35ad903f6060e2ba28eaf1bd562801/Source/JavaScriptCore/runtime/ControlFlowProfiler.cpp#L97">https://github.com/WebKit/webkit/blob/a7970c63ab35ad903f6060e2ba28eaf1bd562801/Source/JavaScriptCore/runtime/ControlFlowProfiler.cpp#L97</a>
Instead emitting &quot;executionCount: 1&quot; for scopes, we should introduce a separate property. We could name it &quot;parsed: true&quot; instead of &quot;executionCount: 1&quot;. I'm not sure if &quot;parsed&quot; is technically accurate, so bike-shedding is welcome.

Longer explanation:

var x = 1;
function foo() {
  return 42;
}

Upon reading executing the JS code above, one of the ranges RuntimeAgent.getBasicBlocks would emit be:

{
   startOffset: 0,
   endOffset: // end of the file
   hasExecuted: true,
   executionCount: 1
}

This is a bit misleading, since function foo hasn't been executed.

I suggest to instead emit:

{
   startOffset: 0,
   endOffset: // end of the file
   hasExecuted: true,
   parsed: true
}

Having a different property would allow to style these ranges differently.</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>