* tree-core.h (enum omp_clause_code): Add OMP_CLAUSE__CONDTEMP_.
	* tree.h (OMP_CLAUSE_DECL): Use OMP_CLAUSE__CONDTEMP_ instead of
	OMP_CLAUSE__REDUCTEMP_.
	* tree.c (omp_clause_num_ops, omp_clause_code_name): Add
	OMP_CLAUSE__CONDTEMP_.
	(walk_tree_1): Handle OMP_CLAUSE__CONDTEMP_.
	* tree-pretty-print.c (dump_omp_clause): Likewise.
	* tree-nested.c (convert_nonlocal_omp_clauses,
	convert_local_omp_clauses): Likewise.
	* gimplify.c (enum gimplify_omp_var_data): Use hexadecimal constants
	instead of decimal.  Add GOVD_LASTPRIVATE_CONDITIONAL.
	(gimplify_scan_omp_clauses): Don't reject lastprivate conditional
	on OMP_FOR.
	(gimplify_omp_for): Warn and disable conditional modifier from
	lastprivate on loop iterators.
	* omp-general.h (struct omp_for_data): Add lastprivate_conditional
	member.
	* omp-general.c (omp_extract_for_data): Initialize it.
	* omp-low.c (struct omp_context): Add lastprivate_conditional_map
	member.
	(delete_omp_context): Delete it.
	(lower_lastprivate_conditional_clauses): New function.
	(lower_lastprivate_clauses): Add BODY_P and CSTMT_LIST arguments,
	handle lastprivate conditional clauses.
	(lower_reduction_clauses): Add CLIST argument, emit it into
	the critical section if any.
	(lower_omp_sections): Adjust lower_lastprivate_clauses and
	lower_reduction_clauses callers.
	(lower_omp_for_lastprivate): Add CLIST argument, pass it through
	to lower_lastprivate_clauses.
	(lower_omp_for): Call lower_lastprivate_conditional_clauses, adjust
	lower_omp_for_lastprivate and lower_reduction_clauses callers, emit
	clist into a critical section if not emitted there already by
	lower_reduction_clauses.
	(lower_omp_taskreg, lower_omp_teams): Adjust lower_reduction_clauses
	callers.
	(lower_omp_1): Handle GIMPLE_ASSIGNs storing into lastprivate
	conditional variables.
	* omp-expand.c (determine_parallel_type): Punt if OMP_CLAUSE__CONDTEMP_
	clause is present.
	(expand_omp_for_generic, expand_omp_for_static_nochunk,
	expand_omp_for_static_chunk): Handle lastprivate conditional.
	(expand_omp_for): Handle fd.lastprivate_conditional like
	fd.have_reductemp.
gcc/testsuite/
	* c-c++-common/gomp/lastprivate-conditional-2.c (foo): Don't expect
	sorry for omp for.
	* c-c++-common/gomp/lastprivate-conditional-3.c: New test.
libgomp/
	* testsuite/libgomp.c-c++-common/lastprivate-conditional-1.c: New test.
	* testsuite/libgomp.c-c++-common/lastprivate-conditional-2.c: New test.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@271610 138bc75d-0d04-0410-961f-82ee72b054a4
17 files changed