summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/math-torture/lround.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.target/i386/math-torture/lround.c')
-rw-r--r--gcc/testsuite/gcc.target/i386/math-torture/lround.c26
1 files changed, 26 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/i386/math-torture/lround.c b/gcc/testsuite/gcc.target/i386/math-torture/lround.c
new file mode 100644
index 000000000..756356d62
--- /dev/null
+++ b/gcc/testsuite/gcc.target/i386/math-torture/lround.c
@@ -0,0 +1,26 @@
+/* { dg-do assemble } */
+
+long testlf (float x)
+{
+ return __builtin_lroundf (x);
+}
+long testl (double x)
+{
+ return __builtin_lround (x);
+}
+long testll (long double x)
+{
+ return __builtin_lroundl (x);
+}
+long long testllf (float x)
+{
+ return __builtin_llroundf (x);
+}
+long long testll_ (double x)
+{
+ return __builtin_llround (x);
+}
+long long testlll (long double x)
+{
+ return __builtin_llroundl (x);
+}