From f14a732496e916cd10e67f2630ddd1eb77cfa7ab Mon Sep 17 00:00:00 2001 From: Kai Tietz Date: Tue, 10 Sep 2013 11:09:05 +0200 Subject: [PATCH] invoke.texi (fms-extensions): Document changed behavior for ms-abi targets. * doc/invoke.texi (fms-extensions): Document changed behavior for ms-abi targets. * config/i386/i386.c (ix86_option_override_internal): Set default value of option -fms-extension for ms-abi targets. From-SVN: r202429 --- gcc/ChangeLog | 7 +++++++ gcc/config/i386/i386.c | 6 ++++++ gcc/doc/invoke.texi | 2 ++ 3 files changed, 15 insertions(+) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 9f4a4b0efc3..b40dc28fb01 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2013-09-10 Kai Tietz + + * doc/invoke.texi (fms-extensions): Document changed + behavior for ms-abi targets. + * config/i386/i386.c (ix86_option_override_internal): + Set default value of option -fms-extension for ms-abi targets. + 2013-09-10 Michael Zolotukhin * config/i386/i386.c (ix86_expand_movmem): Fix epilogue generation. diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c index 1f07e6f3282..fe9a714f9ce 100644 --- a/gcc/config/i386/i386.c +++ b/gcc/config/i386/i386.c @@ -3357,6 +3357,12 @@ ix86_option_override_internal (bool main_args_p) if (!global_options_set.x_ix86_abi) ix86_abi = DEFAULT_ABI; + /* For targets using ms ABI enable ms-extensions, if not + explicit turned off. For non-ms ABI we turn off this + option. */ + if (!global_options_set.x_flag_ms_extensions) + flag_ms_extensions = (MS_ABI == DEFAULT_ABI); + if (global_options_set.x_ix86_cmodel) { switch (ix86_cmodel) diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 5b3c078e77b..73c3c58efa7 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -1856,6 +1856,8 @@ Some cases of unnamed fields in structures and unions are only accepted with this option. @xref{Unnamed Fields,,Unnamed struct/union fields within structs/unions}, for details. +Note that this option is off for all targets but i?86 and x86_64 +targets using ms-abi. @item -fplan9-extensions Accept some non-standard constructs used in Plan 9 code. -- 2.30.2