]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/testsuite/gcc.target/mips/madd-3.c
MIPS32R6 and MIPS64R6 support
[thirdparty/gcc.git] / gcc / testsuite / gcc.target / mips / madd-3.c
CommitLineData
7f9844ca 1/* { dg-do compile } */
82f84ecb 2/* { dg-options "(HAS_MADD) -mgp32" } */
0c436cbd 3/* { dg-skip-if "code quality test" { *-*-* } { "-O0" } { "" } } */
7f9844ca
RS
4/* { dg-final { scan-assembler-times "\tmadd\t" 3 } } */
5
1333282d 6NOMIPS16 long long
7f9844ca
RS
7f1 (int x, int y, long long z)
8{
9 return (long long) x * y + z;
10}
11
1333282d 12NOMIPS16 long long
7f9844ca
RS
13f2 (int x, int y, long long z)
14{
15 return z + (long long) y * x;
16}
17
1333282d 18NOMIPS16 long long
7f9844ca
RS
19f3 (int x, int y, long long z)
20{
21 long long t = (long long) x * y;
22 int temp = 5;
23 if (temp == 5)
24 z += t;
25 return z;
26}