Skip to content

Commit d9b9a1f

Browse files
committed
Use same put_list_deallocate check introduced in OTP PR erlang#11299
1 parent 6850161 commit d9b9a1f

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

erts/emulator/beam/jit/arm/32/instr_common.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -687,7 +687,8 @@ void BeamModuleAssembler::emit_put_list_deallocate(const ArgSource &Hd,
687687

688688
ASSERT(Deallocate.get() <= 1023);
689689

690-
if (Hd.isYRegister() && !Tl.isYRegister() && dealloc > 0) {
690+
if (Hd.isYRegister() && !Tl.isYRegister() && dealloc > 0 &&
691+
Support::isInt9(dealloc)) {
691692
auto hd_index = Hd.as<ArgYRegister>().get();
692693

693694
if (hd_index == 0) {
@@ -696,7 +697,8 @@ void BeamModuleAssembler::emit_put_list_deallocate(const ArgSource &Hd,
696697
tl_reg = load_source(Tl, ARG2).reg;
697698
dealloc = 0;
698699
}
699-
} else if (!Hd.isYRegister() && Tl.isYRegister() && dealloc > 0) {
700+
} else if (!Hd.isYRegister() && Tl.isYRegister() && dealloc > 0 &&
701+
Support::isInt9(dealloc)) {
700702
auto tl_index = Tl.as<ArgYRegister>().get();
701703

702704
if (tl_index == 0) {

0 commit comments

Comments
 (0)