Bug 1022891 - Part 2: Teach IonBailoutIterator about PJS scripts. (r=nbp)

This commit is contained in:
Shu-yu Guo 2014-06-12 12:46:17 -07:00
parent 496e463f68
commit a09ed4d7c2
5 changed files with 28 additions and 5 deletions

View File

@ -1698,7 +1698,14 @@ JitFrameIterator::ionScriptFromCalleeToken() const
switch (GetCalleeTokenTag(calleeToken())) {
case CalleeToken_Function:
case CalleeToken_Script:
return mode_ == ParallelExecution ? script()->parallelIonScript() : script()->ionScript();
switch (mode_) {
case SequentialExecution:
return script()->ionScript();
case ParallelExecution:
return script()->parallelIonScript();
default:
MOZ_ASSUME_UNREACHABLE("No such execution mode");
}
default:
MOZ_ASSUME_UNREACHABLE("unknown callee token type");
}

View File

@ -79,7 +79,11 @@ IonBailoutIterator::IonBailoutIterator(const JitActivationIterator &activations,
current_ = fp;
type_ = JitFrame_IonJS;
topFrameSize_ = current_ - sp;
topIonScript_ = script()->ionScript();
switch (mode_) {
case SequentialExecution: topIonScript_ = script()->ionScript(); break;
case ParallelExecution: topIonScript_ = script()->parallelIonScript(); break;
default: MOZ_ASSUME_UNREACHABLE("No such execution mode");
}
if (bailout->frameClass() == FrameSizeClass::None()) {
snapshotOffset_ = bailout->snapshotOffset();

View File

@ -23,7 +23,11 @@ IonBailoutIterator::IonBailoutIterator(const JitActivationIterator &activations,
current_ = fp;
type_ = JitFrame_IonJS;
topFrameSize_ = current_ - sp;
topIonScript_ = script()->ionScript();
switch (mode_) {
case SequentialExecution: topIonScript_ = script()->ionScript(); break;
case ParallelExecution: topIonScript_ = script()->parallelIonScript(); break;
default: MOZ_ASSUME_UNREACHABLE("No such execution mode");
}
if (bailout->frameClass() == FrameSizeClass::None()) {
snapshotOffset_ = bailout->snapshotOffset();

View File

@ -56,7 +56,11 @@ IonBailoutIterator::IonBailoutIterator(const JitActivationIterator &activations,
current_ = fp;
type_ = JitFrame_IonJS;
topFrameSize_ = current_ - sp;
topIonScript_ = script()->ionScript();
switch (mode_) {
case SequentialExecution: topIonScript_ = script()->ionScript(); break;
case ParallelExecution: topIonScript_ = script()->parallelIonScript(); break;
default: MOZ_ASSUME_UNREACHABLE("No such execution mode");
}
snapshotOffset_ = bailout->snapshotOffset();
}

View File

@ -76,7 +76,11 @@ IonBailoutIterator::IonBailoutIterator(const JitActivationIterator &activations,
current_ = fp;
type_ = JitFrame_IonJS;
topFrameSize_ = current_ - sp;
topIonScript_ = script()->ionScript();
switch (mode_) {
case SequentialExecution: topIonScript_ = script()->ionScript(); break;
case ParallelExecution: topIonScript_ = script()->parallelIonScript(); break;
default: MOZ_ASSUME_UNREACHABLE("No such execution mode");
}
if (bailout->frameClass() == FrameSizeClass::None()) {
snapshotOffset_ = bailout->snapshotOffset();