From: Sandra Loosemore <sandra@codesourcery.com>
To: Jakub Jelinek <jakub@redhat.com>
Cc: Jan Hubicka <jh@suse.cz>,
"gcc-patches@gcc.gnu.org" <gcc-patches@gcc.gnu.org>,
Thomas Schwinge <thomas@codesourcery.com>
Subject: Re: [PATCH v3] Re: OpenMP: Generate SIMD clones for functions with "declare target"
Date: Wed, 26 Oct 2022 20:27:19 -0600 [thread overview]
Message-ID: <bf4a7ec6-a390-8658-6cad-884c05c052c1@codesourcery.com> (raw)
In-Reply-To: <Y1FWBg4O5gLnhx/F@tucnak>
On 10/20/22 08:07, Jakub Jelinek wrote:
> Thus, IMHO it is exactly the pass_omp_simd_clone pass where you want to
> implement this auto-simdization discovery, guarded with
> #ifdef ACCEL_COMPILER and the new option (which means it will be done
> only for gcn and not on the host right now).
I'm running into a practical difficulty with making this controlled by a
static #ifdef: namely, testing.
One of my test cases examines the .s output to make sure that the clones
are emitted as local symbols and not global. I have not been able to
find the symbol linkage information in any of the dump files, and I have
also not been able to figure out how to get a .s file from the offload
compiler even outside of the DejaGnu test harness. (It's possible I am
just an extreme dummy about the latter problem, but so far none of my
colleagues here has been able to give me a recipe either.)
On top of that, I worry that this should be tested more broadly than for
the one target we're presently focusing on (AMD GCN), and we'll get much
more regular test coverage if it's also enabled for x86_64 target which
has the necessary compute_vecsize_and_simdlen target hook.
I remember Carlos O'Donnell used to have a favorite mantra, "design for
test". So, maybe generalize the new -fopenmp-target-simd-clone option
to take a parameter to force clones to be generated on the OpenMP host
for test purposes? The "declare target" directive already has a clause
device_type(host|nohost|any)
that defaults to "any"; maybe we could use that syntax like
-fopenmp-target-simd-clone=any
and use the intersection of the two sets to determine what to
auto-generate clones for?
-Sandra
next prev parent reply other threads:[~2022-10-27 2:27 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-14 17:32 Sandra Loosemore
2022-09-14 18:12 ` Jakub Jelinek
2022-09-22 3:17 ` [PATCH v2] " Sandra Loosemore
2022-09-30 10:37 ` Jakub Jelinek
2022-10-17 1:23 ` [PATCH v3] " Sandra Loosemore
2022-10-20 14:07 ` Jakub Jelinek
2022-10-27 2:27 ` Sandra Loosemore [this message]
2022-10-27 10:09 ` Thomas Schwinge
2022-10-27 20:40 ` Sandra Loosemore
2022-09-14 21:45 ` Thomas Schwinge
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=bf4a7ec6-a390-8658-6cad-884c05c052c1@codesourcery.com \
--to=sandra@codesourcery.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=jakub@redhat.com \
--cc=jh@suse.cz \
--cc=thomas@codesourcery.com \
/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).