Skip to content

Commit 7b046d0

Browse files
Junliang YanCommit Bot
authored andcommitted
Reland "PPC/s390: [interpreter] correctly advance over debug scaling prefixes."
This is a reland of dfdc313 Original change's description: > PPC/s390: [interpreter] correctly advance over debug scaling prefixes. > > Port 7a07d74 > > [email protected], [email protected], [email protected] > BUG= > LOG=N > > Change-Id: I99553fde819cbdc8a12df5b82d9d7230ba4ef8b3 > Reviewed-on: https://chromium-review.googlesource.com/1042355 > Commit-Queue: Junliang Yan <[email protected]> > Reviewed-by: Joran Siu <[email protected]> > Cr-Commit-Position: refs/heads/master@{#52970} Change-Id: I012e79ef5fbff37a8ded8c8cf5d4aaf324cd6ccb Reviewed-on: https://chromium-review.googlesource.com/1043026 Reviewed-by: Joran Siu <[email protected]> Commit-Queue: Junliang Yan <[email protected]> Cr-Commit-Position: refs/heads/master@{#52972}
1 parent 5919d34 commit 7b046d0

2 files changed

Lines changed: 12 additions & 4 deletions

File tree

src/builtins/ppc/builtins-ppc.cc

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -859,9 +859,13 @@ static void AdvanceBytecodeOffsetOrReturn(MacroAssembler* masm,
859859
Label process_bytecode, extra_wide;
860860
STATIC_ASSERT(0 == static_cast<int>(interpreter::Bytecode::kWide));
861861
STATIC_ASSERT(1 == static_cast<int>(interpreter::Bytecode::kExtraWide));
862-
__ cmpi(bytecode, Operand(0x1));
862+
STATIC_ASSERT(2 == static_cast<int>(interpreter::Bytecode::kDebugBreakWide));
863+
STATIC_ASSERT(3 ==
864+
static_cast<int>(interpreter::Bytecode::kDebugBreakExtraWide));
865+
__ cmpi(bytecode, Operand(0x3));
863866
__ bgt(&process_bytecode);
864-
__ beq(&extra_wide);
867+
__ andi(r0, bytecode, Operand(0x1));
868+
__ bne(&extra_wide, cr0);
865869

866870
// Load the next bytecode and update table to the wide scaled table.
867871
__ addi(bytecode_offset, bytecode_offset, Operand(1));

src/builtins/s390/builtins-s390.cc

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -869,9 +869,13 @@ static void AdvanceBytecodeOffsetOrReturn(MacroAssembler* masm,
869869
Label process_bytecode, extra_wide;
870870
STATIC_ASSERT(0 == static_cast<int>(interpreter::Bytecode::kWide));
871871
STATIC_ASSERT(1 == static_cast<int>(interpreter::Bytecode::kExtraWide));
872-
__ CmpP(bytecode, Operand(0x1));
872+
STATIC_ASSERT(2 == static_cast<int>(interpreter::Bytecode::kDebugBreakWide));
873+
STATIC_ASSERT(3 ==
874+
static_cast<int>(interpreter::Bytecode::kDebugBreakExtraWide));
875+
__ CmpP(bytecode, Operand(0x3));
873876
__ bgt(&process_bytecode);
874-
__ beq(&extra_wide);
877+
__ tmll(bytecode, Operand(0x1));
878+
__ bne(&extra_wide);
875879

876880
// Load the next bytecode and update table to the wide scaled table.
877881
__ AddP(bytecode_offset, bytecode_offset, Operand(1));

0 commit comments

Comments
 (0)