aboutsummaryrefslogtreecommitdiff
path: root/gcc/config/darwin.c
diff options
context:
space:
mode:
authorMartin Liska <mliska@suse.cz>2021-10-08 09:48:58 +0200
committerMartin Liska <mliska@suse.cz>2021-10-08 13:27:49 +0200
commit00f34291175981393b2a9802ada879e72335dcd0 (patch)
tree5267346de0543d9c66b23bab9e09d0cf89c9b01f /gcc/config/darwin.c
parent82e3a826871effc7093852a9181f641c693ae94f (diff)
downloadgcc-00f34291175981393b2a9802ada879e72335dcd0.zip
gcc-00f34291175981393b2a9802ada879e72335dcd0.tar.gz
gcc-00f34291175981393b2a9802ada879e72335dcd0.tar.bz2
Come up with OPTION_SET_P macro.
gcc/ada/ChangeLog: * gcc-interface/misc.c (gnat_post_options): Use new macro OPTION_SET_P. (gnat_init_gcc_eh): Likewise. (gnat_init_gcc_fp): Likewise. gcc/c-family/ChangeLog: * c-opts.c (c_common_post_options): Use new macro OPTION_SET_P. gcc/ChangeLog: * config/alpha/alpha.c (alpha_option_override): Use new macro OPTION_SET_P. * config/arc/arc.c (arc_override_options): Likewise. * config/arm/arm.c (arm_option_override): Likewise. * config/bfin/bfin.c (bfin_load_pic_reg): Likewise. * config/c6x/c6x.c (c6x_option_override): Likewise. * config/csky/csky.c: Likewise. * config/darwin.c (darwin_override_options): Likewise. * config/frv/frv.c (frv_option_override): Likewise. * config/i386/djgpp.h: Likewise. * config/i386/i386.c (ix86_stack_protect_guard): Likewise. (ix86_max_noce_ifcvt_seq_cost): Likewise. * config/ia64/ia64.c (ia64_option_override): Likewise. (ia64_override_options_after_change): Likewise. * config/m32c/m32c.c (m32c_option_override): Likewise. * config/m32r/m32r.c (m32r_init): Likewise. * config/m68k/m68k.c (m68k_option_override): Likewise. * config/microblaze/microblaze.c (microblaze_option_override): Likewise. * config/mips/mips.c (mips_option_override): Likewise. * config/nios2/nios2.c (nios2_option_override): Likewise. * config/nvptx/nvptx.c (nvptx_option_override): Likewise. * config/pa/pa.c (pa_option_override): Likewise. * config/riscv/riscv.c (riscv_option_override): Likewise. * config/rs6000/aix71.h: Likewise. * config/rs6000/aix72.h: Likewise. * config/rs6000/aix73.h: Likewise. * config/rs6000/rs6000.c (darwin_rs6000_override_options): Likewise. (rs6000_override_options_after_change): Likewise. (rs6000_linux64_override_options): Likewise. (glibc_supports_ieee_128bit): Likewise. (rs6000_option_override_internal): Likewise. (rs6000_file_start): Likewise. (rs6000_darwin_file_start): Likewise. * config/rs6000/rtems.h: Likewise. * config/rs6000/sysv4.h: Likewise. * config/rs6000/vxworks.h (SUB3TARGET_OVERRIDE_OPTIONS): Likewise. * config/s390/s390.c (s390_option_override): Likewise. * config/sh/linux.h: Likewise. * config/sh/netbsd-elf.h (while): Likewise. * config/sh/sh.c (sh_option_override): Likewise. * config/sol2.c (solaris_override_options): Likewise. * config/sparc/sparc.c (sparc_option_override): Likewise. * config/tilegx/tilegx.c (tilegx_option_override): Likewise. * config/visium/visium.c (visium_option_override): Likewise. * config/vxworks.c (vxworks_override_options): Likewise. * lto-opts.c (lto_write_options): Likewise. * omp-expand.c (expand_omp_simd): Likewise. * omp-general.c (omp_max_vf): Likewise. * omp-offload.c (oacc_xform_loop): Likewise. * opts.h (OPTION_SET_P): Likewise. * targhooks.c (default_max_noce_ifcvt_seq_cost): Likewise. * toplev.c (process_options): Likewise. * tree-predcom.c: Likewise. * tree-sra.c (analyze_all_variable_accesses): Likewise. gcc/cp/ChangeLog: * constexpr.c (maybe_warn_about_constant_value): Use new macro OPTION_SET_P. * decl.c (redeclaration_error_message): Likewise. (cxx_init_decl_processing): Likewise. gcc/d/ChangeLog: * d-lang.cc (d_post_options): Use new macro OPTION_SET_P. gcc/fortran/ChangeLog: * options.c (gfc_post_options): Use new macro OPTION_SET_P. gcc/objc/ChangeLog: * objc-next-runtime-abi-01.c: Use new macro OPTION_SET_P. * objc-next-runtime-abi-02.c (objc_next_runtime_abi_02_init): Likewise.
Diffstat (limited to 'gcc/config/darwin.c')
-rw-r--r--gcc/config/darwin.c31
1 files changed, 16 insertions, 15 deletions
diff --git a/gcc/config/darwin.c b/gcc/config/darwin.c
index 781742f..28dc55d 100644
--- a/gcc/config/darwin.c
+++ b/gcc/config/darwin.c
@@ -48,6 +48,7 @@ along with GCC; see the file COPYING3. If not see
#include "intl.h"
#include "optabs.h"
#include "flags.h"
+#include "opts.h"
/* Fix and Continue.
@@ -3282,7 +3283,7 @@ darwin_override_options (void)
}
/* Unless set, force ABI=2 for NeXT and m64, 0 otherwise. */
- if (!global_options_set.x_flag_objc_abi)
+ if (!OPTION_SET_P (flag_objc_abi))
global_options.x_flag_objc_abi
= (!flag_next_runtime)
? 0
@@ -3290,7 +3291,7 @@ darwin_override_options (void)
: (generating_for_darwin_version >= 9) ? 1
: 0);
- if (global_options_set.x_flag_objc_abi && flag_next_runtime)
+ if (OPTION_SET_P (flag_objc_abi) && flag_next_runtime)
{
if (TARGET_64BIT && global_options.x_flag_objc_abi != 2)
/* The Objective-C family ABI 2 is the only valid version NeXT/m64. */
@@ -3307,23 +3308,23 @@ darwin_override_options (void)
/* Don't emit DWARF3/4 unless specifically selected. This is a
workaround for tool bugs. */
- if (!global_options_set.x_dwarf_strict)
+ if (!OPTION_SET_P (dwarf_strict))
dwarf_strict = 1;
- if (!global_options_set.x_dwarf_version)
+ if (!OPTION_SET_P (dwarf_version))
dwarf_version = 2;
- if (global_options_set.x_dwarf_split_debug_info)
+ if (OPTION_SET_P (dwarf_split_debug_info))
{
inform (input_location,
"%<-gsplit-dwarf%> is not supported on this platform, ignored");
dwarf_split_debug_info = 0;
- global_options_set.x_dwarf_split_debug_info = 0;
+ OPTION_SET_P (dwarf_split_debug_info) = 0;
}
/* Do not allow unwind tables to be generated by default for m32.
fnon-call-exceptions will override this, regardless of what we do. */
if (generating_for_darwin_version < 10
- && !global_options_set.x_flag_asynchronous_unwind_tables
+ && !OPTION_SET_P (flag_asynchronous_unwind_tables)
&& !TARGET_64BIT)
global_options.x_flag_asynchronous_unwind_tables = 0;
@@ -3334,15 +3335,15 @@ darwin_override_options (void)
will be generated". If the User specifically sets flags... we assume
(s)he knows why... */
if (generating_for_darwin_version < 9
- && global_options_set.x_flag_reorder_blocks_and_partition
+ && OPTION_SET_P (flag_reorder_blocks_and_partition)
&& ((global_options.x_flag_exceptions /* User, c++, java */
- && !global_options_set.x_flag_exceptions) /* User specified... */
+ && !OPTION_SET_P (flag_exceptions)) /* User specified... */
|| (global_options.x_flag_unwind_tables
- && !global_options_set.x_flag_unwind_tables)
+ && !OPTION_SET_P (flag_unwind_tables))
|| (global_options.x_flag_non_call_exceptions
- && !global_options_set.x_flag_non_call_exceptions)
+ && !OPTION_SET_P (flag_non_call_exceptions))
|| (global_options.x_flag_asynchronous_unwind_tables
- && !global_options_set.x_flag_asynchronous_unwind_tables)))
+ && !OPTION_SET_P (flag_asynchronous_unwind_tables))))
{
inform (input_location,
"%<-freorder-blocks-and-partition%> does not work with "
@@ -3353,12 +3354,12 @@ darwin_override_options (void)
/* FIXME: flag_objc_sjlj_exceptions is no longer needed since there is only
one valid choice of exception scheme for each runtime. */
- if (!global_options_set.x_flag_objc_sjlj_exceptions)
+ if (!OPTION_SET_P (flag_objc_sjlj_exceptions))
global_options.x_flag_objc_sjlj_exceptions =
flag_next_runtime && !TARGET_64BIT;
/* FIXME: and this could be eliminated then too. */
- if (!global_options_set.x_flag_exceptions
+ if (!OPTION_SET_P (flag_exceptions)
&& flag_objc_exceptions
&& TARGET_64BIT)
flag_exceptions = 1;
@@ -3414,7 +3415,7 @@ darwin_override_options (void)
Linkers that don't need stubs, don't need the EH symbol markers either.
*/
- if (!global_options_set.x_darwin_symbol_stubs)
+ if (!OPTION_SET_P (darwin_symbol_stubs))
{
if (darwin_target_linker)
{