[flang-commits] [flang] [flang] Fix broken atan_real16 test (PR #98499)

Tarun Prabhu via flang-commits flang-commits at lists.llvm.org
Thu Jul 11 08:59:02 PDT 2024


https://github.com/tarunprabhu updated https://github.com/llvm/llvm-project/pull/98499

>From a36bdd881bf1cdb0d93bf3dd02fca03d64879b3c Mon Sep 17 00:00:00 2001
From: Tarun Prabhu <tarun at lanl.gov>
Date: Thu, 11 Jul 2024 09:46:27 -0600
Subject: [PATCH 1/2] [flang] Fix broken atan_real16 test

---
 flang/test/Lower/Intrinsics/atan_real16.f90 | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/flang/test/Lower/Intrinsics/atan_real16.f90 b/flang/test/Lower/Intrinsics/atan_real16.f90
index 3ae037307c32b..292091463b01d 100644
--- a/flang/test/Lower/Intrinsics/atan_real16.f90
+++ b/flang/test/Lower/Intrinsics/atan_real16.f90
@@ -6,7 +6,7 @@
 function test_real16(x)
   real(16) :: x, test_real16
   test_real16 = atan(x)
-end function real16
+end function test_real16
 
 ! CHECK-LABEL: @_QPtest_real16
 ! CHECK: fir.call @_FortranAAtanF128({{.*}}){{.*}}: (f128) -> f128
@@ -14,7 +14,7 @@ end function real16
 function test_real16_2(y, x)
   real(16) :: y, x, test_real16
   test_real16 = atan(y, x)
-end function real16_2
+end function test_real16_2
 
 ! CHECK-LABEL: @_QPtest_real16
 ! CHECK: fir.call @_FortranAAtan2F128({{.*}}){{.*}}: (f128, f128) -> f128

>From 4a0dcd37d2ebb173fdb21b596de48552e6a150c5 Mon Sep 17 00:00:00 2001
From: Tarun Prabhu <tarun at lanl.gov>
Date: Thu, 11 Jul 2024 09:58:37 -0600
Subject: [PATCH 2/2] Address review comments. Fixed several incorrect names.

---
 flang/test/Lower/Intrinsics/atan_real16.f90 | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/flang/test/Lower/Intrinsics/atan_real16.f90 b/flang/test/Lower/Intrinsics/atan_real16.f90
index 292091463b01d..2bad58cf35f77 100644
--- a/flang/test/Lower/Intrinsics/atan_real16.f90
+++ b/flang/test/Lower/Intrinsics/atan_real16.f90
@@ -6,15 +6,15 @@
 function test_real16(x)
   real(16) :: x, test_real16
   test_real16 = atan(x)
-end function test_real16
+end function
 
 ! CHECK-LABEL: @_QPtest_real16
 ! CHECK: fir.call @_FortranAAtanF128({{.*}}){{.*}}: (f128) -> f128
 
 function test_real16_2(y, x)
-  real(16) :: y, x, test_real16
-  test_real16 = atan(y, x)
-end function test_real16_2
+  real(16) :: y, x, test_real16_2
+  test_real16_2 = atan(y, x)
+end function
 
-! CHECK-LABEL: @_QPtest_real16
+! CHECK-LABEL: @_QPtest_real16_2
 ! CHECK: fir.call @_FortranAAtan2F128({{.*}}){{.*}}: (f128, f128) -> f128



More information about the flang-commits mailing list