Commit 6cde186b authored by Deepti Gandluri's avatar Deepti Gandluri Committed by Commit Bot

[atomics] Fix I64AtomicStore/I64AtomicExchange for ia32

Change-Id: I54b34635842e62f08ff06c68b965f2e38155bad8
Bug: v8:8202
Reviewed-on: https://chromium-review.googlesource.com/c/1282932Reviewed-by: 's avatarStephan Herhut <herhut@chromium.org>
Commit-Queue: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56725}
parent 132d2672
...@@ -3678,6 +3678,8 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction( ...@@ -3678,6 +3678,8 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction(
break; break;
} }
case kIA32Word32AtomicPairStore: { case kIA32Word32AtomicPairStore: {
Label store;
__ bind(&store);
TurboAssembler::AllowExplicitEbxAccessScope spill_register(tasm()); TurboAssembler::AllowExplicitEbxAccessScope spill_register(tasm());
__ mov(i.TempRegister(0), i.MemoryOperand(2)); __ mov(i.TempRegister(0), i.MemoryOperand(2));
__ mov(i.TempRegister(1), i.NextMemoryOperand(2)); __ mov(i.TempRegister(1), i.NextMemoryOperand(2));
...@@ -3688,6 +3690,7 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction( ...@@ -3688,6 +3690,7 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction(
__ cmpxchg8b(i.MemoryOperand(2)); __ cmpxchg8b(i.MemoryOperand(2));
__ pop(ebx); __ pop(ebx);
frame_access_state()->IncreaseSPDelta(-1); frame_access_state()->IncreaseSPDelta(-1);
__ j(not_equal, &store);
break; break;
} }
case kWord32AtomicExchangeInt8: { case kWord32AtomicExchangeInt8: {
...@@ -3716,6 +3719,8 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction( ...@@ -3716,6 +3719,8 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction(
} }
case kIA32Word32AtomicPairExchange: { case kIA32Word32AtomicPairExchange: {
DCHECK(VerifyOutputOfAtomicPairInstr(&i, instr)); DCHECK(VerifyOutputOfAtomicPairInstr(&i, instr));
Label exchange;
__ bind(&exchange);
TurboAssembler::AllowExplicitEbxAccessScope spill_ebx(tasm()); TurboAssembler::AllowExplicitEbxAccessScope spill_ebx(tasm());
__ mov(eax, i.MemoryOperand(2)); __ mov(eax, i.MemoryOperand(2));
__ mov(edx, i.NextMemoryOperand(2)); __ mov(edx, i.NextMemoryOperand(2));
...@@ -3726,6 +3731,7 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction( ...@@ -3726,6 +3731,7 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction(
__ cmpxchg8b(i.MemoryOperand(2)); __ cmpxchg8b(i.MemoryOperand(2));
__ pop(ebx); __ pop(ebx);
frame_access_state()->IncreaseSPDelta(-1); frame_access_state()->IncreaseSPDelta(-1);
__ j(not_equal, &exchange);
break; break;
} }
case kWord32AtomicCompareExchangeInt8: { case kWord32AtomicCompareExchangeInt8: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment