aboutsummaryrefslogtreecommitdiff
path: root/gcc/lto-opts.c
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2017-11-13 17:26:41 +0000
committerEric Botcazou <ebotcazou@gcc.gnu.org>2017-11-13 17:26:41 +0000
commit2f02b2c29168b6db2a25deb8073557330f652508 (patch)
tree7258aea2ab239cf5e6c08384f4eb1d2d0464e1a8 /gcc/lto-opts.c
parent41f0e8194de366399afb726a6862843d81f896a3 (diff)
downloadgcc-2f02b2c29168b6db2a25deb8073557330f652508.zip
gcc-2f02b2c29168b6db2a25deb8073557330f652508.tar.gz
gcc-2f02b2c29168b6db2a25deb8073557330f652508.tar.bz2
re PR lto/81351 (Many LTO testcases FAIL)
PR lto/81351 * debug.h (dwarf2out_do_eh_frame): Declare. * dwarf2cfi.c (dwarf2out_do_eh_frame): New predicate. (dwarf2out_do_frame): Use it. (dwarf2out_do_cfi_asm): Likewise. * dwarf2out.c (dwarf2out_frame_finish): Likewise. (dwarf2out_assembly_start): Likewise. (dwarf2out_begin_prologue): Fix comment. * toplev.c (compile_file): Always call dwarf2out_frame_finish if the target needs either debug or unwind DWARF2 info. * lto-opts.c (lto_write_options): Do not save -fexceptions, -fnon-call-exceptions, -ffp-contract, -fmath-errno, -fsigned-zeros, -ftrapping-math, -ftrapv and -fwrapv. From-SVN: r254697
Diffstat (limited to 'gcc/lto-opts.c')
-rw-r--r--gcc/lto-opts.c67
1 files changed, 2 insertions, 65 deletions
diff --git a/gcc/lto-opts.c b/gcc/lto-opts.c
index 641b279..e39f05d 100644
--- a/gcc/lto-opts.c
+++ b/gcc/lto-opts.c
@@ -70,73 +70,10 @@ lto_write_options (void)
obstack_init (&temporary_obstack);
- /* Output options that affect GIMPLE IL semantics and are implicitly
- enabled by the frontend.
- This for now includes an explicit set of options that we also handle
- explicitly in lto-wrapper.c. In the end the effects on GIMPLE IL
- semantics should be explicitely encoded in the IL or saved per
- function rather than per compilation unit. */
- /* -fexceptions causes the EH machinery to be initialized, enabling
- generation of unwind data so that explicit throw() calls work. */
- if (!global_options_set.x_flag_exceptions
- && global_options.x_flag_exceptions)
- append_to_collect_gcc_options (&temporary_obstack, &first_p,
- "-fexceptions");
- /* -fnon-call-exceptions changes the generation of exception
- regions. It is enabled implicitly by the Go frontend. */
- if (!global_options_set.x_flag_non_call_exceptions
- && global_options.x_flag_non_call_exceptions)
- append_to_collect_gcc_options (&temporary_obstack, &first_p,
- "-fnon-call-exceptions");
- /* The default -ffp-contract changes depending on the language
- standard. Pass thru conservative standard settings. */
- if (!global_options_set.x_flag_fp_contract_mode)
- switch (global_options.x_flag_fp_contract_mode)
- {
- case FP_CONTRACT_OFF:
- append_to_collect_gcc_options (&temporary_obstack, &first_p,
- "-ffp-contract=off");
- break;
- case FP_CONTRACT_ON:
- append_to_collect_gcc_options (&temporary_obstack, &first_p,
- "-ffp-contract=on");
- break;
- case FP_CONTRACT_FAST:
- /* Nothing. That merges conservatively and is the default for LTO. */
- break;
- default:
- gcc_unreachable ();
- }
- /* The default -fmath-errno, -fsigned-zeros and -ftrapping-math change
- depending on the language (they can be disabled by the Ada front-end).
- Pass thru conservative standard settings. */
- if (!global_options_set.x_flag_errno_math)
- append_to_collect_gcc_options (&temporary_obstack, &first_p,
- global_options.x_flag_errno_math
- ? "-fmath-errno"
- : "-fno-math-errno");
- if (!global_options_set.x_flag_signed_zeros)
- append_to_collect_gcc_options (&temporary_obstack, &first_p,
- global_options.x_flag_signed_zeros
- ? "-fsigned-zeros"
- : "-fno-signed-zeros");
- if (!global_options_set.x_flag_trapping_math)
- append_to_collect_gcc_options (&temporary_obstack, &first_p,
- global_options.x_flag_trapping_math
- ? "-ftrapping-math"
- : "-fno-trapping-math");
- /* We need to merge -f[no-]strict-overflow, -f[no-]wrapv and -f[no-]trapv
- conservatively, so stream out their defaults. */
- if (!global_options_set.x_flag_wrapv
- && global_options.x_flag_wrapv)
- append_to_collect_gcc_options (&temporary_obstack, &first_p, "-fwrapv");
- if (!global_options_set.x_flag_trapv
- && !global_options.x_flag_trapv)
- append_to_collect_gcc_options (&temporary_obstack, &first_p, "-fno-trapv");
-
if (!global_options_set.x_flag_openmp
&& !global_options.x_flag_openmp)
- append_to_collect_gcc_options (&temporary_obstack, &first_p, "-fno-openmp");
+ append_to_collect_gcc_options (&temporary_obstack, &first_p,
+ "-fno-openmp");
if (!global_options_set.x_flag_openacc
&& !global_options.x_flag_openacc)
append_to_collect_gcc_options (&temporary_obstack, &first_p,