Commit 818ba36e authored by Zhi An Ng's avatar Zhi An Ng Committed by Commit Bot

[ia32] Consolidate anytrue instruction codes

These instructions have the same implementation in code-generator.

Bug: v8:11217
Change-Id: I06fa7eaf6360aa8f142ee1d0b36832be3a518b7b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2568920Reviewed-by: 's avatarBill Budge <bbudge@chromium.org>
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71581}
parent f6291634
......@@ -4207,9 +4207,7 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction(
__ vpor(dst, dst, kScratchDoubleReg);
break;
}
case kIA32V32x4AnyTrue:
case kIA32V16x8AnyTrue:
case kIA32V8x16AnyTrue: {
case kIA32S128AnyTrue: {
Register dst = i.OutputRegister();
XMMRegister src = i.InputSimd128Register(0);
Register tmp = i.TempRegister(0);
......
......@@ -411,11 +411,9 @@ namespace compiler {
V(AVXS8x4Reverse) \
V(SSES8x2Reverse) \
V(AVXS8x2Reverse) \
V(IA32V32x4AnyTrue) \
V(IA32S128AnyTrue) \
V(IA32V32x4AllTrue) \
V(IA32V16x8AnyTrue) \
V(IA32V16x8AllTrue) \
V(IA32V8x16AnyTrue) \
V(IA32V8x16AllTrue) \
V(IA32Word32AtomicPairLoad) \
V(IA32Word32AtomicPairStore) \
......
......@@ -380,11 +380,9 @@ int InstructionScheduler::GetTargetInstructionFlags(
case kAVXS8x4Reverse:
case kSSES8x2Reverse:
case kAVXS8x2Reverse:
case kIA32V32x4AnyTrue:
case kIA32S128AnyTrue:
case kIA32V32x4AllTrue:
case kIA32V16x8AnyTrue:
case kIA32V16x8AllTrue:
case kIA32V8x16AnyTrue:
case kIA32V8x16AllTrue:
return (instr->addressing_mode() == kMode_None)
? kNoOpcodeFlags
......
......@@ -2550,11 +2550,12 @@ SIMD_UNOP_PREFIX_LIST(VISIT_SIMD_UNOP_PREFIX)
#undef VISIT_SIMD_UNOP_PREFIX
#undef SIMD_UNOP_PREFIX_LIST
// The implementation of AnyTrue is the same for all shapes.
#define VISIT_SIMD_ANYTRUE(Opcode) \
void InstructionSelector::Visit##Opcode(Node* node) { \
IA32OperandGenerator g(this); \
InstructionOperand temps[] = {g.TempRegister()}; \
Emit(kIA32##Opcode, g.DefineAsRegister(node), \
Emit(kIA32S128AnyTrue, g.DefineAsRegister(node), \
g.UseRegister(node->InputAt(0)), arraysize(temps), temps); \
}
SIMD_ANYTRUE_LIST(VISIT_SIMD_ANYTRUE)
......
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