From 054549da3537e206c80c046903de39246c370a3d Mon Sep 17 00:00:00 2001 From: Lioncash Date: Mon, 14 May 2018 23:02:38 -0400 Subject: [PATCH] emit_x64_vector: Simplify AVX-512 codepath in EmitVectorMultiply64 I realized I introduced a helper for simple AVX operation emitting, so use that instead of writing it all out long-form. --- src/backend_x64/emit_x64_vector.cpp | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/backend_x64/emit_x64_vector.cpp b/src/backend_x64/emit_x64_vector.cpp index cb209197..610a340e 100644 --- a/src/backend_x64/emit_x64_vector.cpp +++ b/src/backend_x64/emit_x64_vector.cpp @@ -1460,13 +1460,7 @@ void EmitX64::EmitVectorMultiply32(EmitContext& ctx, IR::Inst* inst) { void EmitX64::EmitVectorMultiply64(EmitContext& ctx, IR::Inst* inst) { if (code.DoesCpuSupport(Xbyak::util::Cpu::tAVX512DQ) && code.DoesCpuSupport(Xbyak::util::Cpu::tAVX512VL)) { - auto args = ctx.reg_alloc.GetArgumentInfo(inst); - const Xbyak::Xmm a = ctx.reg_alloc.UseScratchXmm(args[0]); - const Xbyak::Xmm b = ctx.reg_alloc.UseXmm(args[1]); - - code.vpmullq(a, a, b); - - ctx.reg_alloc.DefineValue(inst, a); + EmitAVXVectorOperation(code, ctx, inst, &Xbyak::CodeGenerator::vpmullq); return; }