title: Getting the CPU time in JavaScript
body: <p>Is there a way to get the time a piece of JavaScript actually runs on the CPU, like with the <code>clock()</code> and <code>getrusage()</code> functions in C? Using the normal <code>Date()</code> way only gives the wall time, and for performance measurements the CPU time would be much more useful.</p>
  
  <p>Note that I'm not looking for profiling tools, I want to reduce system noise for automated testing and not optimize specific functions.</p>