[flang-commits] [flang] [flang][cuda] Update syncthreads interface (PR #138023)

Valentin Clement バレンタイン クレメン via flang-commits flang-commits at lists.llvm.org
Wed Apr 30 14:11:05 PDT 2025


https://github.com/clementval created https://github.com/llvm/llvm-project/pull/138023

None

>From e0431b79169536c82518966da2c07d6a0db08f0d Mon Sep 17 00:00:00 2001
From: Valentin Clement <clementval at gmail.com>
Date: Wed, 30 Apr 2025 14:10:23 -0700
Subject: [PATCH] [flang][cuda] Update synthreads interface

---
 flang/module/cudadevice.f90 | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/flang/module/cudadevice.f90 b/flang/module/cudadevice.f90
index 9bd90bcfc30ec..f8a30da8b9615 100644
--- a/flang/module/cudadevice.f90
+++ b/flang/module/cudadevice.f90
@@ -17,9 +17,8 @@ module cudadevice
 
   ! Synchronization Functions
 
-  interface
-    attributes(device) subroutine syncthreads()
-    end subroutine
+  interface syncthreads
+    procedure :: syncthreads
   end interface
 
   interface
@@ -1614,4 +1613,9 @@ attributes(device,host) logical function on_device() bind(c)
     end function
   end interface
 
+contains
+
+  attributes(device) subroutine syncthreads()
+  end subroutine
+
 end module



More information about the flang-commits mailing list