OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc2/] [gcc/] [testsuite/] [gcc.target/] [i386/] [funcspec-7.c] - Blame information for rev 384

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 318 jeremybenn
/* Test whether using target specific options, we can generate the reciprocal
2
   square root instruction.  */
3
/* { dg-do compile } */
4
/* { dg-options "-O2 -march=k8 -mno-recip -mfpmath=sse -ffast-math" } */
5
 
6
float do_recip  (float a) __attribute__((__target__("recip")));
7
float do_normal (float a);
8
 
9
float do_recip  (float a) { return 1.0f / __builtin_sqrtf (a); }
10
float do_normal (float a) { return 1.0f / __builtin_sqrtf (a); }
11
 
12
/* { dg-final { scan-assembler "sqrtss" } } */
13
/* { dg-final { scan-assembler "rsqrtss" } } */

powered by: WebSVN 2.1.0

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