Bug 1205937. r=jandem, with various input from efaust as well, a=sylvestre
authorJeff Walden <jwalden@mit.edu>
Tue, 22 Sep 2015 13:54:00 -0700
changeset 296231 34f6e9cb20a6c6d716c0364c3f9e00090bbb4ac0
parent 296230 744b9efcd17d1d6589a2c46dcc3dcf83ec42fef3
child 296232 94caa265bd0b720d6d69338f5e394cd85454a4ab
push id5245
push userraliiev@mozilla.com
push dateThu, 29 Oct 2015 11:30:51 +0000
treeherdermozilla-beta@dac831dc1bd0 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjandem, with, sylvestre
bugs1205937
milestone43.0a2
Bug 1205937. r=jandem, with various input from efaust as well, a=sylvestre
js/src/jit/BaselineFrame.cpp
js/src/jit/BaselineFrame.h
--- a/js/src/jit/BaselineFrame.cpp
+++ b/js/src/jit/BaselineFrame.cpp
@@ -45,17 +45,18 @@ BaselineFrame::trace(JSTracer* trc, JitF
         TraceRoot(trc, &scopeChain_, "baseline-scopechain");
 
     // Mark return value.
     if (hasReturnValue())
         TraceRoot(trc, returnValue().address(), "baseline-rval");
 
     if (isEvalFrame()) {
         TraceRoot(trc, &evalScript_, "baseline-evalscript");
-        TraceRoot(trc, evalNewTargetAddress(), "baseline-evalNewTarget");
+        if (isFunctionFrame())
+            TraceRoot(trc, evalNewTargetAddress(), "baseline-evalNewTarget");
     }
 
     if (hasArgsObj())
         TraceRoot(trc, &argsObj_, "baseline-args-obj");
 
     // Mark locals and stack values.
     JSScript* script = this->script();
     size_t nfixed = script->nfixed();
--- a/js/src/jit/BaselineFrame.h
+++ b/js/src/jit/BaselineFrame.h
@@ -220,16 +220,17 @@ class BaselineFrame
         return (Value*)(reinterpret_cast<const uint8_t*>(this) +
                          BaselineFrame::Size() +
                          offsetOfArg(0));
     }
 
   private:
     Value* evalNewTargetAddress() const {
         MOZ_ASSERT(isEvalFrame());
+        MOZ_ASSERT(isFunctionFrame());
         return (Value*)(reinterpret_cast<const uint8_t*>(this) +
                         BaselineFrame::Size() +
                         offsetOfEvalNewTarget());
     }
 
   public:
     Value newTarget() const {
         MOZ_ASSERT(isFunctionFrame());