@@ -1,3 +1,22 @@
+2015-01-13 Thomas Schwinge <thomas@codesourcery.com>
+
+ * tree-core.h: Don't include "gomp-constants.h".
+ (struct tree_omp_clause): Change type of map_kind member from enum
+ gomp_map_kind to unsigned char.
+ * tree.h (OMP_CLAUSE_MAP_KIND): Cast it to enum gomp_map_kind.
+ (OMP_CLAUSE_SET_MAP_KIND): New macro.
+ * gimplify.c (gimplify_adjust_omp_clauses_1)
+ (gimplify_adjust_omp_clauses): Use OMP_CLAUSE_SET_MAP_KIND.
+ * omp-low.c (oacc_initialize_reduction_data): Likewise.
+ * tree-nested.c (convert_nonlocal_reference_stmt)
+ (convert_local_reference_stmt, convert_gimple_call): Likewise.
+ * tree-streamer-in.c (unpack_ts_omp_clause_value_fields):
+ Likewise.
+
+ * lto-streamer-out.c: Include "gomp-constants.h".
+ * tree-streamer-in.c: Likewise.
+ * tree-streamer-out.c: Likewise.
+
2015-01-12 Thomas Schwinge <thomas@codesourcery.com>
* tree-core.h (OMP_CLAUSE_MAP_ALLOC, OMP_CLAUSE_MAP_TO)
@@ -1,3 +1,10 @@
+2015-01-13 Thomas Schwinge <thomas@codesourcery.com>
+
+ * c-parser.c (c_parser_oacc_data_clause)
+ (c_parser_oacc_data_clause_deviceptr, c_parser_omp_clause_map):
+ Use OMP_CLAUSE_SET_MAP_KIND.
+ * c-typeck.c (handle_omp_array_sections): Likewise.
+
2014-12-19 Jakub Jelinek <jakub@redhat.com>
* c-parser.c (c_parser_omp_clause_name): Use PRAGMA_OACC_CLAUSE_*
@@ -10305,7 +10305,7 @@ c_parser_oacc_data_clause (c_parser *parser, pragma_omp_clause c_kind,
nl = c_parser_omp_var_list_parens (parser, OMP_CLAUSE_MAP, list);
for (c = nl; c != list; c = OMP_CLAUSE_CHAIN (c))
- OMP_CLAUSE_MAP_KIND (c) = kind;
+ OMP_CLAUSE_SET_MAP_KIND (c, kind);
return nl;
}
@@ -10341,7 +10341,7 @@ c_parser_oacc_data_clause_deviceptr (c_parser *parser, tree list)
error_at (loc, "%qD is not a pointer variable", v);
tree u = build_omp_clause (loc, OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (u) = GOMP_MAP_FORCE_DEVICEPTR;
+ OMP_CLAUSE_SET_MAP_KIND (u, GOMP_MAP_FORCE_DEVICEPTR);
OMP_CLAUSE_DECL (u) = v;
OMP_CLAUSE_CHAIN (u) = list;
list = u;
@@ -11414,7 +11414,7 @@ c_parser_omp_clause_map (c_parser *parser, tree list)
nl = c_parser_omp_variable_list (parser, clause_loc, OMP_CLAUSE_MAP, list);
for (c = nl; c != list; c = OMP_CLAUSE_CHAIN (c))
- OMP_CLAUSE_MAP_KIND (c) = kind;
+ OMP_CLAUSE_SET_MAP_KIND (c, kind);
c_parser_skip_until_found (parser, CPP_CLOSE_PAREN, "expected %<)%>");
return nl;
@@ -11943,7 +11943,7 @@ handle_omp_array_sections (tree c)
return false;
gcc_assert (OMP_CLAUSE_MAP_KIND (c) != GOMP_MAP_FORCE_DEVICEPTR);
tree c2 = build_omp_clause (OMP_CLAUSE_LOCATION (c), OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (c2) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (c2, GOMP_MAP_POINTER);
if (!c_mark_addressable (t))
return false;
OMP_CLAUSE_DECL (c2) = t;
@@ -1,3 +1,10 @@
+2015-01-13 Thomas Schwinge <thomas@codesourcery.com>
+
+ * parser.c (cp_parser_oacc_data_clause)
+ (cp_parser_oacc_data_clause_deviceptr, cp_parser_omp_clause_map):
+ Use OMP_CLAUSE_SET_MAP_KIND.
+ * semantics.c (handle_omp_array_sections): Likewise.
+
2014-12-19 Jakub Jelinek <jakub@redhat.com>
* parser.c (cp_parser_omp_clause_name): Use PRAGMA_OACC_CLAUSE_*
@@ -27962,7 +27962,7 @@ cp_parser_oacc_data_clause (cp_parser *parser, pragma_omp_clause c_kind,
nl = cp_parser_omp_var_list (parser, OMP_CLAUSE_MAP, list);
for (c = nl; c != list; c = OMP_CLAUSE_CHAIN (c))
- OMP_CLAUSE_MAP_KIND (c) = kind;
+ OMP_CLAUSE_SET_MAP_KIND (c, kind);
return nl;
}
@@ -27998,7 +27998,7 @@ cp_parser_oacc_data_clause_deviceptr (cp_parser *parser, tree list)
error_at (loc, "%qD is not a pointer variable", v);
tree u = build_omp_clause (loc, OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (u) = GOMP_MAP_FORCE_DEVICEPTR;
+ OMP_CLAUSE_SET_MAP_KIND (u, GOMP_MAP_FORCE_DEVICEPTR);
OMP_CLAUSE_DECL (u) = v;
OMP_CLAUSE_CHAIN (u) = list;
list = u;
@@ -28959,7 +28959,7 @@ cp_parser_omp_clause_map (cp_parser *parser, tree list)
NULL);
for (c = nlist; c != list; c = OMP_CLAUSE_CHAIN (c))
- OMP_CLAUSE_MAP_KIND (c) = kind;
+ OMP_CLAUSE_SET_MAP_KIND (c, kind);
return nlist;
}
@@ -4671,7 +4671,7 @@ handle_omp_array_sections (tree c)
return false;
tree c2 = build_omp_clause (OMP_CLAUSE_LOCATION (c),
OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (c2) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (c2, GOMP_MAP_POINTER);
if (!cxx_mark_addressable (t))
return false;
OMP_CLAUSE_DECL (c2) = t;
@@ -4695,7 +4695,7 @@ handle_omp_array_sections (tree c)
{
tree c3 = build_omp_clause (OMP_CLAUSE_LOCATION (c),
OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (c3) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (c3, GOMP_MAP_POINTER);
OMP_CLAUSE_DECL (c3) = ptr;
OMP_CLAUSE_DECL (c2) = convert_from_reference (ptr);
OMP_CLAUSE_SIZE (c3) = size_zero_node;
@@ -1046,7 +1046,7 @@ gfc_omp_finish_clause (tree c, gimple_seq *pre_p)
return;
tree orig_decl = decl;
c4 = build_omp_clause (OMP_CLAUSE_LOCATION (c), OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (c4) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (c4, GOMP_MAP_POINTER);
OMP_CLAUSE_DECL (c4) = decl;
OMP_CLAUSE_SIZE (c4) = size_int (0);
decl = build_fold_indirect_ref (decl);
@@ -1057,7 +1057,7 @@ gfc_omp_finish_clause (tree c, gimple_seq *pre_p)
|| GFC_DECL_GET_SCALAR_ALLOCATABLE (orig_decl)))
{
c3 = build_omp_clause (OMP_CLAUSE_LOCATION (c), OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (c3) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (c3, GOMP_MAP_POINTER);
OMP_CLAUSE_DECL (c3) = unshare_expr (decl);
OMP_CLAUSE_SIZE (c3) = size_int (0);
decl = build_fold_indirect_ref (decl);
@@ -1074,11 +1074,11 @@ gfc_omp_finish_clause (tree c, gimple_seq *pre_p)
ptr = build_fold_indirect_ref (ptr);
OMP_CLAUSE_DECL (c) = ptr;
c2 = build_omp_clause (input_location, OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (c2) = GOMP_MAP_TO_PSET;
+ OMP_CLAUSE_SET_MAP_KIND (c2, GOMP_MAP_TO_PSET);
OMP_CLAUSE_DECL (c2) = decl;
OMP_CLAUSE_SIZE (c2) = TYPE_SIZE_UNIT (type);
c3 = build_omp_clause (OMP_CLAUSE_LOCATION (c), OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (c3) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (c3, GOMP_MAP_POINTER);
OMP_CLAUSE_DECL (c3) = gfc_conv_descriptor_data_get (decl);
OMP_CLAUSE_SIZE (c3) = size_int (0);
tree size = create_tmp_var (gfc_array_index_type);
@@ -1954,7 +1954,7 @@ gfc_trans_omp_clauses (stmtblock_t *block, gfc_omp_clauses *clauses,
tree orig_decl = decl;
node4 = build_omp_clause (input_location,
OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (node4) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (node4, GOMP_MAP_POINTER);
OMP_CLAUSE_DECL (node4) = decl;
OMP_CLAUSE_SIZE (node4) = size_int (0);
decl = build_fold_indirect_ref (decl);
@@ -1964,7 +1964,7 @@ gfc_trans_omp_clauses (stmtblock_t *block, gfc_omp_clauses *clauses,
{
node3 = build_omp_clause (input_location,
OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (node3) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (node3, GOMP_MAP_POINTER);
OMP_CLAUSE_DECL (node3) = decl;
OMP_CLAUSE_SIZE (node3) = size_int (0);
decl = build_fold_indirect_ref (decl);
@@ -1980,12 +1980,12 @@ gfc_trans_omp_clauses (stmtblock_t *block, gfc_omp_clauses *clauses,
OMP_CLAUSE_DECL (node) = ptr;
node2 = build_omp_clause (input_location,
OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (node2) = GOMP_MAP_TO_PSET;
+ OMP_CLAUSE_SET_MAP_KIND (node2, GOMP_MAP_TO_PSET);
OMP_CLAUSE_DECL (node2) = decl;
OMP_CLAUSE_SIZE (node2) = TYPE_SIZE_UNIT (type);
node3 = build_omp_clause (input_location,
OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (node3) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (node3, GOMP_MAP_POINTER);
OMP_CLAUSE_DECL (node3)
= gfc_conv_descriptor_data_get (decl);
OMP_CLAUSE_SIZE (node3) = size_int (0);
@@ -2071,7 +2071,7 @@ gfc_trans_omp_clauses (stmtblock_t *block, gfc_omp_clauses *clauses,
{
node4 = build_omp_clause (input_location,
OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (node4) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (node4, GOMP_MAP_POINTER);
OMP_CLAUSE_DECL (node4) = decl;
OMP_CLAUSE_SIZE (node4) = size_int (0);
decl = build_fold_indirect_ref (decl);
@@ -2083,12 +2083,12 @@ gfc_trans_omp_clauses (stmtblock_t *block, gfc_omp_clauses *clauses,
ptr2 = gfc_conv_descriptor_data_get (decl);
node2 = build_omp_clause (input_location,
OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (node2) = GOMP_MAP_TO_PSET;
+ OMP_CLAUSE_SET_MAP_KIND (node2, GOMP_MAP_TO_PSET);
OMP_CLAUSE_DECL (node2) = decl;
OMP_CLAUSE_SIZE (node2) = TYPE_SIZE_UNIT (type);
node3 = build_omp_clause (input_location,
OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (node3) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (node3, GOMP_MAP_POINTER);
OMP_CLAUSE_DECL (node3)
= gfc_conv_descriptor_data_get (decl);
}
@@ -2103,7 +2103,7 @@ gfc_trans_omp_clauses (stmtblock_t *block, gfc_omp_clauses *clauses,
}
node3 = build_omp_clause (input_location,
OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (node3) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (node3, GOMP_MAP_POINTER);
OMP_CLAUSE_DECL (node3) = decl;
}
ptr2 = fold_convert (sizetype, ptr2);
@@ -2113,37 +2113,37 @@ gfc_trans_omp_clauses (stmtblock_t *block, gfc_omp_clauses *clauses,
switch (n->u.map_op)
{
case OMP_MAP_ALLOC:
- OMP_CLAUSE_MAP_KIND (node) = GOMP_MAP_ALLOC;
+ OMP_CLAUSE_SET_MAP_KIND (node, GOMP_MAP_ALLOC);
break;
case OMP_MAP_TO:
- OMP_CLAUSE_MAP_KIND (node) = GOMP_MAP_TO;
+ OMP_CLAUSE_SET_MAP_KIND (node, GOMP_MAP_TO);
break;
case OMP_MAP_FROM:
- OMP_CLAUSE_MAP_KIND (node) = GOMP_MAP_FROM;
+ OMP_CLAUSE_SET_MAP_KIND (node, GOMP_MAP_FROM);
break;
case OMP_MAP_TOFROM:
- OMP_CLAUSE_MAP_KIND (node) = GOMP_MAP_TOFROM;
+ OMP_CLAUSE_SET_MAP_KIND (node, GOMP_MAP_TOFROM);
break;
case OMP_MAP_FORCE_ALLOC:
- OMP_CLAUSE_MAP_KIND (node) = GOMP_MAP_FORCE_ALLOC;
+ OMP_CLAUSE_SET_MAP_KIND (node, GOMP_MAP_FORCE_ALLOC);
break;
case OMP_MAP_FORCE_DEALLOC:
- OMP_CLAUSE_MAP_KIND (node) = GOMP_MAP_FORCE_DEALLOC;
+ OMP_CLAUSE_SET_MAP_KIND (node, GOMP_MAP_FORCE_DEALLOC);
break;
case OMP_MAP_FORCE_TO:
- OMP_CLAUSE_MAP_KIND (node) = GOMP_MAP_FORCE_TO;
+ OMP_CLAUSE_SET_MAP_KIND (node, GOMP_MAP_FORCE_TO);
break;
case OMP_MAP_FORCE_FROM:
- OMP_CLAUSE_MAP_KIND (node) = GOMP_MAP_FORCE_FROM;
+ OMP_CLAUSE_SET_MAP_KIND (node, GOMP_MAP_FORCE_FROM);
break;
case OMP_MAP_FORCE_TOFROM:
- OMP_CLAUSE_MAP_KIND (node) = GOMP_MAP_FORCE_TOFROM;
+ OMP_CLAUSE_SET_MAP_KIND (node, GOMP_MAP_FORCE_TOFROM);
break;
case OMP_MAP_FORCE_PRESENT:
- OMP_CLAUSE_MAP_KIND (node) = GOMP_MAP_FORCE_PRESENT;
+ OMP_CLAUSE_SET_MAP_KIND (node, GOMP_MAP_FORCE_PRESENT);
break;
case OMP_MAP_FORCE_DEVICEPTR:
- OMP_CLAUSE_MAP_KIND (node) = GOMP_MAP_FORCE_DEVICEPTR;
+ OMP_CLAUSE_SET_MAP_KIND (node, GOMP_MAP_FORCE_DEVICEPTR);
break;
default:
gcc_unreachable ();
@@ -6442,9 +6442,10 @@ gimplify_adjust_omp_clauses_1 (splay_tree_node n, void *data)
OMP_CLAUSE_PRIVATE_OUTER_REF (clause) = 1;
else if (code == OMP_CLAUSE_MAP)
{
- OMP_CLAUSE_MAP_KIND (clause) = flags & GOVD_MAP_TO_ONLY
- ? GOMP_MAP_TO
- : GOMP_MAP_TOFROM;
+ OMP_CLAUSE_SET_MAP_KIND (clause,
+ flags & GOVD_MAP_TO_ONLY
+ ? GOMP_MAP_TO
+ : GOMP_MAP_TOFROM);
if (DECL_SIZE (decl)
&& TREE_CODE (DECL_SIZE (decl)) != INTEGER_CST)
{
@@ -6465,7 +6466,7 @@ gimplify_adjust_omp_clauses_1 (splay_tree_node n, void *data)
OMP_CLAUSE_MAP);
OMP_CLAUSE_DECL (nc) = decl;
OMP_CLAUSE_SIZE (nc) = size_zero_node;
- OMP_CLAUSE_MAP_KIND (nc) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (nc, GOMP_MAP_POINTER);
OMP_CLAUSE_CHAIN (nc) = OMP_CLAUSE_CHAIN (clause);
OMP_CLAUSE_CHAIN (clause) = nc;
}
@@ -6639,7 +6640,7 @@ gimplify_adjust_omp_clauses (gimple_seq *pre_p, tree *list_p)
OMP_CLAUSE_MAP);
OMP_CLAUSE_DECL (nc) = decl;
OMP_CLAUSE_SIZE (nc) = size_zero_node;
- OMP_CLAUSE_MAP_KIND (nc) = GOMP_MAP_POINTER;
+ OMP_CLAUSE_SET_MAP_KIND (nc, GOMP_MAP_POINTER);
OMP_CLAUSE_CHAIN (nc) = OMP_CLAUSE_CHAIN (c);
OMP_CLAUSE_CHAIN (c) = nc;
c = nc;
@@ -70,6 +70,7 @@ along with GCC; see the file COPYING3. If not see
#include "streamer-hooks.h"
#include "cfgloop.h"
#include "builtins.h"
+#include "gomp-constants.h"
static void lto_write_tree (struct output_block*, tree, bool);
@@ -1,3 +1,7 @@
+2015-01-13 Thomas Schwinge <thomas@codesourcery.com>
+
+ * lto.c: Include "gomp-constants.h".
+
2014-03-20 Bernd Schmidt <bernds@codesourcery.com>
From Michael Zolotukhin.
@@ -77,6 +77,7 @@ along with GCC; see the file COPYING3. If not see
#include "ipa-inline.h"
#include "params.h"
#include "ipa-utils.h"
+#include "gomp-constants.h"
/* Number of parallel tasks to run, -1 if we want to use GNU Make jobserver. */
@@ -9713,7 +9713,7 @@ oacc_initialize_reduction_data (tree clauses, tree nthreads,
/* Add the reduction array to the list of clauses. */
tree x = array;
t = build_omp_clause (gimple_location (ctx->stmt), OMP_CLAUSE_MAP);
- OMP_CLAUSE_MAP_KIND (t) = GOMP_MAP_FORCE_FROM;
+ OMP_CLAUSE_SET_MAP_KIND (t, GOMP_MAP_FORCE_FROM);
OMP_CLAUSE_DECL (t) = x;
OMP_CLAUSE_CHAIN (t) = NULL;
if (oc)
@@ -20,8 +20,6 @@ along with GCC; see the file COPYING3. If not see
#ifndef GCC_TREE_CORE_H
#define GCC_TREE_CORE_H
-#include "gomp-constants.h"
-
/* This file contains all the data structures that define the 'tree' type.
There are no accessor macros nor functions in this file. Only the
basic data structures, extern declarations and type definitions. */
@@ -1298,7 +1296,8 @@ struct GTY(()) tree_omp_clause {
enum omp_clause_default_kind default_kind;
enum omp_clause_schedule_kind schedule_kind;
enum omp_clause_depend_kind depend_kind;
- enum gomp_map_kind map_kind;
+ /* See include/gomp-constants.h for enum gomp_map_kind's values. */
+ unsigned char map_kind;
enum omp_clause_proc_bind_kind proc_bind_kind;
enum tree_code reduction_code;
} GTY ((skip)) subcode;
@@ -1406,7 +1406,7 @@ convert_nonlocal_reference_stmt (gimple_stmt_iterator *gsi, bool *handled_ops_p,
decl = get_chain_decl (info);
c = build_omp_clause (gimple_location (stmt), OMP_CLAUSE_MAP);
OMP_CLAUSE_DECL (c) = decl;
- OMP_CLAUSE_MAP_KIND (c) = GOMP_MAP_TO;
+ OMP_CLAUSE_SET_MAP_KIND (c, GOMP_MAP_TO);
OMP_CLAUSE_SIZE (c) = DECL_SIZE_UNIT (decl);
OMP_CLAUSE_CHAIN (c) = gimple_omp_target_clauses (stmt);
gimple_omp_target_set_clauses (as_a <gomp_target *> (stmt), c);
@@ -1972,7 +1972,7 @@ convert_local_reference_stmt (gimple_stmt_iterator *gsi, bool *handled_ops_p,
(void) get_frame_type (info);
c = build_omp_clause (gimple_location (stmt), OMP_CLAUSE_MAP);
OMP_CLAUSE_DECL (c) = info->frame_decl;
- OMP_CLAUSE_MAP_KIND (c) = GOMP_MAP_TOFROM;
+ OMP_CLAUSE_SET_MAP_KIND (c, GOMP_MAP_TOFROM);
OMP_CLAUSE_SIZE (c) = DECL_SIZE_UNIT (info->frame_decl);
OMP_CLAUSE_CHAIN (c) = gimple_omp_target_clauses (stmt);
gimple_omp_target_set_clauses (as_a <gomp_target *> (stmt), c);
@@ -2413,7 +2413,7 @@ convert_gimple_call (gimple_stmt_iterator *gsi, bool *handled_ops_p,
{
c = build_omp_clause (gimple_location (stmt), OMP_CLAUSE_MAP);
OMP_CLAUSE_DECL (c) = decl;
- OMP_CLAUSE_MAP_KIND (c) = i ? GOMP_MAP_TO : GOMP_MAP_TOFROM;
+ OMP_CLAUSE_SET_MAP_KIND (c, i ? GOMP_MAP_TO : GOMP_MAP_TOFROM);
OMP_CLAUSE_SIZE (c) = DECL_SIZE_UNIT (decl);
OMP_CLAUSE_CHAIN (c) = gimple_omp_target_clauses (stmt);
gimple_omp_target_set_clauses (as_a <gomp_target *> (stmt),
@@ -59,6 +59,8 @@ along with GCC; see the file COPYING3. If not see
#include "lto-streamer.h"
#include "builtins.h"
#include "ipa-chkp.h"
+#include "gomp-constants.h"
+
/* Read a STRING_CST from the string table in DATA_IN using input
block IB. */
@@ -435,8 +437,8 @@ unpack_ts_omp_clause_value_fields (struct data_in *data_in,
= bp_unpack_enum (bp, omp_clause_depend_kind, OMP_CLAUSE_DEPEND_LAST);
break;
case OMP_CLAUSE_MAP:
- OMP_CLAUSE_MAP_KIND (expr)
- = bp_unpack_enum (bp, gomp_map_kind, GOMP_MAP_LAST);
+ OMP_CLAUSE_SET_MAP_KIND (expr, bp_unpack_enum (bp, gomp_map_kind,
+ GOMP_MAP_LAST));
break;
case OMP_CLAUSE_PROC_BIND:
OMP_CLAUSE_PROC_BIND_KIND (expr)
@@ -55,6 +55,8 @@ along with GCC; see the file COPYING3. If not see
#include "tree-streamer.h"
#include "data-streamer.h"
#include "streamer-hooks.h"
+#include "gomp-constants.h"
+
/* Output the STRING constant to the string
table in OB. Then put the index onto the INDEX_STREAM. */
@@ -1390,7 +1390,10 @@ extern void protected_set_expr_location (tree, location_t);
(OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_DEPEND)->omp_clause.subcode.depend_kind)
#define OMP_CLAUSE_MAP_KIND(NODE) \
- (OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_MAP)->omp_clause.subcode.map_kind)
+ ((enum gomp_map_kind) OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_MAP)->omp_clause.subcode.map_kind)
+#define OMP_CLAUSE_SET_MAP_KIND(NODE, MAP_KIND) \
+ (OMP_CLAUSE_SUBCODE_CHECK (NODE, OMP_CLAUSE_MAP)->omp_clause.subcode.map_kind \
+ = (unsigned char) (MAP_KIND))
/* Nonzero if this map clause is for array (rather than pointer) based array
section with zero bias. Both the non-decl OMP_CLAUSE_MAP and corresponding