aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorSriraman Tallam <tmsriram@google.com>2013-01-03 00:42:10 +0000
committerSriraman Tallam <tmsriram@gcc.gnu.org>2013-01-03 00:42:10 +0000
commit778786217358981221cea14a4c543eaa5fba2221 (patch)
tree536e7aabdf6331042cee7e97399e3b9fbfd94dc8 /gcc
parent7f2ca2ecb81b0afb1b796863f08e4f48bfb6212f (diff)
downloadgcc-778786217358981221cea14a4c543eaa5fba2221.zip
gcc-778786217358981221cea14a4c543eaa5fba2221.tar.gz
gcc-778786217358981221cea14a4c543eaa5fba2221.tar.bz2
Simple fix to code to remove unnecessary NULL checks.
2013-01-02 Sriraman Tallam <tmsriram@google.com> * config/i386/i386.c (fold_builtin_cpu): Remove unnecessary checks for NULL. From-SVN: r194828
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/config/i386/i386.c12
2 files changed, 8 insertions, 9 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 2ab26d3..244208d 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2013-01-02 Sriraman Tallam <tmsriram@google.com>
+
+ * config/i386/i386.c (fold_builtin_cpu): Remove unnecessary checks for
+ NULL.
+
2013-01-02 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
PR middle-end/55198
diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c
index ee2b052..60f68d4 100644
--- a/gcc/config/i386/i386.c
+++ b/gcc/config/i386/i386.c
@@ -29626,15 +29626,9 @@ fold_builtin_cpu (tree fndecl, tree *args)
{"avx2", F_AVX2}
};
- tree __processor_model_type = NULL_TREE;
- tree __cpu_model_var = NULL_TREE;
-
- if (__processor_model_type == NULL_TREE)
- __processor_model_type = build_processor_model_struct ();
-
- if (__cpu_model_var == NULL_TREE)
- __cpu_model_var = make_var_decl (__processor_model_type,
- "__cpu_model");
+ tree __processor_model_type = build_processor_model_struct ();
+ tree __cpu_model_var = make_var_decl (__processor_model_type,
+ "__cpu_model");
gcc_assert ((args != NULL) && (*args != NULL));