From: Jakub Jelinek <jakub@redhat.com>
To: Richard Biener <rguenther@suse.de>
Cc: Tom de Vries <Tom_deVries@mentor.com>,
GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH] Fix ICE for static vars in offloaded functions
Date: Wed, 07 Mar 2018 14:13:00 -0000 [thread overview]
Message-ID: <20180307133113.GF5867@tucnak> (raw)
In-Reply-To: <alpine.LSU.2.20.1803071427530.18265@zhemvz.fhfr.qr>
On Wed, Mar 07, 2018 at 02:29:48PM +0100, Richard Biener wrote:
> On Wed, 7 Mar 2018, Jakub Jelinek wrote:
>
> > On Wed, Mar 07, 2018 at 02:20:26PM +0100, Tom de Vries wrote:
> > > Fix ICE for static vars in offloaded functions
> > >
> > > 2018-03-06 Tom de Vries <tom@codesourcery.com>
> > >
> > > PR lto/84592
> > > * varpool.c (varpool_node::get_create): Mark static variables in
> > > offloaded functions as offloadable.
> > >
> > > * testsuite/libgomp.c/pr84592-2.c: New test.
> > > * testsuite/libgomp.c/pr84592.c: New test.
> > > * testsuite/libgomp.oacc-c-c++-common/pr84592-3.c: New test.
> >
> > Ok, thanks
>
> + bool in_offload_func
> + = (cfun
> + && TREE_STATIC (decl)
> + && (lookup_attribute ("omp target entr
>
> I think you want to use decl_function_context (decl) here,
> not rely on magic cfun being set. The whole varpool.c file
> doesn't mention cfun yet and you shoudln't either.
Oops, sure, thanks for catching it.
Jakub
next prev parent reply other threads:[~2018-03-07 14:13 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-07 13:20 Tom de Vries
2018-03-07 22:13 ` Jakub Jelinek
2018-03-07 13:29 ` Richard Biener
2018-03-07 14:13 ` Jakub Jelinek [this message]
2018-03-07 14:51 ` Tom de Vries
2018-03-07 15:01 ` Richard Biener
2018-03-26 11:04 ` Tom de Vries
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180307133113.GF5867@tucnak \
--to=jakub@redhat.com \
--cc=Tom_deVries@mentor.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=rguenther@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).