aboutsummaryrefslogtreecommitdiff
path: root/gcc/c-family
diff options
context:
space:
mode:
authorRichard Biener <rguenther@suse.de>2014-05-06 10:46:18 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2014-05-06 10:46:18 +0000
commitb15458becf4086c463cba0c42db1d8780351201b (patch)
tree115b7f066f20ecfeb1c96f5a0680b85f748cc4ac /gcc/c-family
parent3d224d46b893cdfa9c30c4dc7ad2b9a42b4071c4 (diff)
downloadgcc-b15458becf4086c463cba0c42db1d8780351201b.zip
gcc-b15458becf4086c463cba0c42db1d8780351201b.tar.gz
gcc-b15458becf4086c463cba0c42db1d8780351201b.tar.bz2
c-opts.c (c_common_post_options): For -freestanding...
2014-05-06 Richard Biener <rguenther@suse.de> c-family/ * c-opts.c (c_common_post_options): For -freestanding, -fno-hosted and -fno-builtin disable pattern recognition if not enabled explicitely. From-SVN: r210100
Diffstat (limited to 'gcc/c-family')
-rw-r--r--gcc/c-family/ChangeLog6
-rw-r--r--gcc/c-family/c-opts.c6
2 files changed, 12 insertions, 0 deletions
diff --git a/gcc/c-family/ChangeLog b/gcc/c-family/ChangeLog
index 3c97323..e347b32 100644
--- a/gcc/c-family/ChangeLog
+++ b/gcc/c-family/ChangeLog
@@ -1,3 +1,9 @@
+2014-05-06 Richard Biener <rguenther@suse.de>
+
+ * c-opts.c (c_common_post_options): For -freestanding,
+ -fno-hosted and -fno-builtin disable pattern recognition
+ if not enabled explicitely.
+
2014-05-02 Marek Polacek <polacek@redhat.com>
* c.opt (Wsizeof-pointer-memaccess): Describe option.
diff --git a/gcc/c-family/c-opts.c b/gcc/c-family/c-opts.c
index e162e49..29e9a35 100644
--- a/gcc/c-family/c-opts.c
+++ b/gcc/c-family/c-opts.c
@@ -851,6 +851,12 @@ c_common_post_options (const char **pfilename)
if (flag_objc_exceptions && !flag_objc_sjlj_exceptions)
flag_exceptions = 1;
+ /* If -ffreestanding, -fno-hosted or -fno-builtin then disable
+ pattern recognition. */
+ if (!global_options_set.x_flag_tree_loop_distribute_patterns
+ && flag_no_builtin)
+ flag_tree_loop_distribute_patterns = 0;
+
/* -Woverlength-strings is off by default, but is enabled by -Wpedantic.
It is never enabled in C++, as the minimum limit is not normative
in that standard. */