aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc')
-rw-r--r--gcc/tree-core.h6
-rw-r--r--gcc/tree-pretty-print.cc13
-rw-r--r--gcc/tree.cc4
-rw-r--r--gcc/tree.h4
4 files changed, 14 insertions, 13 deletions
diff --git a/gcc/tree-core.h b/gcc/tree-core.h
index cfe37c1..4dc3682 100644
--- a/gcc/tree-core.h
+++ b/gcc/tree-core.h
@@ -389,6 +389,9 @@ enum omp_clause_code {
/* OpenACC/OpenMP clause: if (scalar-expression). */
OMP_CLAUSE_IF,
+ /* OpenACC clause: self. */
+ OMP_CLAUSE_SELF,
+
/* OpenMP clause: num_threads (integer-expression). */
OMP_CLAUSE_NUM_THREADS,
@@ -527,9 +530,6 @@ enum omp_clause_code {
/* OpenACC clause: nohost. */
OMP_CLAUSE_NOHOST,
-
- /* OpenACC clause: self. */
- OMP_CLAUSE_SELF,
};
#undef DEFTREESTRUCT
diff --git a/gcc/tree-pretty-print.cc b/gcc/tree-pretty-print.cc
index 39ec1df..1fadd75 100644
--- a/gcc/tree-pretty-print.cc
+++ b/gcc/tree-pretty-print.cc
@@ -587,6 +587,13 @@ dump_omp_clause (pretty_printer *pp, tree clause, int spc, dump_flags_t flags)
pp_right_paren (pp);
break;
+ case OMP_CLAUSE_SELF:
+ pp_string (pp, "self(");
+ dump_generic_node (pp, OMP_CLAUSE_SELF_EXPR (clause),
+ spc, flags, false);
+ pp_right_paren (pp);
+ break;
+
case OMP_CLAUSE_NUM_THREADS:
pp_string (pp, "num_threads(");
dump_generic_node (pp, OMP_CLAUSE_NUM_THREADS_EXPR (clause),
@@ -1453,12 +1460,6 @@ dump_omp_clause (pretty_printer *pp, tree clause, int spc, dump_flags_t flags)
false);
pp_right_paren (pp);
break;
- case OMP_CLAUSE_SELF:
- pp_string (pp, "self(");
- dump_generic_node (pp, OMP_CLAUSE_SELF_EXPR (clause),
- spc, flags, false);
- pp_right_paren (pp);
- break;
default:
gcc_unreachable ();
}
diff --git a/gcc/tree.cc b/gcc/tree.cc
index c38b09c..cfead15 100644
--- a/gcc/tree.cc
+++ b/gcc/tree.cc
@@ -280,6 +280,7 @@ unsigned const char omp_clause_num_ops[] =
1, /* OMP_CLAUSE__CONDTEMP_ */
1, /* OMP_CLAUSE__SCANTEMP_ */
1, /* OMP_CLAUSE_IF */
+ 1, /* OMP_CLAUSE_SELF */
1, /* OMP_CLAUSE_NUM_THREADS */
1, /* OMP_CLAUSE_SCHEDULE */
0, /* OMP_CLAUSE_NOWAIT */
@@ -326,7 +327,6 @@ unsigned const char omp_clause_num_ops[] =
0, /* OMP_CLAUSE_IF_PRESENT */
0, /* OMP_CLAUSE_FINALIZE */
0, /* OMP_CLAUSE_NOHOST */
- 1, /* OMP_CLAUSE_SELF */
};
const char * const omp_clause_code_name[] =
@@ -372,6 +372,7 @@ const char * const omp_clause_code_name[] =
"_condtemp_",
"_scantemp_",
"if",
+ "self",
"num_threads",
"schedule",
"nowait",
@@ -418,7 +419,6 @@ const char * const omp_clause_code_name[] =
"if_present",
"finalize",
"nohost",
- "self",
};
/* Unless specific to OpenACC, we tend to internally maintain OpenMP-centric
diff --git a/gcc/tree.h b/gcc/tree.h
index aaf744c..ac94bd7 100644
--- a/gcc/tree.h
+++ b/gcc/tree.h
@@ -1724,6 +1724,8 @@ class auto_suppress_location_wrappers
OMP_CLAUSE_OPERAND (OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_FINAL), 0)
#define OMP_CLAUSE_IF_EXPR(NODE) \
OMP_CLAUSE_OPERAND (OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_IF), 0)
+#define OMP_CLAUSE_SELF_EXPR(NODE) \
+ OMP_CLAUSE_OPERAND (OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_SELF), 0)
#define OMP_CLAUSE_NUM_THREADS_EXPR(NODE) \
OMP_CLAUSE_OPERAND (OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_NUM_THREADS),0)
#define OMP_CLAUSE_SCHEDULE_CHUNK_EXPR(NODE) \
@@ -1734,8 +1736,6 @@ class auto_suppress_location_wrappers
OMP_CLAUSE_OPERAND (OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_HINT), 0)
#define OMP_CLAUSE_FILTER_EXPR(NODE) \
OMP_CLAUSE_OPERAND (OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_FILTER), 0)
-#define OMP_CLAUSE_SELF_EXPR(NODE) \
- OMP_CLAUSE_OPERAND (OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_SELF), 0)
#define OMP_CLAUSE_GRAINSIZE_EXPR(NODE) \
OMP_CLAUSE_OPERAND (OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_GRAINSIZE),0)