MIPS: Fix [builtins] Introduce further constant & external reference indirections

Temporary register at was rewritten. We use different register.

Change-Id: If3a162765ee29eb1d03d3f29345328cf79244e41
Reviewed-on: https://chromium-review.googlesource.com/1032616
Reviewed-by: Sreten Kovacevic <sreten.kovacevic@mips.com>
Commit-Queue: Sreten Kovacevic <sreten.kovacevic@mips.com>
Cr-Commit-Position: refs/heads/master@{#52843}
This commit is contained in:
Ivica Bogosavljevic 2018-04-27 13:20:46 +02:00 committed by Commit Bot
parent f8597b25c1
commit 443b9de184
2 changed files with 10 additions and 18 deletions

View File

@ -3782,10 +3782,8 @@ void TurboAssembler::Jump(Handle<Code> code, RelocInfo::Mode rmode,
DCHECK(RelocInfo::IsCodeTarget(rmode));
#ifdef V8_EMBEDDED_BUILTINS
if (root_array_available_ && isolate()->ShouldLoadConstantsFromRootList()) {
UseScratchRegisterScope temps(this);
Register scratch = temps.Acquire();
LookupConstant(scratch, code);
Jump(scratch, Code::kHeaderSize - kHeapObjectTag, cond, rs, rt, bd);
LookupConstant(t9, code);
Jump(t9, Code::kHeaderSize - kHeapObjectTag, cond, rs, rt, bd);
return;
}
#endif // V8_EMBEDDED_BUILTINS
@ -3942,10 +3940,8 @@ void TurboAssembler::Call(Handle<Code> code, RelocInfo::Mode rmode,
BlockTrampolinePoolScope block_trampoline_pool(this);
#ifdef V8_EMBEDDED_BUILTINS
if (root_array_available_ && isolate()->ShouldLoadConstantsFromRootList()) {
UseScratchRegisterScope temps(this);
Register scratch = temps.Acquire();
LookupConstant(scratch, code);
Call(scratch, Code::kHeaderSize - kHeapObjectTag, cond, rs, rt, bd);
LookupConstant(t9, code);
Call(t9, Code::kHeaderSize - kHeapObjectTag, cond, rs, rt, bd);
return;
}
#endif // V8_EMBEDDED_BUILTINS

View File

@ -4212,11 +4212,9 @@ void TurboAssembler::Jump(Handle<Code> code, RelocInfo::Mode rmode,
DCHECK(RelocInfo::IsCodeTarget(rmode));
#ifdef V8_EMBEDDED_BUILTINS
if (root_array_available_ && isolate()->ShouldLoadConstantsFromRootList()) {
UseScratchRegisterScope temps(this);
Register scratch = temps.Acquire();
LookupConstant(scratch, code);
Daddu(scratch, scratch, Operand(Code::kHeaderSize - kHeapObjectTag));
Jump(scratch, cond, rs, rt, bd);
LookupConstant(t9, code);
Daddu(t9, t9, Operand(Code::kHeaderSize - kHeapObjectTag));
Jump(t9, cond, rs, rt, bd);
return;
}
#endif // V8_EMBEDDED_BUILTINS
@ -4305,11 +4303,9 @@ void TurboAssembler::Call(Handle<Code> code, RelocInfo::Mode rmode,
BlockTrampolinePoolScope block_trampoline_pool(this);
#ifdef V8_EMBEDDED_BUILTINS
if (root_array_available_ && isolate()->ShouldLoadConstantsFromRootList()) {
UseScratchRegisterScope temps(this);
Register scratch = temps.Acquire();
LookupConstant(scratch, code);
Daddu(scratch, scratch, Operand(Code::kHeaderSize - kHeapObjectTag));
Call(scratch, cond, rs, rt, bd);
LookupConstant(t9, code);
Daddu(t9, t9, Operand(Code::kHeaderSize - kHeapObjectTag));
Call(t9, cond, rs, rt, bd);
return;
}
#endif // V8_EMBEDDED_BUILTINS