mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 21:31:04 +00:00
Bug 1766225: Save volatile output register before calling post-write barrier. r=jandem
Differential Revision: https://phabricator.services.mozilla.com/D144549
This commit is contained in:
parent
9c9a7d440b
commit
4fba387fcc
12
js/src/jit-test/tests/auto-regress/bug1766225.js
Normal file
12
js/src/jit-test/tests/auto-regress/bug1766225.js
Normal file
@ -0,0 +1,12 @@
|
||||
// |jit-test| --ion-offthread-compile=off; --ion-warmup-threshold=1; --ion-gvn=off
|
||||
|
||||
gczeal(4)
|
||||
function a() {}
|
||||
function b() {
|
||||
a(Array.prototype.slice.call(arguments, 1, 3));
|
||||
}
|
||||
function c() {
|
||||
b(1, 2);
|
||||
}
|
||||
for (i=0 ; i<200; ++i)
|
||||
c()
|
@ -11747,6 +11747,9 @@ void CodeGenerator::visitFrameArgumentsSlice(LFrameArgumentsSlice* lir) {
|
||||
|
||||
LiveRegisterSet volatileRegs = liveVolatileRegs(lir);
|
||||
volatileRegs.takeUnchecked(temp);
|
||||
if (output.volatile_()) {
|
||||
volatileRegs.addUnchecked(output);
|
||||
}
|
||||
|
||||
masm.PushRegsInMask(volatileRegs);
|
||||
emitPostWriteBarrier(output);
|
||||
@ -11916,6 +11919,9 @@ void CodeGenerator::visitInlineArgumentsSlice(LInlineArgumentsSlice* lir) {
|
||||
|
||||
LiveRegisterSet volatileRegs = liveVolatileRegs(lir);
|
||||
volatileRegs.takeUnchecked(temp);
|
||||
if (output.volatile_()) {
|
||||
volatileRegs.addUnchecked(output);
|
||||
}
|
||||
|
||||
masm.PushRegsInMask(volatileRegs);
|
||||
emitPostWriteBarrier(output);
|
||||
|
Loading…
Reference in New Issue
Block a user