From b8d38fe82c2a0a1b26db4775c753fa173bc238be Mon Sep 17 00:00:00 2001 From: Yang Liu Date: Thu, 22 Feb 2024 20:51:32 +0800 Subject: [PATCH] Fixed generator for vd,vs2,vm format --- generator/insn_vdvs2vm.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/generator/insn_vdvs2vm.go b/generator/insn_vdvs2vm.go index 4761357..55340c0 100644 --- a/generator/insn_vdvs2vm.go +++ b/generator/insn_vdvs2vm.go @@ -7,6 +7,7 @@ import ( ) func (i *Insn) genCodeVdVs2Vm(pos int) []string { + float := strings.HasPrefix(i.Name, "vf") vdWidening := strings.HasPrefix(i.Name, "vfw") vdNarrowing := strings.HasPrefix(i.Name, "vfn") vdSize := iff(vdWidening, 2, 1) @@ -39,7 +40,7 @@ func (i *Insn) genCodeVdVs2Vm(pos int) []string { builder.WriteString(i.gWriteRandomData(vdEMUL1)) builder.WriteString(i.gLoadDataIntoRegisterGroup(vd, vdEMUL1, SEW(8))) - builder.WriteString(i.gWriteTestData(false, false, vs2EMUL1, vs2EEW, 0, 1)) + builder.WriteString(i.gWriteTestData(float, !i.NoTestfloat3, vs2EMUL1, vs2EEW, 0, 1)) builder.WriteString(i.gLoadDataIntoRegisterGroup(vs2, vs2EMUL1, vs2EEW)) builder.WriteString("# -------------- TEST BEGIN --------------\n")