8287425: Remove unnecessary register push for MacroAssembler::check_klass_subtype_slow_path

Co-authored-by: Wei Kuai <kuaiwei.kw@alibaba-inc.com>
Reviewed-by: kvn
This commit is contained in:
Xiaolin Zheng 2022-06-02 20:31:26 +00:00 committed by Vladimir Kozlov
parent 26048ea21e
commit b5a646ee6c
3 changed files with 3 additions and 3 deletions

@ -1125,7 +1125,7 @@ void MacroAssembler::check_klass_subtype_slow_path(Register sub_klass,
if (!IS_A_TEMP(r2)) pushed_registers += r2;
if (!IS_A_TEMP(r5)) pushed_registers += r5;
if (super_klass != r0 || UseCompressedOops) {
if (super_klass != r0) {
if (!IS_A_TEMP(r0)) pushed_registers += r0;
}

@ -2624,7 +2624,7 @@ void MacroAssembler::check_klass_subtype_slow_path(Register sub_klass,
pushed_registers += x15;
}
if (super_klass != x10 || UseCompressedOops) {
if (super_klass != x10) {
if (!IS_A_TEMP(x10)) {
pushed_registers += x10;
}

@ -4163,7 +4163,7 @@ void MacroAssembler::check_klass_subtype_slow_path(Register sub_klass,
// Get super_klass value into rax (even if it was in rdi or rcx).
bool pushed_rax = false, pushed_rcx = false, pushed_rdi = false;
if (super_klass != rax || UseCompressedOops) {
if (super_klass != rax) {
if (!IS_A_TEMP(rax)) { push(rax); pushed_rax = true; }
mov(rax, super_klass);
}