aboutsummaryrefslogtreecommitdiff
path: root/gcc/jit
diff options
context:
space:
mode:
authorRichard Sandiford <richard.sandiford@arm.com>2015-11-07 10:18:38 +0000
committerRichard Sandiford <rsandifo@gcc.gnu.org>2015-11-07 10:18:38 +0000
commit0aad01985747ab503fd71ccf4767d0069fc3e85a (patch)
treeccf3e9b48b09616d6c7845a4b402ae67fa434d63 /gcc/jit
parent46e343b8d225732ae2e81509ca1accf47444f64b (diff)
downloadgcc-0aad01985747ab503fd71ccf4767d0069fc3e85a.zip
gcc-0aad01985747ab503fd71ccf4767d0069fc3e85a.tar.gz
gcc-0aad01985747ab503fd71ccf4767d0069fc3e85a.tar.bz2
Move #undef DEF_BUILTIN* to builtins.def
I was confused at first why tree-core.h was undefining DEF_BUILTIN_CHKP before defining it, then undefining it again after including builtins.def. This is because builtins.def provides a default definition of DEF_BUILTIN_CHKP, but leaves it up to the caller to undefine it where necessary. Similarly to the previous internal-fn.def patch, it seems more obvious for builtins.def to #undef things unconditionally. One argument might have been that keeping preprocessor stuff out of the .def files makes it easier for non-cpp parsers. In practice though we already have #ifs and multiline #defines, so single-line #undefs should be easy in comparison. Tested on x86_64-linux-gnu, aarch64-linux-gnu and arm-linux-gnueabi. gcc/ada/ * gcc-interface/utils.c: Don't undef DEF_BUILTIN. gcc/c-family/ * c-common.c: Don't undef DEF_BUILTIN. gcc/jit/ * jit-builtins.c: Don't undef DEF_BUILTIN. gcc/lto/ * lto-lang.c: Don't undef DEF_BUILTIN. gcc/ * builtins.def: #undef DEF_BUILTIN and DEF_BUILTIN_CHKP * builtins.c, genmatch.c, tree-core.h: Don't undef them here. From-SVN: r229924
Diffstat (limited to 'gcc/jit')
-rw-r--r--gcc/jit/ChangeLog4
-rw-r--r--gcc/jit/jit-builtins.c1
2 files changed, 4 insertions, 1 deletions
diff --git a/gcc/jit/ChangeLog b/gcc/jit/ChangeLog
index 301179b..5da8044 100644
--- a/gcc/jit/ChangeLog
+++ b/gcc/jit/ChangeLog
@@ -1,3 +1,7 @@
+2015-11-07 Richard Sandiford <richard.sandiford@arm.com>
+
+ * jit-builtins.c: Don't undef DEF_BUILTIN.
+
2015-10-29 Andrew MacLeod <amacleod@redhat.com>
* dummy-frontend.c: Reorder #include's and remove duplicates.
diff --git a/gcc/jit/jit-builtins.c b/gcc/jit/jit-builtins.c
index b28a5de..63ff5af 100644
--- a/gcc/jit/jit-builtins.c
+++ b/gcc/jit/jit-builtins.c
@@ -62,7 +62,6 @@ static const struct builtin_data builtin_data[] =
{
#include "builtins.def"
};
-#undef DEF_BUILTIN
/* Helper function for find_builtin_by_name. */