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/] [paired-1.c] - Blame information for rev 859

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 322 jeremybenn
/* { dg-do compile { target { powerpc-*-linux*paired* && ilp32} } } */
2
/* { dg-options "-mpaired -ffinite-math-only " } */
3
 
4
/* Test PowerPC PAIRED extensions.  */
5
 
6
#include <paired.h>
7
 
8
static float in1[2] __attribute__ ((aligned (8))) =
9
{6.0, 7.0};
10
static float in2[2] __attribute__ ((aligned (8))) =
11
{4.0, 3.0};
12
 
13
static float out[2] __attribute__ ((aligned (8)));
14
 
15
vector float a, b, c, d;
16
void
17
test_api ()
18
{
19
  b = paired_lx (0, in1);
20
  c = paired_lx (0, in2);
21
 
22
  a = paired_sub (b, c);
23
 
24
  paired_stx (a, 0, out);
25
}
26
 
27
int
28
main ()
29
{
30
  test_api ();
31
  return (0);
32
}
33
 

powered by: WebSVN 2.1.0

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