public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc/devel/omp/gcc-11] 'libgomp.c/target-43.c': '-latomic' for nvptx offloading
@ 2021-09-06 13:23 Tobias Burnus
  0 siblings, 0 replies; only message in thread
From: Tobias Burnus @ 2021-09-06 13:23 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:4c086e7dabf99855e6a977228eddf48eb9441a4c

commit 4c086e7dabf99855e6a977228eddf48eb9441a4c
Author: Thomas Schwinge <thomas@codesourcery.com>
Date:   Mon Sep 6 15:23:03 2021 +0200

    'libgomp.c/target-43.c': '-latomic' for nvptx offloading
    
    ... to avoid a regression with recent
    commit 090f0d78f194e3cda23fe904016db77ea36c38fa
    "openmp: Improve expand_omp_atomic_pipeline":
    
        unresolved symbol __atomic_compare_exchange_1
        collect2: error: ld returned 1 exit status
        mkoffload: fatal error: [...]/gcc/x86_64-pc-linux-gnu-accel-nvptx-none-gcc returned 1 exit status
    
            libgomp/
            * testsuite/libgomp.c/target-43.c: '-latomic' for nvptx offloading.
    
    (cherry picked from commit 086bb917d6efa32d9841c34a3b762f4278c762cd)

Diff:
---
 libgomp/ChangeLog.omp                   | 7 +++++++
 libgomp/testsuite/libgomp.c/target-43.c | 2 ++
 2 files changed, 9 insertions(+)

diff --git a/libgomp/ChangeLog.omp b/libgomp/ChangeLog.omp
index 8e702a4dbd1..9ca50b2a32e 100644
--- a/libgomp/ChangeLog.omp
+++ b/libgomp/ChangeLog.omp
@@ -1,3 +1,10 @@
+2021-09-06  Tobias Burnus  <tobias@codesourcery.com>
+
+	Backported from master:
+	2021-09-06  Thomas Schwinge  <thomas@codesourcery.com>
+
+	* testsuite/libgomp.c/target-43.c: '-latomic' for nvptx offloading.
+
 2021-08-03  Tobias Burnus  <tobias@codesourcery.com>
 
 	Backported from master:
diff --git a/libgomp/testsuite/libgomp.c/target-43.c b/libgomp/testsuite/libgomp.c/target-43.c
index 46b1cfc5b20..028e9120f2a 100644
--- a/libgomp/testsuite/libgomp.c/target-43.c
+++ b/libgomp/testsuite/libgomp.c/target-43.c
@@ -1,4 +1,6 @@
 /* { dg-do run } */
+/* { dg-additional-options "-foffload-options=nvptx-none=-latomic" { target { offload_target_nvptx } } } */
+
 #include <stdlib.h>
 
 #define N 32


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-09-06 13:23 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-06 13:23 [gcc/devel/omp/gcc-11] 'libgomp.c/target-43.c': '-latomic' for nvptx offloading Tobias Burnus

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).