Commit 7beb2b9d by Olivier Hainque Committed by Pierre-Marie de Rodat

[Ada] Gigi support for OpenACC pragmas

Matching front-end bits to support Acc_Kernels, Acc_Parallel,
Acc_Loop and Acc_Data.

2018-12-03  Olivier Hainque  <hainque@adacore.com>

gcc/ada/

	* gcc-interface/lang.opt (fopenacc): New option for Ada.
	* gcc-interface/misc.c (gnat_handle_option): Handle it.
	* gcc-interface/trans.c (struct loop_info_d): Add OMP
	attributes.
	(Iterate_Acc_Clause_Arg, Acc_gnat_to_gnu): New functions,
	helpers for OpenACC pragmas processing in Pragma_to_gnu.
	(Acc_Var_to_gnu, Acc_Reduc_Var_to_gnu, Acc_Reduc_to_gnu):
	Likewise.
	(Acc_Size_Expr_to_gnu, Acc_Size_List_to_gnu): Likewise.
	(Pragma_Acc_Data_to_gnu): Likewise.
	(Pragma_to_gnu): Handle Pragma_Acc_Loop, Pragma_Acc_Data,
	Pragma_Acc_Kernels and Pragma_Acc_Parallel.
	(Acc_Loop_to_gnu, Regular_Loop_to_gnu): New functions. Helpers
	for ...
	(Loop_Statement_to_gnu): Rework to handle OpenACC loops.

From-SVN: r266748
parent e663d4d9
2018-12-03 Olivier Hainque <hainque@adacore.com> 2018-12-03 Olivier Hainque <hainque@adacore.com>
* gcc-interface/lang.opt (fopenacc): New option for Ada.
* gcc-interface/misc.c (gnat_handle_option): Handle it.
* gcc-interface/trans.c (struct loop_info_d): Add OMP
attributes.
(Iterate_Acc_Clause_Arg, Acc_gnat_to_gnu): New functions,
helpers for OpenACC pragmas processing in Pragma_to_gnu.
(Acc_Var_to_gnu, Acc_Reduc_Var_to_gnu, Acc_Reduc_to_gnu):
Likewise.
(Acc_Size_Expr_to_gnu, Acc_Size_List_to_gnu): Likewise.
(Pragma_Acc_Data_to_gnu): Likewise.
(Pragma_to_gnu): Handle Pragma_Acc_Loop, Pragma_Acc_Data,
Pragma_Acc_Kernels and Pragma_Acc_Parallel.
(Acc_Loop_to_gnu, Regular_Loop_to_gnu): New functions. Helpers
for ...
(Loop_Statement_to_gnu): Rework to handle OpenACC loops.
2018-12-03 Olivier Hainque <hainque@adacore.com>
* gcc-interface/targtyps.c (MALLOC_OBSERVABLE_ALIGNMENT): Set to * gcc-interface/targtyps.c (MALLOC_OBSERVABLE_ALIGNMENT): Set to
2 * POINTER_SIZE. 2 * POINTER_SIZE.
......
...@@ -100,4 +100,8 @@ fbuiltin-printf ...@@ -100,4 +100,8 @@ fbuiltin-printf
Ada Undocumented Ada Undocumented
Ignored. Ignored.
fopenacc
Ada LTO
; Documented in C but it should be: Enable OpenACC support
; This comment is to ensure we retain the blank line above. ; This comment is to ensure we retain the blank line above.
...@@ -166,6 +166,7 @@ gnat_handle_option (size_t scode, const char *arg, HOST_WIDE_INT value, ...@@ -166,6 +166,7 @@ gnat_handle_option (size_t scode, const char *arg, HOST_WIDE_INT value,
/* These are handled by the front-end. */ /* These are handled by the front-end. */
break; break;
case OPT_fopenacc:
case OPT_fshort_enums: case OPT_fshort_enums:
case OPT_fsigned_char: case OPT_fsigned_char:
case OPT_funsigned_char: case OPT_funsigned_char:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment