public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [gomp4] internal fn cleanup
@ 2015-10-12  0:02 Nathan Sidwell
  0 siblings, 0 replies; only message in thread
From: Nathan Sidwell @ 2015-10-12  0:02 UTC (permalink / raw)
  To: GCC Patches

[-- Attachment #1: Type: text/plain, Size: 193 bytes --]

I've committed this to gomp4

1) move IFN_UNIQUE constants to the IFN_UNIQUE function definition

2) Update IFN_GOACC_REDUCTION_* comments to match the renamed oacc_device_lower 
pass.

nathan

[-- Attachment #2: gomp4-clean.patch --]
[-- Type: text/x-patch, Size: 2922 bytes --]

2015-10-11  Nathan Sidwell  <nathan@codesourcery.com>

	* internal-fn.def (IFN_UNIQUE_UNSPEC, IFN_UNIQUE_OACC_FORK,
	IFN_UNIQUE_OACC_JOIN): Move to IFN_UNIQUE definition.
	* internal-fn.c (expand_GOACC_REDUCTION_*): Correct comments.

Index: internal-fn.c
===================================================================
--- internal-fn.c	(revision 228677)
+++ internal-fn.c	(working copy)
@@ -2026,7 +2026,7 @@ expand_GOACC_DIM_POS (gcall *ARG_UNUSED
 #endif
 }
 
-/* This should get expanded in oacc_transform.  */
+/* All the GOACC_REDUCTION variants  get expanded in oacc_device_lower.  */
 
 static void
 expand_GOACC_REDUCTION_SETUP (gcall *stmt ATTRIBUTE_UNUSED)
@@ -2034,24 +2034,18 @@ expand_GOACC_REDUCTION_SETUP (gcall *stm
   gcc_unreachable ();
 }
 
-/* This should get expanded in oacc_transform.  */
-
 static void
 expand_GOACC_REDUCTION_INIT (gcall *stmt ATTRIBUTE_UNUSED)
 {
   gcc_unreachable ();
 }
 
-/* This should get expanded in oacc_transform.  */
-
 static void
 expand_GOACC_REDUCTION_FINI (gcall *stmt ATTRIBUTE_UNUSED)
 {
   gcc_unreachable ();
 }
 
-/* This should get expanded in oacc_transform.  */
-
 static void
 expand_GOACC_REDUCTION_TEARDOWN (gcall *stmt ATTRIBUTE_UNUSED)
 {
Index: internal-fn.def
===================================================================
--- internal-fn.def	(revision 228677)
+++ internal-fn.def	(working copy)
@@ -67,10 +67,17 @@ DEF_INTERNAL_FN (GOACC_DATA_END_WITH_ARG
 
 /* An unduplicable, uncombinable function.  Generally used to preserve
    a CFG property in the face of jump threading, tail merging or
-   other such optimizations. The optional first argument distinguishes
+   other such optimizations.  The first argument distinguishes
    between uses.  Other arguments are as needed for use.  The return
-   type depends on use too. */
+   type depends on use too.  */
 DEF_INTERNAL_FN (UNIQUE, ECF_NOTHROW | ECF_LEAF, NULL)
+#define IFN_UNIQUE_UNSPEC 0  /* Undifferentiated UNIQUE.  */
+
+/* FORK and JOIN mark the points at which OpenACC partitioned
+   execution is entered or exited.  They take an INTEGER_CST argument,
+   indicating the axis of forking or joining and return nothing.  */
+#define IFN_UNIQUE_OACC_FORK 1
+#define IFN_UNIQUE_OACC_JOIN 2
 
 /* DIM_SIZE and DIM_POS return the size of a particular compute
    dimension and the executing thread's position within that
@@ -99,11 +106,3 @@ DEF_INTERNAL_FN (GOACC_REDUCTION_INIT, E
 DEF_INTERNAL_FN (GOACC_REDUCTION_FINI, ECF_NOTHROW, NULL)
 DEF_INTERNAL_FN (GOACC_REDUCTION_TEARDOWN, ECF_NOTHROW, NULL)
 
-/* IFN_UNIQUE uses an INTEGER_CST first argument to discriminate use.  */
-#define IFN_UNIQUE_UNSPEC 0
-
-/* FORK and JOIN mark the points at which partitioned execution is
-   entered or exited.  They take an INTEGER_CST argument, indicating
-   the axis of forking or joining and return nothing.  */
-#define IFN_UNIQUE_OACC_FORK 1
-#define IFN_UNIQUE_OACC_JOIN 2

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

only message in thread, other threads:[~2015-10-12  0:02 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-12  0:02 [gomp4] internal fn cleanup Nathan Sidwell

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).