aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/dump-parse-tree.c
diff options
context:
space:
mode:
authorGiuliano Belinassi <giuliano.belinassi@usp.br>2020-08-22 17:43:43 -0300
committerGiuliano Belinassi <giuliano.belinassi@usp.br>2020-08-22 17:43:43 -0300
commita926878ddbd5a98b272c22171ce58663fc04c3e0 (patch)
tree86af256e5d9a9c06263c00adc90e5fe348008c43 /gcc/fortran/dump-parse-tree.c
parent542730f087133690b47e036dfd43eb0db8a650ce (diff)
parent07cbaed8ba7d1b6e4ab3a9f44175502a4e1ecdb1 (diff)
downloadgcc-devel/autopar_devel.zip
gcc-devel/autopar_devel.tar.gz
gcc-devel/autopar_devel.tar.bz2
Merge branch 'autopar_rebase2' into autopar_develdevel/autopar_devel
Quickly commit changes in the rebase branch.
Diffstat (limited to 'gcc/fortran/dump-parse-tree.c')
-rw-r--r--gcc/fortran/dump-parse-tree.c65
1 files changed, 28 insertions, 37 deletions
diff --git a/gcc/fortran/dump-parse-tree.c b/gcc/fortran/dump-parse-tree.c
index f323306..6e265f4 100644
--- a/gcc/fortran/dump-parse-tree.c
+++ b/gcc/fortran/dump-parse-tree.c
@@ -1552,6 +1552,8 @@ show_omp_clauses (gfc_omp_clauses *omp_clauses)
fputs (" SEQ", dumpfile);
if (omp_clauses->independent)
fputs (" INDEPENDENT", dumpfile);
+ if (omp_clauses->order_concurrent)
+ fputs (" ORDER(CONCURRENT)", dumpfile);
if (omp_clauses->ordered)
{
if (omp_clauses->orderedc)
@@ -1593,6 +1595,7 @@ show_omp_clauses (gfc_omp_clauses *omp_clauses)
case OMP_LIST_IS_DEVICE_PTR: type = "IS_DEVICE_PTR"; break;
case OMP_LIST_USE_DEVICE_PTR: type = "USE_DEVICE_PTR"; break;
case OMP_LIST_USE_DEVICE_ADDR: type = "USE_DEVICE_ADDR"; break;
+ case OMP_LIST_NONTEMPORAL: type = "NONTEMPORAL"; break;
default:
gcc_unreachable ();
}
@@ -1693,7 +1696,9 @@ show_omp_clauses (gfc_omp_clauses *omp_clauses)
if (omp_clauses->if_exprs[i])
{
static const char *ifs[] = {
+ "CANCEL",
"PARALLEL",
+ "SIMD",
"TASK",
"TASKLOOP",
"TARGET",
@@ -3257,45 +3262,28 @@ get_c_type_name (gfc_typespec *ts, gfc_array_spec *as, const char **pre,
if (ts->type == BT_REAL || ts->type == BT_INTEGER || ts->type == BT_COMPLEX)
{
if (ts->is_c_interop && ts->interop_kind)
- {
- *type_name = ts->interop_kind->name + 2;
- if (strcmp (*type_name, "signed_char") == 0)
- *type_name = "signed char";
- else if (strcmp (*type_name, "size_t") == 0)
- *type_name = "ssize_t";
- else if (strcmp (*type_name, "float_complex") == 0)
- *type_name = "__GFORTRAN_FLOAT_COMPLEX";
- else if (strcmp (*type_name, "double_complex") == 0)
- *type_name = "__GFORTRAN_DOUBLE_COMPLEX";
- else if (strcmp (*type_name, "long_double_complex") == 0)
- *type_name = "__GFORTRAN_LONG_DOUBLE_COMPLEX";
-
- ret = T_OK;
- }
+ ret = T_OK;
else
+ ret = T_WARN;
+
+ for (int i = 0; i < ISOCBINDING_NUMBER; i++)
{
- /* The user did not specify a C interop type. Let's look through
- the available table and use the first one, but warn. */
- for (int i = 0; i < ISOCBINDING_NUMBER; i++)
+ if (c_interop_kinds_table[i].f90_type == ts->type
+ && c_interop_kinds_table[i].value == ts->kind)
{
- if (c_interop_kinds_table[i].f90_type == ts->type
- && c_interop_kinds_table[i].value == ts->kind)
- {
- *type_name = c_interop_kinds_table[i].name + 2;
- if (strcmp (*type_name, "signed_char") == 0)
- *type_name = "signed char";
- else if (strcmp (*type_name, "size_t") == 0)
- *type_name = "ssize_t";
- else if (strcmp (*type_name, "float_complex") == 0)
- *type_name = "__GFORTRAN_FLOAT_COMPLEX";
- else if (strcmp (*type_name, "double_complex") == 0)
- *type_name = "__GFORTRAN_DOUBLE_COMPLEX";
- else if (strcmp (*type_name, "long_double_complex") == 0)
- *type_name = "__GFORTRAN_LONG_DOUBLE_COMPLEX";
-
- ret = T_WARN;
- break;
- }
+ *type_name = c_interop_kinds_table[i].name + 2;
+ if (strcmp (*type_name, "signed_char") == 0)
+ *type_name = "signed char";
+ else if (strcmp (*type_name, "size_t") == 0)
+ *type_name = "ssize_t";
+ else if (strcmp (*type_name, "float_complex") == 0)
+ *type_name = "__GFORTRAN_FLOAT_COMPLEX";
+ else if (strcmp (*type_name, "double_complex") == 0)
+ *type_name = "__GFORTRAN_DOUBLE_COMPLEX";
+ else if (strcmp (*type_name, "long_double_complex") == 0)
+ *type_name = "__GFORTRAN_LONG_DOUBLE_COMPLEX";
+
+ break;
}
}
}
@@ -3595,5 +3583,8 @@ show_global_symbol (gfc_gsymbol *gsym, void *f_data)
void
gfc_dump_global_symbols (FILE *f)
{
- gfc_traverse_gsymbol (gfc_gsym_root, show_global_symbol, (void *) f);
+ if (gfc_gsym_root == NULL)
+ fprintf (f, "empty\n");
+ else
+ gfc_traverse_gsymbol (gfc_gsym_root, show_global_symbol, (void *) f);
}