Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(127)

Unified Diff: src/compiler/x64/code-generator-x64.cc

Issue 2849463003: [wasm] Implement Generic S128 Load/Store, logical ops and Horizontal add (Closed)
Patch Set: Zvi's review Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler/instruction-selector.cc ('k') | src/compiler/x64/instruction-codes-x64.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/x64/code-generator-x64.cc
diff --git a/src/compiler/x64/code-generator-x64.cc b/src/compiler/x64/code-generator-x64.cc
index 72dc78f24b53cf3c1a30d95bb3b85b071dc38873..86c547f460b6803ddd3dc75438b7ecb5204f6061 100644
--- a/src/compiler/x64/code-generator-x64.cc
+++ b/src/compiler/x64/code-generator-x64.cc
@@ -2006,6 +2006,19 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction(
__ Movsd(operand, i.InputDoubleRegister(index));
}
break;
+ case kX64Movdqu: {
+ CpuFeatureScope sse_scope(masm(), SSSE3);
+ EmitOOLTrapIfNeeded(zone(), this, opcode, instr->InputCount(), i,
+ __ pc_offset());
+ if (instr->HasOutput()) {
+ __ movdqu(i.OutputSimd128Register(), i.MemoryOperand());
+ } else {
+ size_t index = 0;
+ Operand operand = i.MemoryOperand(&index);
+ __ movdqu(operand, i.InputSimd128Register(index));
+ }
+ break;
+ }
case kX64BitcastFI:
if (instr->InputAt(0)->IsFPStackSlot()) {
__ movl(i.OutputRegister(), i.InputOperand(0));
@@ -2187,6 +2200,11 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction(
__ paddd(i.OutputSimd128Register(), i.InputSimd128Register(1));
break;
}
+ case kX64I32x4AddHoriz: {
+ CpuFeatureScope sse_scope(masm(), SSSE3);
+ __ phaddd(i.OutputSimd128Register(), i.InputSimd128Register(1));
+ break;
+ }
case kX64I32x4Sub: {
__ psubd(i.OutputSimd128Register(), i.InputSimd128Register(1));
break;
@@ -2276,6 +2294,11 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction(
__ paddsw(i.OutputSimd128Register(), i.InputSimd128Register(1));
break;
}
+ case kX64I16x8AddHoriz: {
+ CpuFeatureScope sse_scope(masm(), SSSE3);
+ __ phaddw(i.OutputSimd128Register(), i.InputSimd128Register(1));
+ break;
+ }
case kX64I16x8Sub: {
__ psubw(i.OutputSimd128Register(), i.InputSimd128Register(1));
break;
@@ -2410,6 +2433,24 @@ CodeGenerator::CodeGenResult CodeGenerator::AssembleArchInstruction(
__ pmaxub(i.OutputSimd128Register(), i.InputSimd128Register(1));
break;
}
+ case kX64S128And: {
+ __ pand(i.OutputSimd128Register(), i.InputSimd128Register(1));
+ break;
+ }
+ case kX64S128Or: {
+ __ por(i.OutputSimd128Register(), i.InputSimd128Register(1));
+ break;
+ }
+ case kX64S128Xor: {
+ __ pxor(i.OutputSimd128Register(), i.InputSimd128Register(1));
+ break;
+ }
+ case kX64S128Not: {
+ XMMRegister dst = i.OutputSimd128Register();
+ __ pcmpeqd(dst, dst);
+ __ pxor(dst, i.InputSimd128Register(1));
+ break;
+ }
case kX64S128Select: {
// Mask used here is stored in dst.
XMMRegister dst = i.OutputSimd128Register();
« no previous file with comments | « src/compiler/instruction-selector.cc ('k') | src/compiler/x64/instruction-codes-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698