aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ChangeLog.omp9
-rw-r--r--gcc/DATESTAMP.omp2
-rw-r--r--gcc/testsuite/ChangeLog.omp8
-rw-r--r--gcc/testsuite/c-c++-common/gomp/omp_get_num_devices_initial_device.c4
-rw-r--r--gcc/testsuite/gfortran.dg/gomp/omp_get_num_devices_initial_device.f904
-rw-r--r--libgomp/ChangeLog.omp18
-rw-r--r--libgomp/testsuite/libgomp.c-c++-common/omp_target_memset-3.c4
7 files changed, 42 insertions, 7 deletions
diff --git a/gcc/ChangeLog.omp b/gcc/ChangeLog.omp
index 9934978..69162ef 100644
--- a/gcc/ChangeLog.omp
+++ b/gcc/ChangeLog.omp
@@ -1,3 +1,12 @@
+2025-06-17 Tobias Burnus <tburnus@baylibre.com>
+
+ Backported from master:
+ 2025-06-17 Tobias Burnus <tburnus@baylibre.com>
+
+ * omp-offload.cc (omp_discover_declare_target_tgt_fn_r): Also
+ walk external functions that are declare inline (and have a
+ DECL_SAVED_TREE).
+
2025-06-10 Tobias Burnus <tburnus@baylibre.com>
Backported from master:
diff --git a/gcc/DATESTAMP.omp b/gcc/DATESTAMP.omp
index 52988ae..6952979 100644
--- a/gcc/DATESTAMP.omp
+++ b/gcc/DATESTAMP.omp
@@ -1 +1 @@
-20250610
+20250703
diff --git a/gcc/testsuite/ChangeLog.omp b/gcc/testsuite/ChangeLog.omp
index 1684f7a..a7ea0db 100644
--- a/gcc/testsuite/ChangeLog.omp
+++ b/gcc/testsuite/ChangeLog.omp
@@ -1,3 +1,11 @@
+2025-07-03 Thomas Schwinge <tschwinge@baylibre.com>
+
+ Backported from master:
+ 2025-07-03 Thomas Schwinge <tschwinge@baylibre.com>
+
+ * c-c++-common/gomp/omp_get_num_devices_initial_device.c: Fix.
+ * gfortran.dg/gomp/omp_get_num_devices_initial_device.f90: Likewise.
+
2025-06-06 Tobias Burnus <tburnus@baylibre.com>
Backported from master:
diff --git a/gcc/testsuite/c-c++-common/gomp/omp_get_num_devices_initial_device.c b/gcc/testsuite/c-c++-common/gomp/omp_get_num_devices_initial_device.c
index 4b17143..6e2c1a8 100644
--- a/gcc/testsuite/c-c++-common/gomp/omp_get_num_devices_initial_device.c
+++ b/gcc/testsuite/c-c++-common/gomp/omp_get_num_devices_initial_device.c
@@ -25,8 +25,8 @@ int f()
/* { dg-final { scan-tree-dump-not "abort" "optimized" } } */
-/* { dg-final { scan-tree-dump-not "omp_get_num_devices;" "optimized" { target { ! offloading_enabled } } } } */
+/* { dg-final { scan-tree-dump-not "omp_get_num_devices" "optimized" { target { ! offloading_enabled } } } } */
/* { dg-final { scan-tree-dump "return 0;" "optimized" { target { ! offloading_enabled } } } } */
-/* { dg-final { scan-tree-dump-times "omp_get_num_devices;" 1 "optimized" { target offloading_enabled } } } */
+/* { dg-final { scan-tree-dump-times "omp_get_num_devices" 1 "optimized" { target offloading_enabled } } } */
/* { dg-final { scan-tree-dump "_1 = __builtin_omp_get_num_devices \\(\\);\[\\r\\n\]+\[ \]+return _1;" "optimized" { target offloading_enabled } } } */
diff --git a/gcc/testsuite/gfortran.dg/gomp/omp_get_num_devices_initial_device.f90 b/gcc/testsuite/gfortran.dg/gomp/omp_get_num_devices_initial_device.f90
index 5409f12..279656b 100644
--- a/gcc/testsuite/gfortran.dg/gomp/omp_get_num_devices_initial_device.f90
+++ b/gcc/testsuite/gfortran.dg/gomp/omp_get_num_devices_initial_device.f90
@@ -17,8 +17,8 @@ end
! { dg-final { scan-tree-dump-not "error_stop" "optimized" } }
-! { dg-final { scan-tree-dump-not "omp_get_num_devices;" "optimized" { target { ! offloading_enabled } } } }
+! { dg-final { scan-tree-dump-not "omp_get_num_devices" "optimized" { target { ! offloading_enabled } } } }
! { dg-final { scan-tree-dump "return 0;" "optimized" { target { ! offloading_enabled } } } }
-! { dg-final { scan-tree-dump-times "omp_get_num_devices;" 1 "optimized" { target offloading_enabled } } }
+! { dg-final { scan-tree-dump-times "omp_get_num_devices" 1 "optimized" { target offloading_enabled } } }
! { dg-final { scan-tree-dump "_1 = __builtin_omp_get_num_devices \\(\\);\[\\r\\n\]+\[ \]+return _1;" "optimized" { target offloading_enabled } } }
diff --git a/libgomp/ChangeLog.omp b/libgomp/ChangeLog.omp
index 2bf31a9..689cfbf 100644
--- a/libgomp/ChangeLog.omp
+++ b/libgomp/ChangeLog.omp
@@ -1,3 +1,21 @@
+2025-07-03 Jakub Jelinek <jakub@redhat.com>
+
+ Backported from master:
+ 2025-06-03 Jakub Jelinek <jakub@redhat.com>
+
+ PR libgomp/120444
+ * testsuite/libgomp.c-c++-common/omp_target_memset-3.c (test_it):
+ Change ptr argument type from void * to int8_t *.
+ (main): Change ptr variable type from void * to int8_t * and cast
+ omp_target_alloc result to the latter type.
+
+2025-06-17 Tobias Burnus <tburnus@baylibre.com>
+
+ Backported from master:
+ 2025-06-17 Tobias Burnus <tburnus@baylibre.com>
+
+ * testsuite/libgomp.c++/declare_target-2.C: New test.
+
2025-06-10 Tobias Burnus <tburnus@baylibre.com>
Backported from master:
diff --git a/libgomp/testsuite/libgomp.c-c++-common/omp_target_memset-3.c b/libgomp/testsuite/libgomp.c-c++-common/omp_target_memset-3.c
index 6f25204..c0e4fa9 100644
--- a/libgomp/testsuite/libgomp.c-c++-common/omp_target_memset-3.c
+++ b/libgomp/testsuite/libgomp.c-c++-common/omp_target_memset-3.c
@@ -24,7 +24,7 @@ check_val (int8_t *ptr, int val, size_t count)
}
static void
-test_it (void *ptr, int lshift, size_t count)
+test_it (int8_t *ptr, int lshift, size_t count)
{
if (N < count + lshift) __builtin_abort ();
if (lshift >= 4) __builtin_abort ();
@@ -42,7 +42,7 @@ test_it (void *ptr, int lshift, size_t count)
int main()
{
size_t size;
- void *ptr = omp_target_alloc (N + 3, omp_get_default_device());
+ int8_t *ptr = (int8_t *) omp_target_alloc (N + 3, omp_get_default_device());
ptr += (4 - (uintptr_t) ptr % 4) % 4;
if ((uintptr_t) ptr % 4 != 0) __builtin_abort ();