public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc/devel/omp/gcc-12] Correct fix offload dwarf info
@ 2022-06-29 14:39 Kwok Yeung
0 siblings, 0 replies; only message in thread
From: Kwok Yeung @ 2022-06-29 14:39 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:353afd4ec8b7d72786b0a12ab78553acc3395c72
commit 353afd4ec8b7d72786b0a12ab78553acc3395c72
Author: Andrew Stubbs <ams@codesourcery.com>
Date: Sat Jan 16 15:18:07 2021 +0000
Correct fix offload dwarf info
The previous patch wasn't quite right, apparently. Somehow the behaviour
changed after another clean build? This tweak fixes it.
This patch should be squashed with fdcb23540a2 to go to mainline.
gcc/ChangeLog:
* dwarf2out.cc (gen_subprogram_die): Check offload attributes only.
Diff:
---
gcc/ChangeLog.omp | 4 ++++
gcc/dwarf2out.cc | 5 ++---
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/gcc/ChangeLog.omp b/gcc/ChangeLog.omp
index 5f473611046..b977f98af97 100644
--- a/gcc/ChangeLog.omp
+++ b/gcc/ChangeLog.omp
@@ -1,3 +1,7 @@
+2021-01-16 Andrew Stubbs <ams@codesourcery.com>
+
+ * dwarf2out.cc (gen_subprogram_die): Check offload attributes only.
+
2021-01-15 Andrew Stubbs <ams@codesourcery.com>
* dwarf2out.cc (add_location_or_const_value_attribute): Set
diff --git a/gcc/dwarf2out.cc b/gcc/dwarf2out.cc
index 50b5b1925b3..46e22c7eb91 100644
--- a/gcc/dwarf2out.cc
+++ b/gcc/dwarf2out.cc
@@ -23770,9 +23770,8 @@ gen_subprogram_die (tree decl, dw_die_ref context_die)
will ignore the function and everything nested within unless
we give it a notional code range (the values aren't
important, as long as they are valid). */
- if (flag_generate_offload
- && lookup_attribute ("omp target entrypoint",
- DECL_ATTRIBUTES (decl))
+ if (lookup_attribute ("omp target entrypoint",
+ DECL_ATTRIBUTES (decl))
&& subr_die->die_parent
&& subr_die->die_parent->die_tag == DW_TAG_subprogram
&& !get_AT_low_pc (subr_die->die_parent))
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-06-29 14:39 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-29 14:39 [gcc/devel/omp/gcc-12] Correct fix offload dwarf info Kwok Yeung
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).