예제 #1
0
 public override void GenerateX86GccAsm(StringBuilder sb)
 {
     string[] setMxcsrInstrs = new string[2];
     setMxcsrInstrs[0] = "  mov $0x1f80, %r15\n  mov %r15, (%r8)\n  ldmxcsr (%r8)\n  addss %xmm0, %xmm1"; // default
     setMxcsrInstrs[1] = "  mov $0x9fc0, %r15\n  mov %r15, (%r8)\n  ldmxcsr (%r8)\n  addss %xmm0, %xmm1"; // set denormals are zero, flush to zero
     UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, setMxcsrInstrs, setMxcsrInstrs, false);
 }
예제 #2
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string initInstrs = "  vmovups (%r8), %ymm1\n" +
                                "  vmovaps %ymm1, %ymm0\n" +
                                "  vmovaps %ymm1, %ymm2\n" +
                                "  vaddps %ymm1, %ymm2, %ymm3\n" +
                                "  vaddps %ymm1, %ymm3, %ymm4\n" +
                                "  vaddps %ymm1, %ymm4, %ymm5\n" +
                                "  vaddps %ymm1, %ymm5, %ymm6\n" +
                                "  vaddps %ymm1, %ymm1, %ymm7\n" +
                                "  vaddps %ymm1, %ymm2, %ymm8\n" +
                                "  vaddps %ymm1, %ymm3, %ymm9\n" +
                                "  vaddps %ymm2, %ymm4, %ymm10\n" +
                                "  vaddps %ymm2, %ymm5, %ymm11\n" +
                                "  vaddps %ymm2, %ymm1, %ymm12\n" +
                                "  vaddps %ymm2, %ymm2, %ymm13\n" +
                                "  vaddps %ymm2, %ymm3, %ymm14\n" +
                                "  vaddps %ymm2, %ymm4, %ymm15\n";

            string postLoadInstr = "  vaddps %ymm1, %ymm2, %ymm3";

            string[] unrolledAdds = new string[11];
            unrolledAdds[0]  = "  add %r11, %r8";
            unrolledAdds[1]  = "  add %r11, %r14";
            unrolledAdds[2]  = "  add %r11, %r13";
            unrolledAdds[3]  = "  add %r11, %r12";
            unrolledAdds[4]  = "  add %r11, %r15";
            unrolledAdds[5]  = "  add %r11, %r8";
            unrolledAdds[6]  = "  add %r11, %r14";
            unrolledAdds[7]  = "  add %r11, %r13";
            unrolledAdds[8]  = "  add %r11, %r15";
            unrolledAdds[9]  = "  add %r11, %r12";
            unrolledAdds[10] = "  add %r11, %r8";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledAdds, unrolledAdds, true, initInstrs: initInstrs, postLoadInstrs1: postLoadInstr, postLoadInstrs2: postLoadInstr);
        }
예제 #3
0
 public override void GenerateX86GccAsm(StringBuilder sb)
 {
     string[] instrs = new string[4];
     instrs[0] = "  mov %r15, (%r8)";
     instrs[1] = "  mov (%rdx), %r14";
     instrs[2] = "  mov %r13, (%r8)";
     instrs[3] = "  mov (%rdx), %r12";
     UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, instrs, instrs, true);
 }
예제 #4
0
 public override void GenerateX86GccAsm(StringBuilder sb)
 {
     string[] unrolledLoads = new string[4];
     unrolledLoads[0] = "  mov %r15, (%r8)";
     unrolledLoads[1] = "  mov %r14, (%r8)";
     unrolledLoads[2] = "  mov %r13, (%r8)";
     unrolledLoads[3] = "  mov %r12, (%r8)";
     UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledLoads, unrolledLoads, true);
 }
예제 #5
0
 public override void GenerateX86GccAsm(StringBuilder sb)
 {
     string[] unrolledAdds = new string[4];
     unrolledAdds[0] = "  not %r15";
     unrolledAdds[1] = "  not %r14";
     unrolledAdds[2] = "  not %r13";
     unrolledAdds[3] = "  not %r12";
     UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledAdds, unrolledAdds, true);
 }
예제 #6
0
 public override void GenerateX86GccAsm(StringBuilder sb)
 {
     string[] unrolledAdds = new string[4];
     unrolledAdds[0] = "  kaddb %k0, %k1, %k1";
     unrolledAdds[1] = "  kaddb %k0, %k2, %k2";
     unrolledAdds[2] = "  kaddb %k0, %k3, %k3";
     unrolledAdds[3] = "  kaddb %k0, %k4, %k4";
     UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledAdds, unrolledAdds, false);
 }
예제 #7
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string postLoadInstr1 = "  mov %rdi, %r15";
            string postLoadInstr2 = "  mov %rsi, %r15";

            string[] rors = new string[1];
            rors[0] = "  ror $1, %r15";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, rors, rors, false, postLoadInstrs1: postLoadInstr1, postLoadInstrs2: postLoadInstr2);
        }
예제 #8
0
 public override void GenerateX86GccAsm(StringBuilder sb)
 {
     string[] instrs1 = new string[2];
     instrs1[0] = "  bts %rdi, %r15";
     instrs1[1] = "  imul %edi, %r12d";
     string[] instrs2 = new string[2];
     instrs2[0] = "  bts %rdi, %r15";
     instrs2[1] = "  imul %esi, %r11d";
     UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, instrs1, instrs1, false);
 }
예제 #9
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string[] unrolledJumps = new string[1];
            unrolledJumps[0] = $"  cmp %rdi, %rsi\n  je jumpsched_reallybadthing";

            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledJumps, unrolledJumps, false);

            sb.AppendLine("jumpsched_reallybadthing:");
            sb.AppendLine("  int3");
        }
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string postLoadInstr1 = "  mov %rdi, %r15";
            string postLoadInstr2 = "  mov %rsi, %r15";

            string[] instrs1 = new string[2];
            instrs1[0] = "  ror $1, %r15";
            instrs1[1] = "  imul %edi, %r12d";
            string[] instrs2 = new string[2];
            instrs2[0] = "  ror $1, %r15";
            instrs2[1] = "  imul %esi, %r11d";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, instrs1, instrs1, false, postLoadInstrs1: postLoadInstr1, postLoadInstrs2: postLoadInstr2);
        }
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string postLoadInstr1 = "  movups (%rdx, %rdi, 2), %xmm1";
            string postLoadInstr2 = "  movups (%rdx, %rsi, 2), %xmm1";

            string[] dependentStores = new string[4];
            dependentStores[0] = "  movups %xmm1, (%r8)";
            dependentStores[1] = "  movups %xmm1, (%r8, %r14, 8)";
            dependentStores[2] = "  movups %xmm1, (%r8, %r13, 8)";
            dependentStores[3] = "  movups %xmm1, (%r8, %r12, 8)";

            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, dependentStores, dependentStores, false, postLoadInstrs1: postLoadInstr1, postLoadInstrs2: postLoadInstr2);
        }
예제 #12
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string postLoadInstr1 = "  mov %rdi, %r15";
            string postLoadInstr2 = "  mov %rsi, %r15";

            string[] instrs = new string[4];
            instrs[0] = "  bts %r14, %r15";
            instrs[1] = "  bts %r13, %r15";
            instrs[2] = "  bts %r12, %r15";
            instrs[3] = "  bts %r11, %r15";

            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, instrs, instrs, false, postLoadInstrs1: postLoadInstr1, postLoadInstrs2: postLoadInstr2);
        }
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string postLoadInstr1 = "  movq %rdi, %xmm0\n  vpbroadcastd %xmm0, %ymm0\n";
            string postLoadInstr2 = "  movq %rsi, %xmm0\n  vpbroadcastd %xmm0, %ymm0\n";

            // ymm0 is dependent on ptr chasing load
            string[] unrolledAdds = new string[4];
            unrolledAdds[0] = "  vpaddd %ymm0, %ymm1, %ymm1";
            unrolledAdds[1] = "  vpaddd %ymm0, %ymm2, %ymm2";
            unrolledAdds[2] = "  vpaddd %ymm0, %ymm3, %ymm3";
            unrolledAdds[3] = "  vpaddd %ymm0, %ymm4, %ymm3";

            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledAdds, unrolledAdds, false, postLoadInstrs1: postLoadInstr1, postLoadInstrs2: postLoadInstr2);
        }
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string postLoadInstr1 = "  add %rdi, %r11";
            string postLoadInstr2 = "  add %rsi, %r11";

            string[] unrolledJumps = new string[2];
            unrolledJumps[0] = $"  cmp %rdi, %rsi\n  je jumpsched_reallybadthing_jadd";
            unrolledJumps[1] = "  add %r11, %r15";

            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledJumps, unrolledJumps, false, postLoadInstrs1: postLoadInstr1, postLoadInstrs2: postLoadInstr2);

            sb.AppendLine("jumpsched_reallybadthing_jadd:");
            sb.AppendLine("  int3");
        }
예제 #15
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string[] unrolledMuls = new string[4];
            unrolledMuls[0] = "  imul %rdi, %r15";
            unrolledMuls[1] = "  imul %rdi, %r14";
            unrolledMuls[2] = "  imul %rdi, %r13";
            unrolledMuls[3] = "  imul %rdi, %r12";

            string[] unrolledMuls1 = new string[4];
            unrolledMuls1[0] = "  imul %rsi, %r15";
            unrolledMuls1[1] = "  imul %rsi, %r14";
            unrolledMuls1[2] = "  imul %rsi, %r13";
            unrolledMuls1[3] = "  imul %rsi, %r12";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledMuls, unrolledMuls1, false);
        }
예제 #16
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string[] dependentLoads = new string[4];
            dependentLoads[0] = "  mov (%r8, %rdi, 4), %r15";
            dependentLoads[1] = "  mov (%r8, %rdi, 4), %r14";
            dependentLoads[2] = "  mov (%r8, %rdi, 4), %r13";
            dependentLoads[3] = "  mov (%r8, %rdi, 4), %r12";

            string[] dependentLoads1 = new string[4];
            dependentLoads1[0] = "  mov (%r8, %rsi, 4), %r15";
            dependentLoads1[1] = "  mov (%r8, %rsi, 4), %r14";
            dependentLoads1[2] = "  mov (%r8, %rsi, 4), %r13";
            dependentLoads1[3] = "  mov (%r8, %rsi, 4), %r12";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, dependentLoads, dependentLoads1, false);
        }
예제 #17
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string[] unrolledInstrs = new string[4];
            unrolledInstrs[0] = "  cvtsi2ss %rdi, %xmm1";
            unrolledInstrs[1] = "  cvtsi2ss %rdi, %xmm2";
            unrolledInstrs[2] = "  cvtsi2ss %rdi, %xmm3";
            unrolledInstrs[3] = "  cvtsi2ss %rdi, %xmm4";

            string[] unrolledInstrs1 = new string[4];
            unrolledInstrs1[0] = "  cvtsi2ss %rsi, %xmm1";
            unrolledInstrs1[1] = "  cvtsi2ss %rsi, %xmm2";
            unrolledInstrs1[2] = "  cvtsi2ss %rsi, %xmm3";
            unrolledInstrs1[3] = "  cvtsi2ss %rsi, %xmm4";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledInstrs, unrolledInstrs, false);
        }
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string[] ops1 = new string[4];
            ops1[0] = "  mov (%rdx, %rdi, 4), %r15";
            ops1[1] = "  mov %r11, (%r8, %rdi, 4)";
            ops1[2] = "  mov (%rdx, %rdi, 4), %r13";
            ops1[3] = "  mov %r11, (%r8, %rdi)";

            string[] ops2 = new string[4];
            ops2[0] = "  mov (%rdx, %rsi, 4), %r15";
            ops2[1] = "  mov %r11, (%r8, %rsi, 4)";
            ops2[2] = "  mov (%rdx, %rsi, 4), %r13";
            ops2[3] = "  mov %r11, (%r8, %rsi)";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, ops1, ops2, true);
        }
예제 #19
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string initInstrs = "  movss (%r8), %xmm1\n" +
                                "  movss 4(%r8), %xmm2\n" +
                                "  movss 8(%r8), %xmm3\n" +
                                "  movss 12(%r8), %xmm4\n" +
                                "  movss 16(%r8), %xmm5\n";

            string[] unrolledAdds = new string[4];
            unrolledAdds[0] = "  addss %xmm1, %xmm2";
            unrolledAdds[1] = "  addss %xmm1, %xmm3";
            unrolledAdds[2] = "  addss %xmm1, %xmm4";
            unrolledAdds[3] = "  addss %xmm1, %xmm5";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledAdds, unrolledAdds, false, initInstrs);
        }
예제 #20
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string[] instrs1 = new string[4];
            instrs1[0] = "  pdep %rdi, %r14, %r15";
            instrs1[1] = "  pdep %rdi, %r13, %r15";
            instrs1[2] = "  pdep %rdi, %r12, %r15";
            instrs1[3] = "  pdep %rdi, %r11, %r15";

            string[] instrs2 = new string[4];
            instrs2[0] = "  pdep %rsi, %r14, %r15";
            instrs2[1] = "  pdep %rsi, %r13, %r15";
            instrs2[2] = "  pdep %rsi, %r12, %r15";
            instrs2[3] = "  pdep %rsi, %r11, %r15";

            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, instrs1, instrs1, false);
        }
예제 #21
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            // it's ok, the ptr chasing arr should be way bigger than this
            string initInstrs = "  vmovups (%r8), %ymm1\n" +
                                "  vmovups 32(%r8), %ymm2\n" +
                                "  vmovups 64(%r8), %ymm3\n" +
                                "  vmovups 96(%r8), %ymm4\n" +
                                "  vmovups 128(%r8), %ymm5\n";

            string[] unrolledAdds = new string[4];
            unrolledAdds[0] = "  vaddps %ymm1, %ymm2, %ymm2";
            unrolledAdds[1] = "  vaddps %ymm1, %ymm3, %ymm3";
            unrolledAdds[2] = "  vaddps %ymm1, %ymm4, %ymm4";
            unrolledAdds[3] = "  vaddps %ymm1, %ymm5, %ymm5";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledAdds, unrolledAdds, false, initInstrs);
        }
예제 #22
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string initInstrs = "  vmovdqu (%r8), %ymm0\n" +
                                "  vmovdqa %ymm0, %ymm1\n" +
                                "  vmovdqa %ymm0, %ymm2\n" +
                                "  vmovdqa %ymm0, %ymm3\n" +
                                "  vmovdqa %ymm0, %ymm4\n";

            string[] unrolledAdds = new string[4];
            unrolledAdds[0] = "  vpaddd %ymm0, %ymm1, %ymm1";
            unrolledAdds[1] = "  vpaddd %ymm0, %ymm2, %ymm2";
            unrolledAdds[2] = "  vpaddd %ymm0, %ymm3, %ymm3";
            unrolledAdds[3] = "  vpaddd %ymm0, %ymm4, %ymm3";

            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledAdds, unrolledAdds, initInstrs: initInstrs);
        }
예제 #23
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string initInstrs = "  movq (%rdx), %mm0\n" +
                                "  movq 8(%rdx), %mm1\n" +
                                "  movq 16(%rdx), %mm2\n" +
                                "  movq 24(%rdx), %mm3\n" +
                                "  movq 32(%rdx), %mm4\n";

            string[] unrolledAdds = new string[4];
            unrolledAdds[0] = "  paddw %mm0, %mm1";
            unrolledAdds[1] = "  paddw %mm0, %mm2";
            unrolledAdds[2] = "  paddw %mm0, %mm3";
            unrolledAdds[3] = "  paddw %mm0, %mm4";

            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledAdds, unrolledAdds, initInstrs: initInstrs);
        }
예제 #24
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            // it's ok, the ptr chasing arr should be way bigger than this
            string initInstrs = "  movdqu (%rdx), %xmm1\n" +
                                "  movdqu 16(%rdx), %xmm2\n" +
                                "  movdqu 32(%rdx), %xmm3\n" +
                                "  movdqu 48(%rdx), %xmm4\n" +
                                "  movdqu 64(%rdx), %xmm5\n";

            string[] unrolledAdds = new string[4];
            unrolledAdds[0] = "  paddq %xmm1, %xmm2";
            unrolledAdds[1] = "  paddq %xmm1, %xmm3";
            unrolledAdds[2] = "  paddq %xmm1, %xmm4";
            unrolledAdds[3] = "  paddq %xmm1, %xmm5";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledAdds, unrolledAdds, false, initInstrs);
        }
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string resetMulsInstr = "mov $1, %r15\n  mov $1, %r13";

            string[] unrolledMuls = new string[4];
            unrolledMuls[0] = "  imul %di, %r15w";
            unrolledMuls[1] = "  imul %rdi, %r14";
            unrolledMuls[2] = "  imul %di, %r13w";
            unrolledMuls[3] = "  imul %rdi, %r12";

            string[] unrolledMuls1 = new string[4];
            unrolledMuls1[0] = "  imul %si, %r15w";
            unrolledMuls1[1] = "  imul %rsi, %r14";
            unrolledMuls1[2] = "  imul %si, %r13w";
            unrolledMuls1[3] = "  imul %rsi, %r12";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledMuls, unrolledMuls1, false, postLoadInstrs1: resetMulsInstr, postLoadInstrs2: resetMulsInstr);
        }
예제 #26
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            // trying to unsuccessfully counter some weird behavior on zhaoxin
            string resetMulsInstr = "mov $11, %r15\n  mov $13, %r14\n  mov $15, %r13\n  mov $17, %r12\n";

            string[] unrolledMuls = new string[4];
            unrolledMuls[0] = "  imul %edi, %r15d";
            unrolledMuls[1] = "  imul %edi, %r14d";
            unrolledMuls[2] = "  imul %edi, %r13d";
            unrolledMuls[3] = "  imul %edi, %r12d";

            string[] unrolledMuls1 = new string[4];
            unrolledMuls1[0] = "  imul %esi, %r15d";
            unrolledMuls1[1] = "  imul %esi, %r14d";
            unrolledMuls1[2] = "  imul %esi, %r13d";
            unrolledMuls1[3] = "  imul %esi, %r12d";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledMuls, unrolledMuls1, false, postLoadInstrs1: resetMulsInstr, postLoadInstrs2: resetMulsInstr);
        }
예제 #27
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string initInstrs = "  movss (%r8), %xmm1\n" +
                                "  movss 4(%r8), %xmm2\n" +
                                "  movss 8(%r8), %xmm3\n" +
                                "  movss 12(%r8), %xmm4\n" +
                                "  movss 16(%r8), %xmm5\n";

            string[] instrs = new string[8];
            instrs[0] = "add %r15, %r14";
            instrs[1] = "addss %xmm1, %xmm2";
            instrs[2] = "add %r15, %r13";
            instrs[3] = "addss %xmm1, %xmm3";
            instrs[4] = "add %r15, %r12";
            instrs[5] = "addss %xmm1, %xmm4";
            instrs[6] = "add %r15, %r11";
            instrs[7] = "addss %xmm1, %xmm5";
            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, instrs, instrs, true, initInstrs);
        }
예제 #28
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string[] unrolledJumps = new string[6];
            unrolledJumps[0] = "  cmp %rdi, %rsi\n  je muljmpsched_reallybadthing";
            unrolledJumps[1] = "  imul %edi, %r12d";
            unrolledJumps[2] = "  cmp %rdi, %rsi\n  je muljmpsched_reallybadthing";
            unrolledJumps[3] = "  imul %edi, %r13d";
            unrolledJumps[4] = "  cmp %rdi, %rsi\n  je muljmpsched_reallybadthing";
            unrolledJumps[5] = "  imul %edi, %r14d";

            string[] unrolledJumps1 = new string[2];
            unrolledJumps1[0] = "  cmp %rdi, %rsi\n  je muljmpsched_reallybadthing";
            unrolledJumps1[1] = "  imul %esi, %r11d";

            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledJumps, unrolledJumps1, false);

            sb.AppendLine("muljmpsched_reallybadthing:");
            sb.AppendLine("  int3");
        }
예제 #29
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            // xmm0 is dependent on ptr chasing load
            string[] unrolledAdds = new string[4];
            unrolledAdds[0] = "  addss %xmm0, %xmm1";
            unrolledAdds[1] = "  add %edi, %r11d";
            unrolledAdds[2] = "  addss %xmm0, %xmm3";
            unrolledAdds[3] = "  add %edi, %r12d";

            string[] unrolledAdds1 = new string[4];
            unrolledAdds1[0] = "  addss %xmm0, %xmm1";
            unrolledAdds1[1] = "  add %esi, %r14d";
            unrolledAdds1[2] = "  addss %xmm0, %xmm3";
            unrolledAdds1[3] = "  add %esi, %r15d";

            string rdicvt = "cvtsi2ss %rdi, %xmm0";
            string rsicvt = "cvtsi2ss %rsi, %xmm0";

            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(sb, this.Counts, this.Prefix, unrolledAdds, unrolledAdds,
                                                              includePtrChasingLoads: false, postLoadInstrs1: rdicvt, postLoadInstrs2: rsicvt);
        }
예제 #30
0
        public override void GenerateX86GccAsm(StringBuilder sb)
        {
            string postLoadInstr1 = "  add %rdi, %r11";

            string[] unrolledAdds = new string[4];
            unrolledAdds[0] = "  add %r11, %r15";
            unrolledAdds[1] = "  add %r11, %r14";
            unrolledAdds[2] = "  add %r11, %r13";
            unrolledAdds[3] = "  add %r11, %r12";

            string postLoadInstr2 = "  add %rsi, %r11";

            UarchTestHelpers.GenerateX86AsmStructureTestFuncs(
                sb,
                this.Counts,
                this.Prefix,
                unrolledAdds,
                unrolledAdds,
                false,
                postLoadInstrs1: postLoadInstr1,
                postLoadInstrs2: postLoadInstr2);
        }