Bug 1656552 - Fix CacheIRHealth report spewer to account for arglength. r=iain
authorcaroline <ccullen@mozilla.com>
Tue, 04 Aug 2020 16:03:40 +0000
changeset 543426 bf19c3693cc521d5f935d1e835013cfc6f100ad8
parent 543425 07812e460d4fb872b449198bfcb1099095099c20
child 543427 f724e2961c5eda2057c57e42298b89a69d89ddda
push id37673
push userapavel@mozilla.com
push dateWed, 05 Aug 2020 21:44:54 +0000
treeherdermozilla-central@26de281d4c21 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersiain
bugs1656552
milestone81.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1656552 - Fix CacheIRHealth report spewer to account for arglength. r=iain Differential Revision: https://phabricator.services.mozilla.com/D85805
js/src/jit/CacheIRHealth.cpp
--- a/js/src/jit/CacheIRHealth.cpp
+++ b/js/src/jit/CacheIRHealth.cpp
@@ -13,25 +13,30 @@
 
 using namespace js;
 using namespace js::jit;
 
 bool CacheIRHealth::spewStubHealth(AutoStructuredSpewer& spew, ICStub* stub) {
   const CacheIRStubInfo* stubInfo = stub->cacheIRStubInfo();
   CacheIRReader stubReader(stubInfo);
   uint32_t totalStubHealth = 0;
+
   while (stubReader.more()) {
     CacheOp op = stubReader.readOp();
     uint32_t opHealth = CacheIROpHealth[size_t(op)];
+    uint32_t argLength = CacheIROpArgLengths[size_t(op)];
+
     if (opHealth == UINT32_MAX) {
       const char* opName = CacheIROpNames[size_t(op)];
       spew->property("unscoredOp", opName);
     } else {
       totalStubHealth += opHealth;
     }
+
+    stubReader.skip(argLength);
   }
 
   spew->property("stubHealth", totalStubHealth);
   return true;
 }
 
 bool CacheIRHealth::spewHealthForStubsInCacheIREntry(AutoStructuredSpewer& spew,
                                                      ICEntry* entry) {