OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-stable/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.target/] [powerpc/] [dfp-dd.c] - Blame information for rev 826

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 322 jeremybenn
/* Test generation of DFP instructions for POWER6.  */
2
/* Origin: Janis Johnson <janis187@us.ibm.com> */
3
/* { dg-do compile { target { powerpc*-*-linux* && powerpc_fprs } } } */
4
/* { dg-options "-std=gnu99 -mcpu=power6" } */
5
 
6
/* { dg-final { scan-assembler "dadd" } } */
7
/* { dg-final { scan-assembler "ddiv" } } */
8
/* { dg-final { scan-assembler "dmul" } } */
9
/* { dg-final { scan-assembler "dsub" } } */
10
/* { dg-final { scan-assembler-times "dcmpu" 6 } } */
11
/* { dg-final { scan-assembler-times "dctfix" 2 } } */
12
/* { dg-final { scan-assembler-times "drintn" 2 } } */
13
/* { dg-final { scan-assembler-times "dcffixq" 2 } } */
14
 
15
extern _Decimal64 a, b, c;
16
extern int result;
17
extern int si;
18
extern long long di;
19
 
20
void add (void) { a = b + c; }
21
void div (void) { a = b / c; }
22
void mul (void) { a = b * c; }
23
void sub (void) { a = b - c; }
24
void eq (void) { result = a == b; }
25
void ne (void) { result = a != b; }
26
void lt (void) { result = a < b; }
27
void le (void) { result = a <= b; }
28
void gt (void) { result = a > b; }
29
void ge (void) { result = a >= b; }
30
void ddsi (void) { si = a; }
31
void dddi (void) { di = a; }
32
void sidd (void) { a = si; }
33
void didd (void) { a = di; }

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.