Commit 1506ae0e by Tom de Vries Committed by Tom de Vries

Make fopenmp an LTO option

2015-01-23  Tom de Vries  <tom@codesourcery.com>

	PR libgomp/64707
	* lto-opts.c (lto_write_options): Output non-explicit conservative
	-fno-openmp.
	* lto-wrapper.c (merge_and_complain): Handle merging -fopenmp.
	(append_compiler_options): Pass -fopenmp through.

	* c.opt (fopenmp): Mark as LTO option.

	* lang.opt (fopenmp): Mark as LTO option.

	* testsuite/libgomp.c/target-9.c: Add -ftree-parallelize-loops=0 to
	dg-options.

From-SVN: r220037
parent 10ef8f28
2015-01-23 Tom de Vries <tom@codesourcery.com>
PR libgomp/64707
* lto-opts.c (lto_write_options): Output non-explicit conservative
-fno-openmp.
* lto-wrapper.c (merge_and_complain): Handle merging -fopenmp.
(append_compiler_options): Pass -fopenmp through.
2015-01-23 Jakub Jelinek <jakub@redhat.com>
PR debug/64511
......
2015-01-23 Tom de Vries <tom@codesourcery.com>
PR libgomp/64707
* c.opt (fopenmp): Mark as LTO option.
2015-01-21 Jakub Jelinek <jakub@redhat.com>
PR c/63307
......
......@@ -1288,7 +1288,7 @@ C ObjC C++ ObjC++ Var(flag_openacc)
Enable OpenACC
fopenmp
C ObjC C++ ObjC++ Var(flag_openmp)
C ObjC C++ ObjC++ LTO Var(flag_openmp)
Enable OpenMP (implies -frecursive in Fortran)
fopenmp-simd
......
2015-01-23 Tom de Vries <tom@codesourcery.com>
PR libgomp/64707
* lang.opt (fopenmp): Mark as LTO option.
2015-01-23 Andre Vehreschild <vehre@gmx.de>
......
......@@ -571,7 +571,7 @@ Fortran
; Documented in C
fopenmp
Fortran
Fortran LTO
; Documented in C
fopenmp-simd
......
......@@ -166,6 +166,10 @@ lto_write_options (void)
append_to_collect_gcc_options (&temporary_obstack, &first_p,
"-fno-strict-overflow");
if (!global_options_set.x_flag_openmp
&& !global_options.x_flag_openmp)
append_to_collect_gcc_options (&temporary_obstack, &first_p, "-fno-openmp");
/* Append options from target hook and store them to offload_lto section. */
if (lto_stream_offload_p)
{
......
......@@ -271,6 +271,7 @@ merge_and_complain (struct cl_decoded_option **decoded_options,
case OPT_fsigned_zeros:
case OPT_ftrapping_math:
case OPT_fwrapv:
case OPT_fopenmp:
/* For selected options we can merge conservatively. */
for (j = 0; j < *decoded_options_count; ++j)
if ((*decoded_options)[j].opt_index == foption->opt_index)
......@@ -490,6 +491,7 @@ append_compiler_options (obstack *argv_obstack, struct cl_decoded_option *opts,
case OPT_fsigned_zeros:
case OPT_ftrapping_math:
case OPT_fwrapv:
case OPT_fopenmp:
case OPT_ftrapv:
case OPT_fstrict_overflow:
case OPT_foffload_abi_:
......
2015-01-23 Tom de Vries <tom@codesourcery.com>
PR libgomp/64707
* testsuite/libgomp.c/target-9.c: Add -ftree-parallelize-loops=0 to
dg-options.
2015-01-19 Thomas Schwinge <thomas@codesourcery.com>
PR libgomp/64625
......
/* { dg-do run } */
/* { dg-options "-O1" } */
/* { dg-options "-O1 -ftree-parallelize-loops=0" } */
/* { dg-additional-options "-flto" { target lto } } */
#include <stdlib.h>
......
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