summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/pr22152.c
blob: 489c8e9f8c49a5a91fe6346332902ab34ab7e26d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/* { dg-do compile { target ia32 } } */
/* { dg-options "-O2 -msse2 -mtune=core2" } */
/* { dg-additional-options "-mno-vect8-ret-in-mem" { target *-*-vxworks* } } */

#include <mmintrin.h>

typedef __SIZE_TYPE__ size_t;

__m64
unsigned_add3 (const __m64 * a, const __m64 * b, size_t count)
{
  __m64 sum = { 0, 0 };

  if (count > 0)
    sum = _mm_add_si64 (a[count-1], b[count-1]);

  return sum;
}

/* { dg-final { scan-assembler-times "movq\[ \\t\]+\[^\n\]*%mm" 1 } } */