aboutsummaryrefslogtreecommitdiff
path: root/scripts/gcc-plugins/gcc-common.h
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2020-05-04 11:20:32 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2020-05-04 11:20:32 -0700
commit9851a0dee7c28514f149f7e4f60ec1b06286cc1b (patch)
tree274e2d24230a9eed5160f6f7be150f95a4f6faf2 /scripts/gcc-plugins/gcc-common.h
parenta16a47e98a30ae6a424d30ce9f4f99e4d9384713 (diff)
parentc7527373fe28f97d8a196ab562db5589be0d34b9 (diff)
Merge tag 'gcc-plugins-v5.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux
Pull gcc-plugins fixes from Kees Cook: "GCC 10 fixes for gcc-plugins: - Adjust caller of cgraph_create_edge for GCC 10 argument usage - Update common headers to build under GCC 10 (Frédéric Pierret)" * tag 'gcc-plugins-v5.7-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux: gcc-common.h: Update for GCC 10 gcc-plugins/stackleak: Avoid assignment for unused macro argument
Diffstat (limited to 'scripts/gcc-plugins/gcc-common.h')
-rw-r--r--scripts/gcc-plugins/gcc-common.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/scripts/gcc-plugins/gcc-common.h b/scripts/gcc-plugins/gcc-common.h
index 17f06079a712..9ad76b7f3f10 100644
--- a/scripts/gcc-plugins/gcc-common.h
+++ b/scripts/gcc-plugins/gcc-common.h
@@ -35,7 +35,9 @@
#include "ggc.h"
#include "timevar.h"
+#if BUILDING_GCC_VERSION < 10000
#include "params.h"
+#endif
#if BUILDING_GCC_VERSION <= 4009
#include "pointer-set.h"
@@ -847,6 +849,7 @@ static inline gimple gimple_build_assign_with_ops(enum tree_code subcode, tree l
return gimple_build_assign(lhs, subcode, op1, op2 PASS_MEM_STAT);
}
+#if BUILDING_GCC_VERSION < 10000
template <>
template <>
inline bool is_a_helper<const ggoto *>::test(const_gimple gs)
@@ -860,6 +863,7 @@ inline bool is_a_helper<const greturn *>::test(const_gimple gs)
{
return gs->code == GIMPLE_RETURN;
}
+#endif
static inline gasm *as_a_gasm(gimple stmt)
{